Beispiel #1
0
        public async Task <ActionResult <PersonPhoneResponse> > Put([FromBody] PersonPhoneListRequest personPhoneRequest)
        {
            try
            {
                ActionResult <PersonPhoneResponse> response = null;

                foreach (var personPhone in personPhoneRequest.Phones)
                {
                    response = Response(await _facade.PutAsync(personPhone));
                }

                return(response);
            }
            catch (Exception ex)
            {
                var result = BadRequest(ex.Message);
                return(result);
            }
        }
Beispiel #2
0
 public async Task <ActionResult <PersonPhoneResponse> > Put(string previosKeys, [FromBody] PersonPhoneRequest request) =>
 Response(await _personPhoneFacade.PutAsync(previosKeys, _mapper.Map <PersonPhoneDto>(request)));