コード例 #1
0
 public CheckingAccount SaveCheckingAccount(CheckingAccount checkingAccount)
 {
     this.applicationDbContext.Entry(checkingAccount).State = EntityState.Modified;
     this.applicationDbContext.SaveChanges();
     return(checkingAccount);
 }
コード例 #2
0
        public CheckingAccount GetAccountByNumber(string accountNumber)
        {
            CheckingAccount checkingAccount = this.applicationDbContext.CheckingAccounts.Where(c => c.AccountNumber == accountNumber).FirstOrDefault <CheckingAccount>();

            return(checkingAccount);
        }
コード例 #3
0
 public CheckingAccount AddCheckingAccount(CheckingAccount checkingAccount)
 {
     this.applicationDbContext.CheckingAccounts.Add(checkingAccount);
     this.applicationDbContext.SaveChanges();
     return(checkingAccount);
 }
コード例 #4
0
        public CheckingAccount GetCheckingAccountById(int id)
        {
            CheckingAccount checkingAccount = this.applicationDbContext.CheckingAccounts.Where(c => c.Id == id).FirstOrDefault <CheckingAccount>();

            return(checkingAccount);
        }