Пример #1
0
 public static MvcHtmlString AjaxPager(this HtmlHelper html, IPagedList pagedList, string routeName, RouteValueDictionary routeValues, PagerOptions pagerOptions, AjaxOptions ajaxOptions, IDictionary <string, object> htmlAttributes)
 {
     if (pagedList == null)
     {
         return(AjaxPager(html, pagerOptions, htmlAttributes));
     }
     return(html.AjaxPager(pagedList.TotalItemCount, pagedList.PageSize, pagedList.CurrentPageIndex, null, null, routeName, pagerOptions, routeValues, ajaxOptions, htmlAttributes));
 }
Пример #2
0
        public static MvcHtmlString AjaxPager(this HtmlHelper html, int totalItemCount, int pageSize, int pageIndex, string actionName, string controllerName, string routeName, PagerOptions pagerOptions, object routeValues, AjaxOptions ajaxOptions, object htmlAttributes)
        {
            if (pagerOptions == null)
            {
                pagerOptions = new PagerOptions();
            }
            pagerOptions.UseJqueryAjax = true;
            int          totalPageCount = (int)Math.Ceiling(totalItemCount / ((double)pageSize));
            PagerBuilder builder        = new PagerBuilder(html, actionName, controllerName, totalPageCount, pageIndex, totalItemCount, pagerOptions, routeName, new RouteValueDictionary(routeValues), ajaxOptions, new RouteValueDictionary(htmlAttributes));

            return(builder.RenderPager());
        }
Пример #3
0
        public static MvcHtmlString Pager(this AjaxHelper ajax, int totalItemCount, int pageSize, int pageIndex, string actionName, string controllerName, string routeName, PagerOptions pagerOptions, RouteValueDictionary routeValues, AjaxOptions ajaxOptions, IDictionary <string, object> htmlAttributes)
        {
            int          totalPageCount = (int)Math.Ceiling(totalItemCount / ((double)pageSize));
            PagerBuilder builder        = new PagerBuilder(ajax, actionName, controllerName, totalPageCount, pageIndex, totalItemCount, pagerOptions, routeName, routeValues, ajaxOptions, htmlAttributes);

            return(builder.RenderPager());
        }
Пример #4
0
 public static MvcHtmlString AjaxPager(this HtmlHelper html, IPagedList pagedList, string actionName, string controllerName, PagerOptions pagerOptions, AjaxOptions ajaxOptions)
 {
     if (pagedList == null)
     {
         return(AjaxPager(html, pagerOptions, null));
     }
     return(html.AjaxPager(pagedList.TotalItemCount, pagedList.PageSize, pagedList.CurrentPageIndex, actionName, controllerName, null, pagerOptions, null, ajaxOptions, null));
 }
Пример #5
0
 public static MvcHtmlString Pager(this AjaxHelper ajax, IPagedList pagedList, string routeName, object routeValues, PagerOptions pagerOptions, AjaxOptions ajaxOptions, object htmlAttributes)
 {
     if (pagedList == null)
     {
         return(Pager(ajax, pagerOptions, new RouteValueDictionary(htmlAttributes)));
     }
     return(ajax.Pager(pagedList.TotalItemCount, pagedList.PageSize, pagedList.CurrentPageIndex, null, null, routeName, pagerOptions, routeValues, ajaxOptions, htmlAttributes));
 }
Пример #6
0
        public static MvcHtmlString Pager(this HtmlHelper helper, int totalItemCount, int pageSize, int pageIndex, string actionName, string controllerName, PagerOptions pagerOptions, string routeName, object routeValues, object htmlAttributes)
        {
            int          totalPageCount = (int)Math.Ceiling(totalItemCount / ((double)pageSize));
            PagerBuilder builder        = new PagerBuilder(helper, actionName, controllerName, totalPageCount, pageIndex, totalItemCount, pagerOptions, routeName, new RouteValueDictionary(routeValues), new RouteValueDictionary(htmlAttributes));

            return(builder.RenderPager());
        }
Пример #7
0
 private static MvcHtmlString AjaxPager(HtmlHelper html, PagerOptions pagerOptions, IDictionary <string, object> htmlAttributes)
 {
     return(new PagerBuilder(html, null, pagerOptions, htmlAttributes).RenderPager());
 }
Пример #8
0
 public static MvcHtmlString Pager(this HtmlHelper helper, IPagedList pagedList, PagerOptions pagerOptions, string routeName, RouteValueDictionary routeValues)
 {
     if (pagedList == null)
     {
         return(Pager(helper, pagerOptions, null));
     }
     return(helper.Pager(pagedList.TotalItemCount, pagedList.PageSize, pagedList.CurrentPageIndex, null, null, pagerOptions, routeName, routeValues, null));
 }
Пример #9
0
 public static MvcHtmlString Pager(this AjaxHelper ajax, IPagedList pagedList, PagerOptions pagerOptions, AjaxOptions ajaxOptions, IDictionary <string, object> htmlAttributes)
 {
     if (pagedList == null)
     {
         return(Pager(ajax, pagerOptions, htmlAttributes));
     }
     return(ajax.Pager(pagedList.TotalItemCount, pagedList.PageSize, pagedList.CurrentPageIndex, null, null, null, pagerOptions, null, ajaxOptions, htmlAttributes));
 }
Пример #10
0
 public static MvcHtmlString Pager(this HtmlHelper helper, IPagedList pagedList, PagerOptions pagerOptions, object htmlAttributes)
 {
     if (pagedList == null)
     {
         return(Pager(helper, pagerOptions, new RouteValueDictionary(htmlAttributes)));
     }
     return(helper.Pager(pagedList.TotalItemCount, pagedList.PageSize, pagedList.CurrentPageIndex, null, null, pagerOptions, null, null, htmlAttributes));
 }
Пример #11
0
 public static MvcHtmlString Pager(this AjaxHelper ajax, IPagedList pagedList, PagerOptions pagerOptions, AjaxOptions ajaxOptions)
 {
     if (pagedList != null)
     {
         return(ajax.Pager(pagedList.TotalItemCount, pagedList.PageSize, pagedList.CurrentPageIndex, null, null, null, pagerOptions, null, ajaxOptions, null));
     }
     return(Pager(ajax, pagerOptions, null));
 }
Пример #12
0
 public static MvcHtmlString Pager(this HtmlHelper helper, IPagedList pagedList, PagerOptions pagerOptions)
 {
     if (pagedList == null)
     {
         return(Pager(helper, pagerOptions, null));
     }
     return(helper.Pager(pagedList.TotalItemCount, pagedList.PageSize, pagedList.CurrentPageIndex, null, null, pagerOptions, null, null, null));
 }
Пример #13
0
 private static MvcHtmlString Pager(AjaxHelper ajax, PagerOptions pagerOptions, IDictionary <string, object> htmlAttributes)
 {
     return(new PagerBuilder(null, ajax, pagerOptions, htmlAttributes).RenderPager());
 }