Created
July 3, 2018 07:03
-
-
Save mikeedwards83/61549efae1254dc83e652bc3d76114d2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Demo | |
{ | |
public virtual Guid Id { get; set; } | |
public virtual string Title { get; set; } | |
public virtual DateTime Date { get; set; } | |
public virtual string Url { get; set; } | |
} | |
public class DemoController : Controller { | |
public ActionResult Index(){ | |
var mvcContext = new MvcContext(); | |
var model = mvcContext.GetCurrentItem<Demo>(); | |
var url = model.Url; | |
return View(model); | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment