public async Task <IActionResult> Create([Bind("Id,Name")] Department departament) { if (ModelState.IsValid) { _context.Add(departament); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(departament)); }
public async Task InsertAsync(Seller obj) { _context.Add(obj); await _context.SaveChangesAsync(); }