public virtual async Task UpdateAddressInfo(CreateAddressInfo input) { var AddressInfo = await _NewAddressInfoRepository.GetAsync(input.Id); ObjectMapper.Map(input, AddressInfo); await _NewAddressInfoRepository.UpdateAsync(AddressInfo); }
public async Task CreateOrUpdateAddressInfo(CreateAddressInfo input) { if (input.Id == 0) { await CreateAddressInfo(input); } else { await UpdateAddressInfo(input); } }
public virtual async Task CreateAddressInfo(CreateAddressInfo input) { var AddressInfos = input.MapTo <AddressInfo>(); await _NewAddressInfoRepository.InsertAsync(AddressInfos); }