public async Task Add(IAccount account, ICredit credit) { await _context.Accounts.AddAsync((Account)account); await _context.Credits.AddAsync((Credit)credit); await _context.SaveChangesAsync(); }
public async Task Add(ICustomer customer) { await _context.Customers.AddAsync((Customer)customer); await _context.SaveChangesAsync(); }
public async Task <int> Save() { int affectedRows = await context.SaveChangesAsync(); return(affectedRows); }