Exemplo n.º 1
0
        public Core.Payment.Entities.BankAccount GetBankAccount(Guid id)
        {
            var bankAccount = BankAccounts
                              .Include(x => x.Bank)
                              .Include(x => x.Bank.Brand)
                              .Include(x => x.PaymentLevels)
                              .Include(x => x.AccountType)
                              .First(x => x.Id == id);

            if (bankAccount == null)
            {
                throw new ArgumentException("Bank not found");
            }
            return(new Core.Payment.Entities.BankAccount(bankAccount));
        }