public async Task <ActionResult> Index(OrderSearchCriteriaViewModel criteria) { criteria.Customer = await _customerManager.GetCustomerAsync(criteria.CustomerId); var items = _manager.GetOrdersForCustomer(criteria.CustomerId); //var items = await _manager.GetOrdersForCustomerAsync(criteria.CustomerId); criteria.Orders = items; return(View(criteria)); }
// GET: Order public ActionResult Index() { var vm = new OrderSearchCriteriaViewModel(); return(View(vm)); }