public void Initialize() { _importPath = System.IO.Path.Combine(Environment.CurrentDirectory, @"Ressources\Configuration.xlsx"); _exportPath = System.IO.Path.Combine(Environment.CurrentDirectory, @"Ressources\UnitTest.xlsx"); _wvm = WorkspaceViewModel.Instance; _groupTableVm = new GroupTableViewModel(); _wvm.LoadWorkspace(_importPath); _impExcel = ImportExcel.Instance; _exExcel = TreatPraktik.ViewModel.ExportExcel.Instance; //Get original lists of worksheets _oldExGroup = (from a in _impExcel._workSheetktExaminedGroup.ExaminedGroupList select new ktExaminedGroup { DataQualityScore = a.DataQualityScore, Expanded = a.Expanded, GroupExpendable = a.GroupExpendable, GroupIdentifier = a.GroupIdentifier, GroupType = a.GroupType, ID = a.ID, Name = a.Name, RequiredScore = a.RequiredScore }).ToList(); _oldGroupOrder = (from a in _impExcel._workSheetktUIGroupOrder.ktUIGroupOrderList select new ktUIGroupOrder { DepartmentID = a.DepartmentID, GroupOrder = a.GroupOrder, GroupTypeID = a.GroupTypeID, PageTypeID = a.PageTypeID }).ToList(); _oldOrder = (from a in _impExcel._workSheetktUIOrder.ktUIOrderList select new ktUIOrder { DesignID = a.DesignID, GroupOrder = a.GroupOrder, GroupTypeID = a.GroupTypeID, IncludedTypeID = a.IncludedTypeID, PageTypeID = a.PageTypeID }).ToList(); _oldResources = (from a in _impExcel._workSheetktResources.ktResourceList select new ktResources { ResourceID = a.ResourceID, ResourceResxID = a.ResourceResxID, ResourceTypeID = a.ResourceTypeID }).ToList(); _oldResTranslation = (from a in _impExcel._workSheetktResourceTranslation.ktResourceTranslationList select new ktResourceTranslation { LanguageID = a.LanguageID, ResourceID = a.ResourceID, TranslationText = a.TranslationText }).ToList(); }
public void Initialize() { string importPath = System.IO.Path.Combine(Environment.CurrentDirectory, @"Ressources\Configuration.xlsx"); ifvm = ToolboxStandardItemsViewModel.Instance; glvm = ToolboxGroupsViewModel.Instance; WorkspaceViewModel.Instance = null; wvm = WorkspaceViewModel.Instance; wvm.LoadWorkspace(importPath); ifvm.PopulateToolbox(); glvm.PopulateGTList(); sfvm = new ToolboxSpecialItemsViewModel(); gtvm = new GroupTableViewModel(); }