void loadOperationFileType_Completed(object sender, EventArgs e) { FileTypeEntityDictionary.Clear(); FileTypeEntityList.Clear(); LoadOperation loadOperation = sender as LoadOperation; foreach (ProductManager.Web.Model.filetype filetype in loadOperation.Entities) { FileTypeEntity fileTypeEntity = new FileTypeEntity(); fileTypeEntity.FileType = filetype; fileTypeEntity.Update(); FileTypeEntityDictionary.Add(fileTypeEntity.FileTypeID, fileTypeEntity); FileTypeEntityList.Add(fileTypeEntity); } LoadOperation<ProductManager.Web.Model.product_type> loadOperationProductType = SystemManageDomainContext.Load<ProductManager.Web.Model.product_type>(SystemManageDomainContext.GetProduct_typeQuery()); loadOperationProductType.Completed += loadOperationProductType_Completed; }
void loadOperationFileType_Completed(object sender, EventArgs e) { FileTypeEntityDictionary.Clear(); FileTypeEntityList.Clear(); LoadOperation loadOperation = sender as LoadOperation; foreach (ProductManager.Web.Model.filetype filetype in loadOperation.Entities) { FileTypeEntity fileTypeEntity = new FileTypeEntity(); fileTypeEntity.FileType = filetype; fileTypeEntity.Update(); FileTypeEntityDictionary.Add(fileTypeEntity.FileTypeID, fileTypeEntity); FileTypeEntityList.Add(fileTypeEntity); } this.prjectSource = new EntityList<ProductManager.Web.Model.project>(this.ProductDomainContext.projects); this.projectLoader = new DomainCollectionViewLoader<ProductManager.Web.Model.project>( this.LoadProjectEntities, this.LoadOperationProjectCompleted); this.projectView = new DomainCollectionView<ProductManager.Web.Model.project>(this.projectLoader, this.prjectSource); using (this.CollectionProjectView.DeferRefresh()) { this.projectView.MoveToFirstPage(); } this.IsBusy = false; }
void loadOperationFileType_Completed(object sender, EventArgs e) { FileTypeEntityList.Clear(); LoadOperation loadOperation = sender as LoadOperation; foreach (ProductManager.Web.Model.filetype filetype in loadOperation.Entities) { FileTypeEntity fileTypeEntity = new FileTypeEntity(); fileTypeEntity.FileType = filetype; fileTypeEntity.Update(); FileTypeEntityList.Add(fileTypeEntity); } UpdateChanged("FileTypeEntityList"); IsBusy = false; }