public async Task <IActionResult> Create([Bind("ProtocolCode,Description")] Protocol protocol) { if (ModelState.IsValid) { _context.Add(protocol); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(protocol)); }
public async Task <IActionResult> Create([Bind("EnvironmentCode,Description")] Context.Environment environment) { if (ModelState.IsValid) { _context.Add(environment); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(environment)); }