Пример #1
0
 public DataLevel(ExternalCommandData commandData)
 {
     doc         = commandData.Application.ActiveUIDocument.Document;
     filterUtils = new FilterUtils(commandData);
     //
     AllLevels        = filterUtils.CollectLevels();
     StructuralLevels = AllLevels.Where(x => x.Name.Contains("结构")).ToList();
 }
        public LevelGenerationViewModel(ExternalCommandData commandData)
        {
            doc         = commandData.Application.ActiveUIDocument.Document;
            filterUtils = new FilterUtils(commandData);
            datalevel   = new DataLevel(commandData);

            GetAturalLevels();

            MockLevels = GetMockLevels();

            SelectionChangedCommand = new DelegateCommand(new Action(SelectionChangedCommandExcute));

            AddLevelCommand    = new DelegateCommand(new Action(AddLevelCommandExcute));
            DeleteLevelCommand = new DelegateCommand(new Action(DeleteLevelCommandExcute));
            UpdateCommand      = new DelegateCommand(new Action(UpdateCommandExcute));
        }