private void CheckStoreOpenCloseTimes() { // ACPRO 119776: If a store has corrently no timerange at all or a time range is insert, // but it has no values in it (e.g. MO-SU is empty then the notification mamanger at login shall // warn the store manager and all users who own the market) long[] storeIDWithEmptyOpenCloseTimes = ClientEnvironment.StoreService.GetStoreEmptyOpenCloseTimeList(_currentUser.ID); IStoreService storeService = ClientEnvironment.StoreService; List <Store> stores = storeService.FindByIDList(new List <long>(storeIDWithEmptyOpenCloseTimes)); if (stores != null && stores.Count > 0) { UCStoresListNotification displayUC = new UCStoresListNotification(); displayUC.StoresList = stores; _notificationForm.AddResultItem(Localizer.GetLocalized("WarnNoOpenCloseTime"), displayUC); } }
private void CheckNeedToMergeExternalEmployees() { // ACPRO 119082 Wether an employee is now available (due to latest import) // that has the same name and same firstname as an unmigrated external employee // (=> so user can start migrate usecase of this external user) // acpro item #119082 // "The notification wether an external employee data is available for mergeing shall come for all userclass please!" //if(!IsAdminOrCountryManager()) //{ // return; //} long[][] needMergeEmployee = ClientEnvironment.EmployeeService.GetEmployeeToMergeList(); IDictionary <long, Store> storesMap = new Dictionary <long, Store>(); IStoreService storeService = ClientEnvironment.StoreService; for (int idx = 0; idx < needMergeEmployee.Length; idx++) { if (!storesMap.ContainsKey(needMergeEmployee[idx][1])) { Store store = storeService.FindById(needMergeEmployee[idx][1]); if (store != null) { storesMap.Add(store.ID, store); } } } // Create UI if (storesMap.Count > 0) { UCStoresListNotification displayUC = new UCStoresListNotification(); displayUC.StoresList = new List <Store>(storesMap.Values); _notificationForm.AddResultItem(Localizer.GetLocalized("WarnNeedMergeEmployees"), displayUC); } }
private void CheckStoreOpenCloseTimes() { // ACPRO 119776: If a store has corrently no timerange at all or a time range is insert, // but it has no values in it (e.g. MO-SU is empty then the notification mamanger at login shall // warn the store manager and all users who own the market) long[] storeIDWithEmptyOpenCloseTimes = ClientEnvironment.StoreService.GetStoreEmptyOpenCloseTimeList(_currentUser.ID); IStoreService storeService = ClientEnvironment.StoreService; List<Store> stores = storeService.FindByIDList(new List<long>(storeIDWithEmptyOpenCloseTimes)); if(stores != null && stores.Count > 0) { UCStoresListNotification displayUC = new UCStoresListNotification(); displayUC.StoresList = stores; _notificationForm.AddResultItem(Localizer.GetLocalized("WarnNoOpenCloseTime"), displayUC); } }
private void CheckNeedToMergeExternalEmployees() { // ACPRO 119082 Wether an employee is now available (due to latest import) // that has the same name and same firstname as an unmigrated external employee // (=> so user can start migrate usecase of this external user) // acpro item #119082 // "The notification wether an external employee data is available for mergeing shall come for all userclass please!" //if(!IsAdminOrCountryManager()) //{ // return; //} long[][] needMergeEmployee = ClientEnvironment.EmployeeService.GetEmployeeToMergeList(); IDictionary<long, Store> storesMap = new Dictionary<long, Store>(); IStoreService storeService = ClientEnvironment.StoreService; for(int idx = 0; idx < needMergeEmployee.Length; idx++) { if(!storesMap.ContainsKey(needMergeEmployee[idx][1])) { Store store = storeService.FindById(needMergeEmployee[idx][1]); if(store != null) { storesMap.Add(store.ID, store); } } } // Create UI if(storesMap.Count > 0) { UCStoresListNotification displayUC = new UCStoresListNotification(); displayUC.StoresList = new List<Store>(storesMap.Values); _notificationForm.AddResultItem(Localizer.GetLocalized("WarnNeedMergeEmployees"), displayUC); } }