From 6936ebf1dfbd0025d3e86ae7dde316b6a6e43b9b Mon Sep 17 00:00:00 2001 From: duheng <2784771470@qq.com> Date: 星期二, 24 十二月 2024 16:40:23 +0800 Subject: [PATCH] Merge branch 'master' of http://47.103.154.90:83/r/HStation/XHS.V1.0 --- WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/XhsProjectSimulationMgrPage.cs | 82 +++++++++++++++++++++++++++++++++++++++-- 1 files changed, 78 insertions(+), 4 deletions(-) diff --git a/WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/XhsProjectSimulationMgrPage.cs b/WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/XhsProjectSimulationMgrPage.cs index 3389cf2..f437feb 100644 --- a/WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/XhsProjectSimulationMgrPage.cs +++ b/WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/XhsProjectSimulationMgrPage.cs @@ -18,14 +18,18 @@ this.simulationFunctionMgrCtrl1.ShowProjectSiteInfoEvent += SimulationFunctionMgrCtrl1_ShowProjectSiteInfoEvent; this.simulationFunctionMgrCtrl1.ShowProjectSiteSimulationEvent += SimulationFunctionMgrCtrl1_ShowProjectSiteSimulationEvent; this.simulationFunctionMgrCtrl1.ShowProjectSiteWorkingEvent += SimulationFunctionMgrCtrl1_ShowProjectSiteWorkingEvent; + this.simulationFunctionMgrCtrl1.ProjectSiteWorkingAppendEvent += SimulationFunctionMgrCtrl1_ProjectSiteWorkingAppendEvent; this.simulationFunctionMgrCtrl1.ProjectSiteWorkingUpdateEvent += SimulationFunctionMgrCtrl1_ProjectSiteWorkingUpdateEvent; this.simulationFunctionMgrCtrl1.ProjectSiteWorkingRemoveEvent += SimulationFunctionMgrCtrl1_ProjectSiteWorkingRemoveEvent; this.simulationFunctionMgrCtrl1.ProjectSiteWorkingCheckedEvent += SimulationFunctionMgrCtrl1_ProjectSiteWorkingCheckedEvent; this.simulationFunctionMgrCtrl1.CreateProjectSiteSchemeEvent += SimulationFunctionMgrCtrl1_CreateProjectSiteSchemeEvent; + this.simulationFunctionMgrCtrl1.ProjectSiteSchemeAppendEvent += SimulationFunctionMgrCtrl1_ProjectSiteSchemeAppendEvent; + this.simulationFunctionMgrCtrl1.ProjectSiteSchemeUpdateEvent += SimulationFunctionMgrCtrl1_ProjectSiteSchemeUpdateEvent; + this.simulationFunctionMgrCtrl1.ProjectSiteSchemeRemoveEvent += SimulationFunctionMgrCtrl1_ProjectSiteSchemeRemoveEvent; } private XhsProjectVmo _project = null;//椤圭洰 - private object _locker = new object();//閿佸畾瀵硅薄 + private object _locker = new();//閿佸畾瀵硅薄 /// <summary> /// 鍒濆鍖栨暟鎹簮 @@ -118,15 +122,28 @@ page.PageTitle.HeaderSvgImage = svgImage; page.AppendWorkingEvent += (working) => { + //澧炲姞宸ュ喌浜嬩欢 this.simulationFunctionMgrCtrl1.AppendWorking(scheme, working); }; page.SaveModelEvent += (rhs) => { + //淇濆瓨妯″瀷浜嬩欢 return this.simulationFunctionMgrCtrl1.SaveModel(scheme, rhs); }; page.RefreshModelEvent += () => { + //鍒锋柊妯″瀷浜嬩欢 return this.simulationFunctionMgrCtrl1.RefreshModel(scheme); + }; + page.UpdateSchemeEvent += (rhs) => + { + //鏇存柊鏂规浜嬩欢 + this.simulationFunctionMgrCtrl1.UpdateScheme(rhs); + }; + page.RemoveSchemeEvent += (rhs) => + { + //绉婚櫎鏂规浜嬩欢 + this.simulationFunctionMgrCtrl1.RemoveScheme(rhs); }; page.SetBindingData(project, projectSite, scheme, hydroInfo, allWorkingCheckedListDict); CreatePage(page, guid); @@ -172,6 +189,20 @@ } } + /// <summary> + /// 椤圭洰绔欏伐鍐靛鍔犱簨浠� + /// </summary> + private void SimulationFunctionMgrCtrl1_ProjectSiteWorkingAppendEvent + ( + XhsProjectVmo project, + XhsProjectSiteVmo projectSite, + XhsSchemeVmo scheme, + HydroWorkingVmo working + ) + { + //鐩墠澧炲姞宸ュ喌閮芥槸閫氳繃妯℃嫙鐣岄潰澧炲姞鐨勶紝鍔熻兘绠$悊鎺т欢灞炰簬琚�氱煡鐨勶紝鍏朵粬鍦版柟鏆傛椂涓嶅叧蹇冨伐鍐靛鍔� + } + //椤圭洰绔欏伐鍐垫洿鏂颁簨浠� private void SimulationFunctionMgrCtrl1_ProjectSiteWorkingUpdateEvent ( @@ -186,7 +217,7 @@ Modular = this.PageGuid.Modular, MoudingType = eMoudingType.Tab, Function = SimulationFunctionHelper.Simulation, - TagName = projectSite.ID.ToString() + TagName = $"{project.ID}-{projectSite.ID}-{scheme?.ID}" }; var page = FindPage(guid); if (page == null) @@ -269,17 +300,60 @@ SvgImage svgImage ) { + //WaitFormHelper.ShowWaitForm(this.FindForm(), "姝e湪鍔犺浇妯″瀷锛岃绋嶄警..."); + //var dlg = new AddXhsSchemeDlg(); + //dlg.Shown += delegate { WaitFormHelper.HideWaitForm(this.FindForm()); }; + //dlg.ReloadDataEvent += (rhs) => + //{ + // this.simulationFunctionMgrCtrl1.AppendScheme(rhs); + //}; + //dlg.SetBindingData(project, projectSite, hydroInfo); + //dlg.ShowDialog(); + WaitFormHelper.ShowWaitForm(this.FindForm(), "姝e湪鍔犺浇妯″瀷锛岃绋嶄警..."); - var dlg = new AddXhsSchemeDlg(); + var dlg = new CreateXhsSchemeDlg(); dlg.Shown += delegate { WaitFormHelper.HideWaitForm(this.FindForm()); }; + dlg.SetBindingData(project, projectSite, hydroInfo); dlg.ReloadDataEvent += (rhs) => { this.simulationFunctionMgrCtrl1.AppendScheme(rhs); }; - dlg.SetBindingData(project, projectSite, hydroInfo); dlg.ShowDialog(); } + //椤圭洰绔欐柟妗堝鍔犱簨浠� + private void SimulationFunctionMgrCtrl1_ProjectSiteSchemeAppendEvent + ( + XhsProjectVmo project, + XhsProjectSiteVmo projectSite, + XhsSchemeVmo scheme + ) + { + //琚姩 + } + + //椤圭洰绔欐柟妗堟洿鏂颁簨浠� + private void SimulationFunctionMgrCtrl1_ProjectSiteSchemeUpdateEvent + ( + XhsProjectVmo project, + XhsProjectSiteVmo projectSite, + XhsSchemeVmo scheme + ) + { + //琚姩 + } + + //椤圭洰绔欐柟妗堢Щ闄や簨浠� + private void SimulationFunctionMgrCtrl1_ProjectSiteSchemeRemoveEvent + ( + XhsProjectVmo project, + XhsProjectSiteVmo projectSite, + XhsSchemeVmo scheme + ) + { + //琚姩 + } + #endregion #region TabbedView 鐩稿叧浜嬩欢澶勭悊绋嬪簭 -- Gitblit v1.9.3