Пример #1
0
        public IActionResult Get(long id)
        {
            var person = _personBusiness.FindByID(id);

            if (person == null)
            {
                return(NotFound());
            }
            return(Ok(person));
        }
Пример #2
0
        [HttpGet("{id}")] // Busca Individual

        public IActionResult Get(long id)
        {
            var person = _personBusiness.FindByID(id);

            if (person == null)
            {
                return(NotFound("Não encontramos! Tente um ID valido"));
            }
            return(Ok(person));
        }
        public IActionResult Get(long id)
        {
            var Token  = Request.Headers["Authorization"];
            var person = _personBusiness.FindByID(id);

            if (person == null)
            {
                return(NotFound());
            }
            return(Ok(person));
        }
Пример #4
0
 public IActionResult Get(long id)
 {
     var person = _personBusiness.FindByID(id);
     if (person == null) return NotFound();
     return Ok(person);
 }