public async Task <IActionResult> Create([Bind("ID,Username,Password,Access,Status")] User user) { if (ModelState.IsValid) { _context.Add(user); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(user)); }
public async Task <IActionResult> Create([Bind("ID,PublicKey,Fingerprint,CivilStatus,IsAlive")] Record record) { if (ModelState.IsValid) { _context.Add(record); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(record)); }