/// <summary> /// Gets order by location /// </summary> /// <param name="locationId"></param> /// <returns></returns> public List <Order> GetOrderByLocatoinId(int locationId) { List <Order> ordersForCustomer = new List <Order>(); foreach (var item in repo.GetOrderByLocationId(locationId)) { if (item.LocationId == locationId) { ordersForCustomer.Add(item); } } return(ordersForCustomer); }