示例#1
0
        public IActionResult GetCidadeEstado(string estado)
        {
            var cidade = _cidadeService.GetByEstado(estado);

            if (cidade == null)
            {
                return(NotFound());
            }
            else
            {
                return(new ObjectResult(cidade));
            }
        }
示例#2
0
 public async Task <CustomResponse <IList <Cidade> > > GetByEstado([FromBody] Estado estado)
 {
     return(await _service.GetByEstado(estado.EstadoId));
 }