public CustomerInputModel GetFilters()
        {
            var customer = new CustomerInputModel()
            {
                Cities          = _fieldService.GetDropDownList(_cityService.Get()),
                Classifications = _fieldService.GetDropDownList(_classificationService.Get()),
                Regions         = _fieldService.GetDropDownList(_regionService.Get()),
                Genders         = _fieldService.GetDropDownList(_genderService.Get()),
                Sellers         = _fieldService.GetDropDownList(_sellerService.Get())
            };

            return(customer);
        }
Beispiel #2
0
        public ActionResult <BaseResult <List <GenderViewModel> > > Get()
        {
            var result = _genderService.Get();

            if (result.Success)
            {
                var resultMap = _mapper.Map <List <GenderViewModel> >(result.Data);

                return(BaseResult <List <GenderViewModel> > .OK(resultMap));
            }

            return(BaseResult <List <GenderViewModel> > .NotOK(result.Messages));
        }
Beispiel #3
0
        public IActionResult Get([FromQuery] GenderModel model = null, [FromQuery] PaginationModel paginationModel = null, [FromQuery] SortModel sortModel = null)
        {
            if (model == null)
            {
                model = new GenderModel();
            }

            ////region CustomCodeBlockBeforeGet#
            ////endregion CustomCodeBlockBeforeGet#
            var results = _logic.Get(model, paginationModel, sortModel);

            ////region CustomCodeBlockAfterGet#
            ////endregion CustomCodeBlockAfterGet#
            return(this.Ok(results));
        }
 public async Task <ActionResult <IEnumerable <Gender> > > GetGenders()
 {
     return(await _service.Get());
 }
Beispiel #5
0
 public IHttpActionResult Get()
 {
     return(Ok(_service.Get()));
 }