예제 #1
0
        public static HtmlGrid <T> Grid <T>(this IHtmlHelper helper, SGrid <T> sourceGrid, string viewName, IViewEngine viewEngine)
        {
            //wrap source grid:
            var htmlGrid = new HtmlGrid <T>(helper, sourceGrid, viewName);

            return(htmlGrid);
        }
예제 #2
0
        public static HtmlGrid <T> Grid <T>(this IHtmlHelper helper, SGrid <T> sourceGrid, IViewEngine viewEngine = null)
        {
            //wrap source grid:
            var htmlGrid = new HtmlGrid <T>(helper, sourceGrid, DefaultPartialViewName);

            return(htmlGrid);
        }
예제 #3
0
        public static HtmlGrid <T> Grid <T>(this IHtmlHelper helper, IEnumerable <T> items, string viewName, IViewEngine viewEngine = null)
        {
            var newGrid  = new SGrid <T>(items, helper.ViewContext.HttpContext.Request.Query);
            var htmlGrid = new HtmlGrid <T>(helper, newGrid, viewName);

            return(htmlGrid);
        }
예제 #4
0
        public static HtmlGrid <T> Grid <T>(this IHtmlHelper helper, SGrid <T> sourceGrid, IViewEngine viewEngine)
        {
            //wrap source grid:
            var htmlGrid = new HtmlGrid <T>(sourceGrid, helper.ViewContext, DefaultPartialViewName, viewEngine);

            return(htmlGrid);
        }
예제 #5
0
        public static HtmlGrid <T> Grid <T>(this IHtmlHelper helper, IEnumerable <T> items, IQueryCollection query, string viewName, IViewEngine viewEngine = null)
        {
            var newGrid  = new SGrid <T>(items, query);
            var htmlGrid = new HtmlGrid <T>(helper, newGrid, viewName);

            return(htmlGrid);
        }
예제 #6
0
        public static HtmlGrid <T> Grid <T>(this IHtmlHelper helper, IEnumerable <T> items,
                                            GridRenderOptions renderOptions, IViewEngine viewEngine)
        {
            var newGrid = new SGrid <T>(items, helper.ViewContext.HttpContext.Request.Query);

            newGrid.RenderOptions = renderOptions;
            var htmlGrid = new HtmlGrid <T>(newGrid, helper.ViewContext, renderOptions.ViewName, viewEngine);

            return(htmlGrid);
        }