Exemple #1
0
        public override Result <Address> Update(AddressModel model)
        {
            try
            {
                Address address = _mapper.Map <Address>(model);

                var result = _addressValidation.Validate(address);
                if (!result.Success)
                {
                    return(result);
                }

                _addressDAL.Update(address);
                return(Result <Address> .BuildSuccess(address));
            }
            catch (Exception error)
            {
                return(Result <Address> .BuildError("Erro ao alterar o registro do endereço.", error));
            }
        }
Exemple #2
0
 public bool Update(Address address)
 {
     return(_addressDAL.Update(address));
 }
Exemple #3
0
 public bool Update(Address model)
 {
     return(_addressDAL.Update(model) > 0);
 }
 public bool Update(Address entity)
 {
     return(_addressDAL.Update(entity) > 0);
 }