About example DynamicDataMvcPreview0718 RRS feed

  • Question

  • User1235385968 posted


    How do I create a Custom Pages folder in this project?
    The source code here.
    Thank you!!


    Thursday, August 14, 2008 8:37 AM

All replies

  • User1235385968 posted

    One solution a this question is in DynamicScaffoldController.cs

    protected virtual ActionResult OnList(PagedList<TEntity> entities, string sort) {

    ViewData["sort"] = sort;

    //Looking at the table we want to customize


    return View("CustomPages/Paginas/List", entities);return View("PageTemplates/List", entities);



    but this is a solution rather poor. Any other ideas?
    Thursday, August 14, 2008 9:42 AM
  • User-1032240251 posted

    The current build does not have any built-in support for automatically finding custom pages.

    One way to do this is by creating controllers which override the appropriate methods. For example:

    public class PaginasController : DynamicScaffoldController<Paginas> {
        protected override ActionResult OnList(PagedList<Paginas> entities, string sort) {
            ViewData["sort"] = sort;
            return View("CustomPages/Paginas/List", entities);
    Monday, September 8, 2008 3:20 AM