Esempio n. 1
0
        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 = "" });
        }
Esempio n. 2
0
        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);
        }
Esempio n. 3
0
 public DatalistData()
 {
     FilteredRecords = 0;
     Columns         = new DatalistColumns();
     Rows            = new List <Dictionary <String, String> >();
 }