private void LoadSpecification() { ServiceZipList.Clear(); EmptyZipsList.Clear(); NewZipList.Clear(); _reportsController.ShowDialogWindow(); foreach (var serviceZip in _excelSpecificationLoader.GetServiceZips(SelectedCompany, _specFileName, SelectedMonth, SelectedYear).Result) { ServiceZipList.Add(serviceZip); } foreach (var serviceZip in ServiceZipList) { if (!ZipList.Any(z => z.ZipName.ToLower() == serviceZip.ZipName.ToLower())) { if (!NewZipList.Any(e => e.ZipName.ToLower() == serviceZip.ZipName.ToLower())) { NewZipList.Add(new ZipSet { ZipName = serviceZip.ZipName }); } } } }
private void SaveEmptyZips() { _zipService.UpdateMainZip(EmptyZipsList.Where(z => !string.IsNullOrWhiteSpace(z.MainZipName))); RefreshEmptyList(); }
private void RefreshEmptyList() { EmptyZipsList.Clear(); EmptyZipsList = new ObservableCollection <ZipSet>(_zipService.GetEmptyZips()); }
public override void OnNavigatedTo(NavigationContext navigationContext) { EmptyZipsList.Clear(); ZipList = _zipService.GetZips(); MainZipList = _zipService.GetMainZips(); }