public GVSectionViewModel(NavigationController controller, LegSectionViewModel prev, int number) : base(controller, prev)
 {
     ListNumber      = number;
     StructureSource = new ObservableCollection <LegPartDbStructure>(Data.GV.LevelStructures(number).ToList());
     foreach (var structure in StructureSource)
     {
         structure.Metrics = Data.Metrics.GetStr(structure.Size);
     }
     AddCustomObject(typeof(GVStructure));
     AddNextPartObject(typeof(GVStructure));
     AddEmpty(typeof(GVStructure));
     CurrentEntry = new GVEntry();
 }
示例#2
0
        public SPSAdditionalSectionViewModel(NavigationController controller, LegSectionViewModel prevSection, int number) : base(controller, prevSection)
        {
            ListNumber      = number;
            StructureSource = new ObservableCollection <LegPartDbStructure>(base.Data.SPS.LevelStructures(number).ToList());
            foreach (var structure in StructureSource)
            {
                structure.Metrics = Data.Metrics.GetStr(structure.Size);
            }

            AddCustomObject(typeof(SPSHipStructure));

            AddEmpty(typeof(SPSHipStructure));
            CurrentEntry = new SPSHipEntry();
        }