예제 #1
0
        public static void SetSortDefault(this Controller controller, string sort, int index = 0)
        {
            var existingSort = ViewBagHelper.GetSort(controller.ViewBag, index);

            if (string.IsNullOrEmpty(existingSort))
            {
                ViewBagHelper.SetSort(controller.ViewBag, sort, index);
            }
        }
예제 #2
0
        public static void SetFilterDefault(this Controller controller, string filter, int index = 0)
        {
            var existingFilter = ViewBagHelper.GetFilter(controller.ViewBag, index);

            if (string.IsNullOrEmpty(existingFilter))
            {
                ViewBagHelper.SetFilter(controller.ViewBag, filter, index);
            }
        }
예제 #3
0
 private static string GetSort(this Controller controller, int index)
 {
     return(ViewBagHelper.GetSort(controller.ViewBag, index));
 }
예제 #4
0
 private static int?GetPage(this Controller controller, int index)
 {
     return(ViewBagHelper.GetPage(controller.ViewBag, index));
 }
예제 #5
0
 private static bool GetDescending(this Controller controller, int index)
 {
     return(ViewBagHelper.GetDescending(controller.ViewBag, index));
 }
예제 #6
0
        private static string GetSort(this IHtmlHelper htmlHelper, int index)
        {
            var sort = ViewBagHelper.GetSort(htmlHelper.ViewBag, index);

            return(sort);
        }
예제 #7
0
        private static string GetSortValue(this IHtmlHelper htmlHelper)
        {
            var sort = ViewBagHelper.GetSortValue(htmlHelper.ViewBag);

            return(sort);
        }
예제 #8
0
        private static string GetPageValue(this IHtmlHelper htmlHelper)
        {
            var page = ViewBagHelper.GetPageValue(htmlHelper.ViewBag);

            return(page);
        }
예제 #9
0
        private static string GetFilterValue(this IHtmlHelper htmlHelper)
        {
            var filter = ViewBagHelper.GetFilterValue(htmlHelper.ViewBag);

            return(filter);
        }
예제 #10
0
        private static string GetFilter(this IHtmlHelper htmlHelper, int index)
        {
            var filter = ViewBagHelper.GetFilter(htmlHelper.ViewBag, index);

            return(filter);
        }
예제 #11
0
        private static string GetDescendingValue(this IHtmlHelper htmlHelper)
        {
            var descending = ViewBagHelper.GetDescendingValue(htmlHelper.ViewBag);

            return(descending);
        }
예제 #12
0
        private static bool GetDescending(this IHtmlHelper htmlHelper, int index)
        {
            var descending = ViewBagHelper.GetDescending(htmlHelper.ViewBag, index);

            return(descending);
        }