public async Task <IActionResult> Create([Bind("ID,FirstName,LastName,Balance")] Students students) { if (ModelState.IsValid) { _context.Add(students); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(students)); }
public async Task <IActionResult> Create([Bind("ID,StudentID,AmountPaid,Date")] Payments payments) { if (ModelState.IsValid) { _context.Add(payments); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(payments)); }