protected AbstractDatalist(UrlHelper url) { String sanitizedName = GetType().Name.Replace(Prefix, ""); AdditionalFilters = new List <String>(); CurrentFilter = new DatalistFilter(); Columns = new DatalistColumns(); DialogTitle = sanitizedName; DefaultRecordsPerPage = 20; DatalistUrl = url.Action(sanitizedName, Prefix, new { area = "" }); }
protected AbstractDatalist() { String sanitizedName = GetType().Name.Replace(Prefix, String.Empty); AdditionalFilters = new List <String>(); CurrentFilter = new DatalistFilter(); Columns = new DatalistColumns(); DialogTitle = sanitizedName; DefaultRecordsPerPage = 20; String applicationPath = HttpContext.Current.Request.ApplicationPath ?? "/"; if (!applicationPath.EndsWith("/")) { applicationPath += "/"; } DatalistUrl = String.Format("{0}://{1}{2}{3}/{4}", HttpContext.Current.Request.Url.Scheme, HttpContext.Current.Request.Url.Authority, applicationPath, Prefix, sanitizedName); }
public DatalistData() { FilteredRecords = 0; Columns = new DatalistColumns(); Rows = new List <Dictionary <String, String> >(); }