Beispiel #1
0
 /// <summary>
 /// Creates a new instance of the Pager class.
 /// </summary>
 /// <param name="pagination">The IPagination datasource</param>
 /// <param name="request">The current HTTP Request</param>
 public Pager(PaginationModels pagination, HttpRequestBase request, string strParam = "")
 {
     _pagination = pagination;
     if (!string.IsNullOrEmpty(_pagination.PageQueryName))
     {
         _pageQueryName = _pagination.PageQueryName;
     }
     _request   = request;
     _strParam  = strParam;
     urlBuilder = CreateDefaultUrl;
 }
Beispiel #2
0
 public static Pager Pager(this HtmlHelper helper, PaginationModels pagination)
 {
     return(new Pager(pagination, helper.ViewContext.HttpContext.Request));
 }