Esempio n. 1
0
        /// <summary>
        /// 创建分页导航
        /// </summary>
        public static MvcHtmlString Create <T>(PageObj <T> page, CoreHelper.PageNavigation.PageStyle style, string navFormat)
        {
            var nav = new CoreHelper.PageNavigation();

            nav.SetPageStyle(style);
            nav.PageNavigationFormat = navFormat;
            if (page.Count == 0)
            {
                return(MvcHtmlString.Create(""));
            }
            string str = nav.GetPageNavigation(page.PageIndex, page.Total, page.PageSize);

            return(MvcHtmlString.Create(str));
        }
Esempio n. 2
0
 /// <summary>
 /// 创建分页导航
 /// </summary>
 /// <typeparam name="T"></typeparam>
 /// <param name="page"></param>
 /// <returns></returns>
 public static MvcHtmlString Create <T>(PageObj <T> page)
 {
     return(Create(page, CoreHelper.PageNavigation.PageStyle.Default, ""));
 }