Пример #1
0
        public IActionResult Get([FromServices] IPersonBusiness personService, [FromServices] IMapper mapper)
        {
            var resultDomain = personService.FindAll();
            var resultVO     = mapper.Map <List <PersonValue> >(resultDomain);

            return(Ok(resultVO));
        }
Пример #2
0
        public IActionResult Get()
        {
            List <Person> person = personBusiness.FindAll();

            if (person == null)
            {
                return(NotFound());
            }

            return(Ok(person));
        }
Пример #3
0
        public ActionResult Get()
        {
            List <PersonVO> pessoas = new List <PersonVO>();

            try
            {
                pessoas = _personBusiness.FindAll().ToList();
            }
            catch (Exception ex)
            {
                throw ex;
            }

            return(Ok(pessoas));
        }
Пример #4
0
 public IActionResult Get()
 {
     try
     {
         var person = _personBusiness.FindAll();
         if (person == null)
         {
             return(NotFound());
         }
         else
         {
             return(Ok(person));
         }
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Пример #5
0
 public IActionResult Get()
 {
     return(Ok(_personBusiness.FindAll()));
 }
        //[Authorize("Bearer")]

        public IActionResult Get()
        {
            return(new OkObjectResult(_personBusiness.FindAll()));
        }
Пример #7
0
 public IActionResult Get()
 {
     return(Ok(_personService.FindAll()));
 }
Пример #8
0
 public IActionResult Get()
 {
     return(Ok(_personRepository.FindAll()));
 }
        public IActionResult Get()
        {
            var res = _personBusiness.FindAll();

            return(Ok(res));
        }
Пример #10
0
 public IActionResult Get(int page, int pageSize)
 {
     return(Ok(_personService.FindAll(page, pageSize)));
 }
Пример #11
0
        public ActionResult Get()
        {
            var persons = _personBusiness.FindAll();

            return(Ok(persons));
        }
Пример #12
0
 public ActionResult <IEnumerable <string> > Get()
 {
     return(Ok(_personBusiness.FindAll()));
 }
Пример #13
0
 // public ActionResult<IEnumerable<string>> Get()
 public IActionResult Get()
 {
     // return new string[] { "value1", "value2" };
     return(Ok(_personBusiness.FindAll()));
 }
Пример #14
0
        public ActionResult Get()
        {
            var persons = _personBusiness.FindAll();

            return(new OkObjectResult(persons));
        }
 public List <Person> FindAll()
 {
     return(_repository.FindAll());
 }
Пример #16
0
 public ActionResult <List <Persons> > Get()
 {
     return(Ok(_personBusiness.FindAll()));
 }