public void RefreshNewOrders() { NewOrders.Clear(); // remove all previous List <NewOrderWPF> NOs = local_lckComm.GetNewOrders(); if (NOs == null) { return; } int idx = 1; foreach (NewOrderWPF no in NOs) { // only add entries added from the other location if (no.StoreOrigin.Id != Globals.SelectedStore.Id) { no.PrintSpecialOrder += PrintSO_Event; no.RemoveNewOrder += RemoveNewOrder; no.ID_UI = idx; NewOrders.Add(no); idx++; } } // notify WCF_CommManager that new orders has changed NewOrder_Event(); }
public void Reload_Orders() { NewOrders.Clear(); foreach (var order in IoC.Application_Work.All_Orders) { if (order.Status == StatusOfProduct.Inpprocessing) { NewOrders.Add(Make_UserProductsViewModel(order)); } } }
public void Set_Orders() { NewOrders.Clear(); ConfirmOrders.Clear(); CurrentOrders.Clear(); foreach (var order in IoC.Application_Work.All_Orders) { if (order.Status == StatusOfProduct.Inpprocessing || order.Status == StatusOfProduct.HoldDispetcherToDriverAccept) { NewOrders.Add(Make_UserProductsViewModel(order)); } else if (order.Status == StatusOfProduct.Current) { CurrentOrders.Add(Make_UserProductsViewModel(order)); } else if (order.Status == StatusOfProduct.Completed) { ConfirmOrders.Add(Make_UserProductsViewModel(order)); } } }