public async Task <IActionResult> Create([Bind("LanguageID,LanguageName")] Language language) { if (ModelState.IsValid) { _context.Add(language); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(language)); }
public async Task <IActionResult> Create(Translator translator) { if (ModelState.IsValid) { _context.Add(translator); await _context.SaveChangesAsync(); return(RedirectToAction("Index")); } return(View(translator)); }