public async Task <WithdrawAccountDto> UpdateAsync(Guid id, WithdrawAccountCreateUpdateDto input) { var account = await _repository.GetAsync(id); account.Update(input.AccountType, input.Account, input.IsDefault, input.Description); return(ObjectMapper.Map <WithdrawAccount, WithdrawAccountDto>(account)); }
public async Task <WithdrawAccountDto> CreateAsync(WithdrawAccountCreateUpdateDto input) { var account = new WithdrawAccount(GuidGenerator.Create(), CurrentUser.TenantId, input.AccountType, input.Account, input.IsDefault, input.Description); await _repository.InsertAsync(account); return(ObjectMapper.Map <WithdrawAccount, WithdrawAccountDto>(account)); }
public Task <WithdrawAccountDto> UpdateAsync(Guid id, WithdrawAccountCreateUpdateDto input) { return(_service.UpdateAsync(id, input)); }
public Task <WithdrawAccountDto> CreateAsync(WithdrawAccountCreateUpdateDto input) { return(_service.CreateAsync(input)); }