Ejemplo n.º 1
0
        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);
        }
Ejemplo n.º 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));
        }
Ejemplo n.º 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));
        }
Ejemplo n.º 4
0
 public async Task <ActionResult <IEnumerable <Gender> > > GetGenders()
 {
     return(await _service.Get());
 }
Ejemplo n.º 5
0
 public IHttpActionResult Get()
 {
     return(Ok(_service.Get()));
 }