Ejemplo n.º 1
0
        public async Task <Result> UpdateAddressTypeAsync(AddressTypeViewModel model)
        {
            var data = _iMapper.Map <AddressTypeViewModel, AddressType>(model);

            var saveChange = await _iAddressTypeRepository.UpdateAddressTypeAsync(data);

            if (saveChange > 0)
            {
                return(Result.Ok(MessageHelper.Update));
            }
            else
            {
                return(Result.Fail(MessageHelper.UpdateFail));
            }
        }