Exemplo n.º 1
0
        public override void setFromSerial(FpmlSerializedCSharp.ISerialized serial_Class)
        {
            FpmlSerializedCSharp.Excel_interface serial_Excel_interface = serial_Class as FpmlSerializedCSharp.Excel_interface;
            FpmlSerializedCSharp.Excel_general   serial_Excel_general   = serial_Excel_interface.Excel_general_;

            FpmlSerializedCSharp.Excel_issueInfo serial_excel_issueInfo = serial_Excel_general.Excel_issueInfo_;
            string excel_issueInfotype = serial_excel_issueInfo.Excel_type_.ValueStr;

            this.excel_issueInfoViewModel_ = Excel_issueInfoViewModel.CreateExcel_issueInfo(excel_issueInfotype);
            this.excel_issueInfoViewModel_.setFromSerial(serial_excel_issueInfo);

            List <FpmlSerializedCSharp.GeneralSchedule> serial_generalSchedule = serial_Excel_general.GeneralSchedule_;

            this.generalScheduleViewModel_ = new ObservableCollection <GeneralScheduleViewModel>();
            foreach (var item in serial_generalSchedule)
            {
                string type = item.Excel_type_.ValueStr;
                GeneralScheduleViewModel viewModel = GeneralScheduleViewModel.CreateGeneralSchedule(type);
                viewModel.setFromSerial(item);
                this.generalScheduleViewModel_.Add(viewModel);
            }

            List <FpmlSerializedCSharp.GeneralTerminationEvent> serial_generalTerminationEvent = serial_Excel_general.GeneralTerminationEvent_;

            this.generalTerminationEventViewModel_ = new ObservableCollection <GeneralTerminationEventViewModel>();
            foreach (var item in serial_generalTerminationEvent)
            {
                string type = item.Excel_type_.ValueStr;
                GeneralTerminationEventViewModel viewModel = GeneralTerminationEventViewModel.CreateGeneralTerminationEvent(type);
                viewModel.setFromSerial(item);
                this.generalTerminationEventViewModel_.Add(viewModel);
            }
        }
 private void terminationDataGrid__SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     this.selectedViewModel_ = this.terminationDataGrid_.SelectedItem as GeneralTerminationEventViewModel;
 }
 private void terminationDataGrid__SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     this.selectedViewModel_ = this.terminationDataGrid_.SelectedItem as GeneralTerminationEventViewModel;
 }