public AlarmPolicyManagementListViewModel(AlarmPolicyManagementListView mWin) { _Window = mWin; Init(); }
/// <summary> /// 报警管理 菜单事件 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> protected void AlermAdmin_Click(object sender, RoutedEventArgs e) { var Menu = sender as MenuItem; if (Menu != null) { string menuName = Menu.Name; string mHeader = Menu.Header.ToString(); DockableContent mWindow = null; switch (menuName) { //一级 [报警管理] case "InspectionList"://[定时巡检设置] mWindow = new InspectionListView(); break; case "KeyWordList"://[关键字配置] mWindow = new KeyWordListView(); break; case "AlarmSetRemove"://[声光告警解除] mWindow = new AlarmSetRemoveView(); break; //二级 [报警管理]-[ 报警管理] case "EventTypeList"://[事件定义] mWindow = new EventTypeListView(); break; case "AlarmPolicyManagementList"://[报警策略管理] mWindow = new AlarmPolicyManagementListView(); break; case "AlarmLevelSet": mWindow = new AlarmLevelSetListView(); break; case "SchedulingList": mWindow = new SchedulingListView(); break; case "AlarmGroupMembersList": mWindow = new AlarmGroupMembersListView(); break; case "AlarmGroupsList": mWindow = new AlarmGroupsListView(); break; case "MainteList": mWindow = new MainteListView(); break; case "DisarmTimeList": mWindow = new DisarmTimeListView(); break; //二级[报警管理]-[误报警管理] case "AlramBindTimeList": mWindow = new AlramBindTimeListView(); break; case "FalseAlarmPolicyList": mWindow = new FalseAlarmPolicyListView(); break; } if (mWindow != null) { mWindow.Title = mHeader; mWindow.ShowAsDocument(dockManager); } } }