public async Task <IActionResult> Create([Bind("Id,Name,Address")] Customer customer) { if (ModelState.IsValid) { _context.Add(customer); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(customer)); }
public async Task <IActionResult> Create([Bind("Id,OrderDate")] Orders orders) { if (ModelState.IsValid) { _context.Add(orders); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(orders)); }
public async Task <IActionResult> Create([Bind("Id,Gender,Price,Style,Image,Color,Size")] Shoes shoes) { if (ModelState.IsValid) { _context.Add(shoes); await _context.SaveChangesAsync(); return(RedirectToAction(nameof(Index))); } return(View(shoes)); }