Ejemplo n.º 1
0
        public IActionResult ListData(IDataTablesRequest request, DeliveryItemFilterVM filterData)
        {
            filterData.ResetCourtByType(userContext.CourtId);
            var data = service.DeliveryItemSelect(filterData);

            return(request.GetResponse(data));
        }
Ejemplo n.º 2
0
        public IActionResult Index(int?filterType)
        {
            var model = new DeliveryItemFilterVM();

            model.FilterType = filterType ?? 0;
            if (model.FilterType == 0)
            {
                model.FilterType = NomenclatureConstants.DeliveryItemFilterType.Inner;
            }
            model.NoAutoLoad = "Y";
            SetHelpFile(HelpFileValues.Summons);
            return(LoadIndex(model));
        }
Ejemplo n.º 3
0
 public IActionResult LoadIndex(DeliveryItemFilterVM model)
 {
     if (model == null)
     {
         model = new DeliveryItemFilterVM();
     }
     if ((model.FilterType <= 0) || (model.FilterType > NomenclatureConstants.DeliveryItemFilterType.ToOther))
     {
         model.FilterType = NomenclatureConstants.DeliveryItemFilterType.Inner;
     }
     SetViewbag(userContext.CourtId);
     ViewBag.breadcrumbs = commonService.Breadcrumbs_ForDeliveryItems(model.FilterType).DeleteOrDisableLast();
     return(View(model));
 }
Ejemplo n.º 4
0
        public IActionResult Index(string filterJson)
        {
            DeliveryItemFilterVM model = null;

            if (!string.IsNullOrEmpty(filterJson))
            {
                var dateTimeConverter = new IsoDateTimeConverter()
                {
                    DateTimeFormat = FormattingConstant.NormalDateFormat
                };
                model = JsonConvert.DeserializeObject <DeliveryItemFilterVM>(filterJson, dateTimeConverter);
            }
            return(LoadIndex(model));
        }
Ejemplo n.º 5
0
 private int getFilterTypeFromJson(string filterJson)
 {
     try
     {
         var dateTimeConverter = new IsoDateTimeConverter()
         {
             DateTimeFormat = FormattingConstant.NormalDateFormat
         };
         DeliveryItemFilterVM model = JsonConvert.DeserializeObject <DeliveryItemFilterVM>(filterJson, dateTimeConverter);
         return(model.FilterType);
     } catch
     {
         return(0);
     }
 }