public IActionResult MarkShipped(int orderID) { Order order = repository.Orders.FirstOrDefault(p => p.OrderID == orderID); if (order != null) { order.Shipped = true; repository.SaveOrder(order); } return(RedirectToAction(nameof(List))); }
public IActionResult MarkShipped(int orderID) { Order order = repository.Orders.FirstOrDefault(p => p.OrderID == orderID); if (order != null) { order.Shipped = true; repository.SaveOrder(order); } return(RedirectToAction(nameof(List))); }