WinFrmUI/HStation.WinFrmUI.Xhs.Core/04-simulation/06-simulation/02-check/XhsProjectSimulationHydroCheckFailedCtrl.Designer.cs
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,115 @@ namespace HStation.WinFrmUI { partial class XhsProjectSimulationHydroCheckFailedCtrl { /// <summary> /// Required designer variable. /// </summary> private System.ComponentModel.IContainer components = null; /// <summary> /// Clean up any resources being used. /// </summary> /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param> protected override void Dispose(bool disposing) { if (disposing && (components != null)) { components.Dispose(); } base.Dispose(disposing); } #region Component Designer generated code /// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { components = new Container(); gridControl1 = new DevExpress.XtraGrid.GridControl(); xhsProjectSimulationHydroCheckFailedViewModelBindingSource = new BindingSource(components); gridView1 = new DevExpress.XtraGrid.Views.Grid.GridView(); colParterId = new DevExpress.XtraGrid.Columns.GridColumn(); colFailType = new DevExpress.XtraGrid.Columns.GridColumn(); colFailReason = new DevExpress.XtraGrid.Columns.GridColumn(); ((ISupportInitialize)gridControl1).BeginInit(); ((ISupportInitialize)xhsProjectSimulationHydroCheckFailedViewModelBindingSource).BeginInit(); ((ISupportInitialize)gridView1).BeginInit(); SuspendLayout(); // // gridControl1 // gridControl1.DataSource = xhsProjectSimulationHydroCheckFailedViewModelBindingSource; gridControl1.Dock = DockStyle.Fill; gridControl1.Location = new Point(0, 0); gridControl1.MainView = gridView1; gridControl1.Name = "gridControl1"; gridControl1.Size = new Size(822, 448); gridControl1.TabIndex = 1; gridControl1.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] { gridView1 }); // // xhsProjectSimulationHydroCheckFailedViewModelBindingSource // xhsProjectSimulationHydroCheckFailedViewModelBindingSource.DataSource = typeof(XhsProjectSimulationHydroCheckFailedViewModel); // // gridView1 // gridView1.Columns.AddRange(new DevExpress.XtraGrid.Columns.GridColumn[] { colParterId, colFailType, colFailReason }); gridView1.GridControl = gridControl1; gridView1.Name = "gridView1"; gridView1.RowClick += gridView1_RowClick; // // colParterId // colParterId.FieldName = "ParterId"; colParterId.MaxWidth = 250; colParterId.MinWidth = 150; colParterId.Name = "colParterId"; colParterId.Visible = true; colParterId.VisibleIndex = 0; colParterId.Width = 150; // // colFailType // colFailType.FieldName = "FailType"; colFailType.MaxWidth = 300; colFailType.MinWidth = 200; colFailType.Name = "colFailType"; colFailType.Visible = true; colFailType.VisibleIndex = 1; colFailType.Width = 250; // // colFailReason // colFailReason.FieldName = "FailReason"; colFailReason.Name = "colFailReason"; colFailReason.Visible = true; colFailReason.VisibleIndex = 2; colFailReason.Width = 321; // // XhsProjectSimulationHydroCheckFailedCtrl // AutoScaleDimensions = new SizeF(7F, 14F); AutoScaleMode = AutoScaleMode.Font; Controls.Add(gridControl1); Name = "XhsProjectSimulationHydroCheckFailedCtrl"; Size = new Size(822, 448); ((ISupportInitialize)gridControl1).EndInit(); ((ISupportInitialize)xhsProjectSimulationHydroCheckFailedViewModelBindingSource).EndInit(); ((ISupportInitialize)gridView1).EndInit(); ResumeLayout(false); } #endregion private DevExpress.XtraGrid.GridControl gridControl1; private DevExpress.XtraGrid.Views.Grid.GridView gridView1; private DevExpress.XtraGrid.Columns.GridColumn colParterId; private DevExpress.XtraGrid.Columns.GridColumn colFailType; private DevExpress.XtraGrid.Columns.GridColumn colFailReason; private BindingSource xhsProjectSimulationHydroCheckFailedViewModelBindingSource; } } WinFrmUI/HStation.WinFrmUI.Xhs.Core/04-simulation/06-simulation/02-check/XhsProjectSimulationHydroCheckFailedCtrl.cs
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,60 @@ using DevExpress.XtraEditors; using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Threading.Tasks; using System.Windows.Forms; namespace HStation.WinFrmUI { public partial class XhsProjectSimulationHydroCheckFailedCtrl : DevExpress.XtraEditors.XtraUserControl { public XhsProjectSimulationHydroCheckFailedCtrl() { InitializeComponent(); this.gridView1.SetNormalView(30); this.gridView1.RegistCustomDrawRowIndicator(40); } /// <summary> /// ç¹å»æä»¶äºä»¶ /// </summary> public event Action<string> HydroClickEvent; private List<XhsProjectSimulationHydroCheckFailedViewModel> _allBindingList = null; /// <summary> /// ç»å®æ°æ® /// </summary> public void SetBindingData(List<Yw.EPAnet.CheckFailed> allFailedList) { _allBindingList = new List<XhsProjectSimulationHydroCheckFailedViewModel>(); if (allFailedList != null && allFailedList.Count > 0) { foreach (var failed in allFailedList) { var vm = new XhsProjectSimulationHydroCheckFailedViewModel(failed); _allBindingList.Add(vm); } } this.xhsProjectSimulationHydroCheckFailedViewModelBindingSource.DataSource = _allBindingList; this.xhsProjectSimulationHydroCheckFailedViewModelBindingSource.ResetBindings(false); } private void gridView1_RowClick(object sender, DevExpress.XtraGrid.Views.Grid.RowClickEventArgs e) { var row = this.gridView1.GetRow(e.RowHandle) as XhsProjectSimulationHydroCheckFailedViewModel; if (row == null) { return; } this.HydroClickEvent?.Invoke(row.ParterId); } } } WinFrmUI/HStation.WinFrmUI.Xhs.Core/04-simulation/06-simulation/02-check/XhsProjectSimulationHydroCheckFailedCtrl.resxcopy from WinFrmUI/HStation.WinFrmUI.Xhs.Core/04-simulation/06-simulation/XhsProjectSimulationHydroCheckFailedDlg.resx copy to WinFrmUI/HStation.WinFrmUI.Xhs.Core/04-simulation/06-simulation/02-check/XhsProjectSimulationHydroCheckFailedCtrl.resx
WinFrmUI/HStation.WinFrmUI.Xhs.Core/04-simulation/06-simulation/02-check/XhsProjectSimulationHydroCheckFailedDlg.Designer.cs
WinFrmUI/HStation.WinFrmUI.Xhs.Core/04-simulation/06-simulation/02-check/XhsProjectSimulationHydroCheckFailedDlg.cs
WinFrmUI/HStation.WinFrmUI.Xhs.Core/04-simulation/06-simulation/02-check/XhsProjectSimulationHydroCheckFailedDlg.resx
WinFrmUI/HStation.WinFrmUI.Xhs.Core/04-simulation/06-simulation/02-check/XhsProjectSimulationHydroCheckFailedViewModel.cs
WinFrmUI/HStation.WinFrmUI.Xhs.Core/04-simulation/06-simulation/XhsProjectSimulationCorePage.Designer.cs
@@ -58,6 +58,12 @@ docPnlProperty = new DevExpress.XtraBars.Docking.DockPanel(); dockPanel1_Container = new DevExpress.XtraBars.Docking.ControlContainer(); xhsProjectSimulationPropertyCtrl1 = new XhsProjectSimulationPropertyCtrl(); docPnlBottom = new DevExpress.XtraBars.Docking.DockPanel(); docPnlHydroCalcu = new DevExpress.XtraBars.Docking.DockPanel(); controlContainer2 = new DevExpress.XtraBars.Docking.ControlContainer(); docPnlHydroCheck = new DevExpress.XtraBars.Docking.DockPanel(); controlContainer1 = new DevExpress.XtraBars.Docking.ControlContainer(); xhsProjectSimulationHydroCheckFailedCtrl1 = new XhsProjectSimulationHydroCheckFailedCtrl(); svgImg32 = new DevExpress.Utils.SvgImageCollection(components); ((ISupportInitialize)ribbonControl1).BeginInit(); ((ISupportInitialize)tabPane1).BeginInit(); @@ -67,6 +73,10 @@ ((ISupportInitialize)dockManager1).BeginInit(); docPnlProperty.SuspendLayout(); dockPanel1_Container.SuspendLayout(); docPnlBottom.SuspendLayout(); docPnlHydroCalcu.SuspendLayout(); docPnlHydroCheck.SuspendLayout(); controlContainer1.SuspendLayout(); ((ISupportInitialize)svgImg32).BeginInit(); SuspendLayout(); // @@ -82,7 +92,7 @@ ribbonControl1.ShowApplicationButton = DevExpress.Utils.DefaultBoolean.False; ribbonControl1.ShowExpandCollapseButton = DevExpress.Utils.DefaultBoolean.False; ribbonControl1.ShowPageHeadersMode = DevExpress.XtraBars.Ribbon.ShowPageHeadersMode.ShowOnMultiplePages; ribbonControl1.Size = new Size(951, 101); ribbonControl1.Size = new Size(1051, 128); ribbonControl1.ToolbarLocation = DevExpress.XtraBars.Ribbon.RibbonQuickAccessToolbarLocation.Hidden; // // barBtnHydroCheck @@ -225,12 +235,12 @@ tabPane1.Controls.Add(pageBimface); tabPane1.Controls.Add(pageQ3d); tabPane1.Dock = DockStyle.Fill; tabPane1.Location = new Point(0, 101); tabPane1.Location = new Point(0, 128); tabPane1.Name = "tabPane1"; tabPane1.Pages.AddRange(new DevExpress.XtraBars.Navigation.NavigationPageBase[] { pageBimface, pageQ3d }); tabPane1.RegularSize = new Size(651, 486); tabPane1.RegularSize = new Size(776, 334); tabPane1.SelectedPage = pageBimface; tabPane1.Size = new Size(651, 486); tabPane1.Size = new Size(776, 334); tabPane1.TabIndex = 1; tabPane1.Text = "tabPane1"; // @@ -239,14 +249,14 @@ pageBimface.Caption = "ä¸ç»´æ¨¡å"; pageBimface.Controls.Add(xhsProjectSimulationBimfaceCtrl1); pageBimface.Name = "pageBimface"; pageBimface.Size = new Size(651, 453); pageBimface.Size = new Size(776, 301); // // xhsProjectSimulationBimfaceCtrl1 // xhsProjectSimulationBimfaceCtrl1.Dock = DockStyle.Fill; xhsProjectSimulationBimfaceCtrl1.Location = new Point(0, 0); xhsProjectSimulationBimfaceCtrl1.Name = "xhsProjectSimulationBimfaceCtrl1"; xhsProjectSimulationBimfaceCtrl1.Size = new Size(651, 453); xhsProjectSimulationBimfaceCtrl1.Size = new Size(776, 301); xhsProjectSimulationBimfaceCtrl1.TabIndex = 0; xhsProjectSimulationBimfaceCtrl1.ClickParterEvent += xhsProjectSimulationBimfaceCtrl1_ClickParterEvent; // @@ -268,7 +278,7 @@ // dockManager1 // dockManager1.Form = this; dockManager1.RootPanels.AddRange(new DevExpress.XtraBars.Docking.DockPanel[] { docPnlProperty }); dockManager1.RootPanels.AddRange(new DevExpress.XtraBars.Docking.DockPanel[] { docPnlProperty, docPnlBottom }); dockManager1.TopZIndexControls.AddRange(new string[] { "DevExpress.XtraBars.BarDockControl", "DevExpress.XtraBars.StandaloneBarDockControl", "System.Windows.Forms.MenuStrip", "System.Windows.Forms.StatusStrip", "System.Windows.Forms.StatusBar", "DevExpress.XtraBars.Ribbon.RibbonStatusBar", "DevExpress.XtraBars.Ribbon.RibbonControl", "DevExpress.XtraBars.Navigation.OfficeNavigationBar", "DevExpress.XtraBars.Navigation.TileNavPane", "DevExpress.XtraBars.TabFormControl", "DevExpress.XtraBars.FluentDesignSystem.FluentDesignFormControl", "DevExpress.XtraBars.ToolbarForm.ToolbarFormControl" }); // // docPnlProperty @@ -276,10 +286,10 @@ docPnlProperty.Controls.Add(dockPanel1_Container); docPnlProperty.Dock = DevExpress.XtraBars.Docking.DockingStyle.Right; docPnlProperty.ID = new Guid("cffe2560-3445-4488-83cf-b9e4b936ff18"); docPnlProperty.Location = new Point(651, 101); docPnlProperty.Location = new Point(776, 128); docPnlProperty.Name = "docPnlProperty"; docPnlProperty.OriginalSize = new Size(300, 200); docPnlProperty.Size = new Size(300, 486); docPnlProperty.OriginalSize = new Size(275, 200); docPnlProperty.Size = new Size(275, 622); docPnlProperty.Text = "屿§"; // // dockPanel1_Container @@ -287,7 +297,7 @@ dockPanel1_Container.Controls.Add(xhsProjectSimulationPropertyCtrl1); dockPanel1_Container.Location = new Point(4, 26); dockPanel1_Container.Name = "dockPanel1_Container"; dockPanel1_Container.Size = new Size(293, 457); dockPanel1_Container.Size = new Size(268, 593); dockPanel1_Container.TabIndex = 0; // // xhsProjectSimulationPropertyCtrl1 @@ -295,8 +305,69 @@ xhsProjectSimulationPropertyCtrl1.Dock = DockStyle.Fill; xhsProjectSimulationPropertyCtrl1.Location = new Point(0, 0); xhsProjectSimulationPropertyCtrl1.Name = "xhsProjectSimulationPropertyCtrl1"; xhsProjectSimulationPropertyCtrl1.Size = new Size(293, 457); xhsProjectSimulationPropertyCtrl1.Size = new Size(268, 593); xhsProjectSimulationPropertyCtrl1.TabIndex = 0; // // docPnlBottom // docPnlBottom.ActiveChild = docPnlHydroCheck; docPnlBottom.Controls.Add(docPnlHydroCheck); docPnlBottom.Controls.Add(docPnlHydroCalcu); docPnlBottom.Dock = DevExpress.XtraBars.Docking.DockingStyle.Bottom; docPnlBottom.ID = new Guid("b0042bf8-5e21-49c9-a503-0ba75eabffa4"); docPnlBottom.Location = new Point(0, 462); docPnlBottom.Name = "docPnlBottom"; docPnlBottom.OriginalSize = new Size(200, 288); docPnlBottom.Size = new Size(776, 288); docPnlBottom.Tabbed = true; docPnlBottom.Text = "panelContainer1"; // // docPnlHydroCalcu // docPnlHydroCalcu.Controls.Add(controlContainer2); docPnlHydroCalcu.Dock = DevExpress.XtraBars.Docking.DockingStyle.Fill; docPnlHydroCalcu.FloatVertical = true; docPnlHydroCalcu.ID = new Guid("ac7055c0-e9fe-40c2-bf51-83dde5710cd4"); docPnlHydroCalcu.Location = new Point(3, 27); docPnlHydroCalcu.Name = "docPnlHydroCalcu"; docPnlHydroCalcu.OriginalSize = new Size(200, 200); docPnlHydroCalcu.Size = new Size(770, 231); docPnlHydroCalcu.Text = "æ°´å计ç®"; // // controlContainer2 // controlContainer2.Location = new Point(0, 0); controlContainer2.Name = "controlContainer2"; controlContainer2.Size = new Size(770, 231); controlContainer2.TabIndex = 0; // // docPnlHydroCheck // docPnlHydroCheck.Controls.Add(controlContainer1); docPnlHydroCheck.Dock = DevExpress.XtraBars.Docking.DockingStyle.Fill; docPnlHydroCheck.ID = new Guid("dee18895-8b3d-44cd-9001-28bee516095d"); docPnlHydroCheck.Location = new Point(3, 27); docPnlHydroCheck.Name = "docPnlHydroCheck"; docPnlHydroCheck.OriginalSize = new Size(200, 200); docPnlHydroCheck.Size = new Size(770, 231); docPnlHydroCheck.Text = "æ°´åæ ¡éª"; // // controlContainer1 // controlContainer1.Controls.Add(xhsProjectSimulationHydroCheckFailedCtrl1); controlContainer1.Location = new Point(0, 0); controlContainer1.Name = "controlContainer1"; controlContainer1.Size = new Size(770, 231); controlContainer1.TabIndex = 0; // // xhsProjectSimulationHydroCheckFailedCtrl1 // xhsProjectSimulationHydroCheckFailedCtrl1.Dock = DockStyle.Fill; xhsProjectSimulationHydroCheckFailedCtrl1.Location = new Point(0, 0); xhsProjectSimulationHydroCheckFailedCtrl1.Name = "xhsProjectSimulationHydroCheckFailedCtrl1"; xhsProjectSimulationHydroCheckFailedCtrl1.Size = new Size(770, 231); xhsProjectSimulationHydroCheckFailedCtrl1.TabIndex = 0; xhsProjectSimulationHydroCheckFailedCtrl1.HydroClickEvent += xhsProjectSimulationHydroCheckFailedCtrl1_HydroClickEvent; // // svgImg32 // @@ -310,11 +381,12 @@ AutoScaleDimensions = new SizeF(7F, 14F); AutoScaleMode = AutoScaleMode.Font; Controls.Add(tabPane1); Controls.Add(docPnlBottom); Controls.Add(docPnlProperty); Controls.Add(ribbonControl1); Margin = new Padding(2); Name = "XhsProjectSimulationCorePage"; Size = new Size(951, 587); Size = new Size(1051, 750); ((ISupportInitialize)ribbonControl1).EndInit(); ((ISupportInitialize)tabPane1).EndInit(); tabPane1.ResumeLayout(false); @@ -323,6 +395,10 @@ ((ISupportInitialize)dockManager1).EndInit(); docPnlProperty.ResumeLayout(false); dockPanel1_Container.ResumeLayout(false); docPnlBottom.ResumeLayout(false); docPnlHydroCalcu.ResumeLayout(false); docPnlHydroCheck.ResumeLayout(false); controlContainer1.ResumeLayout(false); ((ISupportInitialize)svgImg32).EndInit(); ResumeLayout(false); PerformLayout(); @@ -359,5 +435,11 @@ private XhsProjectSimulationPropertyCtrl xhsProjectSimulationPropertyCtrl1; private DevExpress.Utils.SvgImageCollection svgImg32; private DevExpress.XtraBars.BarButtonItem BtnPerformChart; private DevExpress.XtraBars.Docking.DockPanel docPnlHydroCheck; private DevExpress.XtraBars.Docking.ControlContainer controlContainer1; private XhsProjectSimulationHydroCheckFailedCtrl xhsProjectSimulationHydroCheckFailedCtrl1; private DevExpress.XtraBars.Docking.DockPanel docPnlBottom; private DevExpress.XtraBars.Docking.DockPanel docPnlHydroCalcu; private DevExpress.XtraBars.Docking.ControlContainer controlContainer2; } } WinFrmUI/HStation.WinFrmUI.Xhs.Core/04-simulation/06-simulation/XhsProjectSimulationCorePage.cs
@@ -1,6 +1,7 @@ global using Yw.EPAnet; using HStation.WinFrmUI.Xhs; using HStation.WinFrmUI.Xhs.Core; using NPOI.SS.Formula.Functions; namespace HStation.WinFrmUI { @@ -11,6 +12,9 @@ InitializeComponent(); this.PageTitle.Caption = "æ°´åæ¨¡æ"; this.PageTitle.HeaderSvgImage = this.svgImg32[0]; this.docPnlBottom.Visibility = DevExpress.XtraBars.Docking.DockVisibility.Hidden; this.docPnlHydroCheck.Visibility = DevExpress.XtraBars.Docking.DockVisibility.Hidden; this.docPnlHydroCalcu.Visibility = DevExpress.XtraBars.Docking.DockVisibility.Hidden; } private HStation.Vmo.XhsProjectVmo _project = null;//é¡¹ç® @@ -98,21 +102,8 @@ TipFormHelper.ShowSucceed("æ ¡éªéè¿ï¼"); return; } var dlg = new XhsProjectSimulationHydroCheckFailedDlg(); dlg.TopMost = true; dlg.HydroClickEvent += async (code) => { if (_hydroInfo == null) { return; } await this.xhsProjectSimulationBimfaceCtrl1.SetSelectedComponents(new List<string>() { code }); var allParterList = _hydroInfo.GetAllParters(); _parter = allParterList.Find(x => x.Code == code); ShowProperty(); }; dlg.SetBindingData(_checkResult.FailedList); dlg.Show(); this.xhsProjectSimulationHydroCheckFailedCtrl1.SetBindingData(_checkResult.FailedList); this.docPnlHydroCheck.Visibility = DevExpress.XtraBars.Docking.DockVisibility.Visible; } //æ°´åè®¡ç® @@ -269,5 +260,19 @@ var dlg = new PerformChart(); dlg.ShowDialog(); } //æ°´åæ ¡éªç¹å» private async void xhsProjectSimulationHydroCheckFailedCtrl1_HydroClickEvent(string obj) { if (_hydroInfo == null) { return; } await this.xhsProjectSimulationBimfaceCtrl1.SetSelectedComponents(new List<string>() { obj }); var allParterList = _hydroInfo.GetAllParters(); _parter = allParterList.Find(x => x.Code == obj); ShowProperty(); } } } WinFrmUI/HStation.WinFrmUI.Xhs.Core/HStation.WinFrmUI.Xhs.Core.csproj.user
@@ -103,10 +103,13 @@ <Compile Update="04-simulation\05-function\XhsProjectSimulationFunctionMgrCtrl.cs"> <SubType>UserControl</SubType> </Compile> <Compile Update="04-simulation\06-simulation\02-check\XhsProjectSimulationHydroCheckFailedCtrl.cs"> <SubType>UserControl</SubType> </Compile> <Compile Update="04-simulation\06-simulation\PerformChart.cs"> <SubType>Form</SubType> </Compile> <Compile Update="04-simulation\06-simulation\XhsProjectSimulationHydroCheckFailedDlg.cs"> <Compile Update="04-simulation\06-simulation\02-check\XhsProjectSimulationHydroCheckFailedDlg.cs"> <SubType>Form</SubType> </Compile> <Compile Update="04-simulation\XhsProjectSimulationMgrPage.cs"> WinFrmUI/Yw.WinFrmUI.Hydro.Core/Yw.WinFrmUI.Hydro.Core.csproj
@@ -9,8 +9,8 @@ <ItemGroup> <PackageReference Include="DevExpress.Win.Design" Version="23.2.4" /> <PackageReference Include="Yw.BLL.Basic.Core" Version="3.2.7" /> <PackageReference Include="Yw.BLL.Hydro.Core" Version="3.2.1" /> <PackageReference Include="Yw.BLL.Basic.Core" Version="3.2.8" /> <PackageReference Include="Yw.BLL.Hydro.Core" Version="3.2.2" /> </ItemGroup> <ItemGroup>