Example #1
0
        public async Task <ActionResult <IList <Model.Receita> > > GetAsync()
        {
            try
            {
                var receitas = await _service.GetAllAsync();

                return(new OkObjectResult(receitas));
            }
            catch (Exception ex)
            {
                return(new BadRequestObjectResult(ex));
            }
        }