public AlarmLevelSetEditViewModel(AlarmLevelSetListViewModel _vm, AlarmLevelSetEditView _mw)
        {
            _AlarmLevelSetListVM = _vm;
            _Window = _mw;
            OperationType = OpType.Add;
            AlarmLevelSetObj = new AlarmLevelSetOR();

            Init();
        }
        public AlarmLevelSetEditViewModel(AlarmLevelSetListViewModel _vm, AlarmLevelSetEditView _mw, AlarmLevelSetOR _AlarmLevelSetObj)
        {
            _AlarmLevelSetListVM = _vm;
            _Window = _mw;
            _SourceObj = _AlarmLevelSetObj;

            OperationType = OpType.Alert;
            AlarmLevelSetObj = new AlarmLevelSetOR();
            AlarmLevelSetObj.Clone(_AlarmLevelSetObj);

            Init();
        }
 public override void Insert()
 {
     AlarmLevelSetEditView _sta = new AlarmLevelSetEditView(this);
     _sta.Owner = Global._MainWindow;
     _sta.ShowDialog();
 }
 public override void Update(object par)
 {
     if (par is AlarmLevelSetOR)
     {
         AlarmLevelSetEditView _sta = new AlarmLevelSetEditView(this, par as AlarmLevelSetOR);
         _sta.Owner = Global._MainWindow;
         _sta.ShowDialog();
     }
 }