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); } }
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); } }
private static string GetSort(this Controller controller, int index) { return(ViewBagHelper.GetSort(controller.ViewBag, index)); }
private static int?GetPage(this Controller controller, int index) { return(ViewBagHelper.GetPage(controller.ViewBag, index)); }
private static bool GetDescending(this Controller controller, int index) { return(ViewBagHelper.GetDescending(controller.ViewBag, index)); }
private static string GetSort(this IHtmlHelper htmlHelper, int index) { var sort = ViewBagHelper.GetSort(htmlHelper.ViewBag, index); return(sort); }
private static string GetSortValue(this IHtmlHelper htmlHelper) { var sort = ViewBagHelper.GetSortValue(htmlHelper.ViewBag); return(sort); }
private static string GetPageValue(this IHtmlHelper htmlHelper) { var page = ViewBagHelper.GetPageValue(htmlHelper.ViewBag); return(page); }
private static string GetFilterValue(this IHtmlHelper htmlHelper) { var filter = ViewBagHelper.GetFilterValue(htmlHelper.ViewBag); return(filter); }
private static string GetFilter(this IHtmlHelper htmlHelper, int index) { var filter = ViewBagHelper.GetFilter(htmlHelper.ViewBag, index); return(filter); }
private static string GetDescendingValue(this IHtmlHelper htmlHelper) { var descending = ViewBagHelper.GetDescendingValue(htmlHelper.ViewBag); return(descending); }
private static bool GetDescending(this IHtmlHelper htmlHelper, int index) { var descending = ViewBagHelper.GetDescending(htmlHelper.ViewBag, index); return(descending); }