From 1b7957fac12e80698971513b30e65772c4c5c038 Mon Sep 17 00:00:00 2001 From: duheng <2784771470@qq.com> Date: 星期一, 13 一月 2025 18:32:53 +0800 Subject: [PATCH] 修复显示问题 --- WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/XhsProjectSimulationMgrPage.cs | 66 +++------------------------------ 1 files changed, 6 insertions(+), 60 deletions(-) diff --git a/WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/XhsProjectSimulationMgrPage.cs b/WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/XhsProjectSimulationMgrPage.cs index f437feb..7db75a9 100644 --- a/WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/XhsProjectSimulationMgrPage.cs +++ b/WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/XhsProjectSimulationMgrPage.cs @@ -1,5 +1,4 @@ -锘縰sing DevExpress.Drawing; -using DevExpress.Utils.Svg; +锘縰sing DevExpress.Utils.Svg; using DevExpress.XtraBars.Docking; using DevExpress.XtraBars.Docking2010.Views; using Yw.Vmo; @@ -17,7 +16,6 @@ this.PageTitle.SvgImageSize = new Size(24, 24); 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; @@ -125,11 +123,6 @@ //澧炲姞宸ュ喌浜嬩欢 this.simulationFunctionMgrCtrl1.AppendWorking(scheme, working); }; - page.SaveModelEvent += (rhs) => - { - //淇濆瓨妯″瀷浜嬩欢 - return this.simulationFunctionMgrCtrl1.SaveModel(scheme, rhs); - }; page.RefreshModelEvent += () => { //鍒锋柊妯″瀷浜嬩欢 @@ -146,44 +139,6 @@ this.simulationFunctionMgrCtrl1.RemoveScheme(rhs); }; page.SetBindingData(project, projectSite, scheme, hydroInfo, allWorkingCheckedListDict); - CreatePage(page, guid); - } - } - } - - //鏄剧ず椤圭洰绔欏伐鍐典簨浠� - private void SimulationFunctionMgrCtrl1_ShowProjectSiteWorkingEvent - ( - XhsProjectVmo project, - XhsProjectSiteVmo projectSite, - XhsSchemeVmo scheme, - Yw.Model.HydroModelInfo hydroInfo, - HydroWorkingVmo working, - SvgImage svgImage - ) - { - lock (_locker) - { - var guid = new PageGuid() - { - Modular = this.PageGuid.Modular, - MoudingType = eMoudingType.Tab, - Function = SimulationFunctionHelper.Working, - TagName = $"{project.ID}-{projectSite.ID}-{scheme?.ID}-{working.ID}" - }; - if (!IsExistPage(guid, true)) - { - var page = new XhsProjectSimulationWorkingPage(); - page.UpdateWorkingEvent += (rhs) => - { - this.simulationFunctionMgrCtrl1.UpdateWorking(scheme, rhs); - }; - page.RemoveWorkingEvent += (rhs) => - { - this.simulationFunctionMgrCtrl1.RemoveWorking(scheme, rhs); - }; - page.PageTitle.HeaderSvgImage = svgImage; - page.SetBindingData(project, projectSite, scheme, hydroInfo, working); CreatePage(page, guid); } } @@ -246,7 +201,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) @@ -276,7 +231,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) @@ -297,23 +252,14 @@ XhsProjectVmo project, XhsProjectSiteVmo projectSite, Yw.Model.HydroModelInfo hydroInfo, + List<XhsSchemeVmo> allSchemeList, 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湪鍔犺浇妯″瀷锛岃绋嶄警..."); + WaitFormHelper.ShowWaitForm(this.FindForm(), "姝e湪鍔犺浇锛岃绋嶄警..."); var dlg = new CreateXhsSchemeDlg(); dlg.Shown += delegate { WaitFormHelper.HideWaitForm(this.FindForm()); }; - dlg.SetBindingData(project, projectSite, hydroInfo); + dlg.SetBindingData(project, projectSite, hydroInfo, allSchemeList); dlg.ReloadDataEvent += (rhs) => { this.simulationFunctionMgrCtrl1.AppendScheme(rhs); -- Gitblit v1.9.3