public void DepositAccount(BankAccount account, decimal deposit) { account.Deposit(deposit); BankAccountDTO accToUpdate = AccountMapper.AccountToDTO(account); _repository.UpdateAccount(accToUpdate); }
public void WithdrawAccount(BankAccount account, decimal withdraw) { account.Withdraw(withdraw); BankAccountDTO accToUpdate = AccountMapper.AccountToDTO(account); _repository.UpdateAccount(accToUpdate); }
public void CloseAccount(BankAccount account) { BankAccountDTO accToRemove = AccountMapper.AccountToDTO(account); _repository.RemoveAccount(accToRemove); }