From 7079cbb505471a8d3251cac4e27c7a3841f8e656 Mon Sep 17 00:00:00 2001 From: duheng <2784771470@qq.com> Date: 星期三, 04 十二月 2024 22:51:37 +0800 Subject: [PATCH] 修改单独匹配界面 --- WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/06-simulation/01-matching/09-Tank/TankChartShowDlg.cs | 106 ++++++++++++++++++++++++++++------------------------ 1 files changed, 57 insertions(+), 49 deletions(-) diff --git a/WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/06-simulation/01-matching/09-Tank/TankChartShowDlg.cs b/WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/06-simulation/01-matching/09-Tank/TankChartShowDlg.cs index 1c4638e..68257c5 100644 --- a/WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/06-simulation/01-matching/09-Tank/TankChartShowDlg.cs +++ b/WinFrmUI/HStation.WinFrmUI.Xhs.Core/03-simulation/06-simulation/01-matching/09-Tank/TankChartShowDlg.cs @@ -10,58 +10,66 @@ this.IconOptions.Icon = Yw.WinFrmUI.GlobalParas.AppIcon; } + /* //鍒濆鍖栧浘琛ㄦ暟鎹� + public void InitChart(Vmo.XhsTankMainPhartMappingExtensions dto) + { + if (dto == null) + { + return; + } + var diagram = dto.Diagram; + if (diagram == null) + { + return; + } + var graph_list = diagram.GraphList; + if (graph_list == null || !graph_list.Any()) + { + return; + } + + var graph_ql = graph_list.Find(x => x.GraphType == HStation.PhartRelation.eGraphType.TankQL); + var graph_ol = graph_list.Find(x => x.GraphType == HStation.PhartRelation.eGraphType.TankOL); + if (graph_ql == null && graph_ol == null) + { + return; + } + + List<Yw.Geometry.Point2d> points_ql = null; + if (graph_ql != null) + points_ql = PhartPerformCurveHelper.GetFeatPointList(graph_ql.GraphType, graph_ql.GeometryInfo, 12, null); + + List<Yw.Geometry.Point2d> points_ol = null; + if (graph_ol != null) + points_ol = PhartPerformCurveHelper.GetFeatPointList(graph_ol.GraphType, graph_ol.GeometryInfo, 12, null); + Yw.Geometry.CubicSpline2d cubic_spline = null; + if (points_ql != null) + { + cubic_spline = new Yw.Geometry.CubicSpline2d(points_ql); + } + if (points_ol != null) + { + cubic_spline = new Yw.Geometry.CubicSpline2d(points_ol); + } + var disp_paras = diagram.DispParas; + var is_calc_disp_paras = string.IsNullOrWhiteSpace(disp_paras); + this.xtrPerform2dchart1.SetBindingData(cubic_spline.ToDbString(), disp_paras, is_calc_disp_paras); + if (graph_ol != null) + { + this.xtrPerform2dchart1.SetAxisTitle("闃�闂ㄥ紑搴�", "鎹熷け绯绘暟"); + } + else + { + this.xtrPerform2dchart1.SetAxisTitle("娴侀噺(m鲁/h)", "姘存崯/m"); + } + }*/ + //鍒濆鍖栧浘琛ㄦ暟鎹� - public void InitChart(/*Vmo.XhsTankMainPhartMappingExtensions dto*/) + public void InitChart(string curveStr) { - /* if (dto == null) - { - return; - } - var diagram = dto.Diagram; - if (diagram == null) - { - return; - } - var graph_list = diagram.GraphList; - if (graph_list == null || !graph_list.Any()) - { - return; - } + this.xtrPerform2dchart1.SetBindingData(curveStr, null); - var graph_ql = graph_list.Find(x => x.GraphType == HStation.PhartRelation.eGraphType.TankQL); - var graph_ol = graph_list.Find(x => x.GraphType == HStation.PhartRelation.eGraphType.TankOL); - if (graph_ql == null && graph_ol == null) - { - return; - } - - List<Yw.Geometry.Point2d> points_ql = null; - if (graph_ql != null) - points_ql = PhartPerformCurveHelper.GetFeatPointList(graph_ql.GraphType, graph_ql.GeometryInfo, 12, null); - - List<Yw.Geometry.Point2d> points_ol = null; - if (graph_ol != null) - points_ol = PhartPerformCurveHelper.GetFeatPointList(graph_ol.GraphType, graph_ol.GeometryInfo, 12, null); - Yw.Geometry.CubicSpline2d cubic_spline = null; - if (points_ql != null) - { - cubic_spline = new Yw.Geometry.CubicSpline2d(points_ql); - } - if (points_ol != null) - { - cubic_spline = new Yw.Geometry.CubicSpline2d(points_ol); - } - var disp_paras = diagram.DispParas; - var is_calc_disp_paras = string.IsNullOrWhiteSpace(disp_paras); - this.xtrPerform2dchart1.SetBindingData(cubic_spline, disp_paras, is_calc_disp_paras); - if (graph_ol != null) - { - this.xtrPerform2dchart1.SetAxisTitle("闃�闂ㄥ紑搴�", "鎹熷け绯绘暟"); - } - else - { - this.xtrPerform2dchart1.SetAxisTitle("娴侀噺(m鲁/h)", "姘存崯/m"); - }*/ + this.xtrPerform2dchart1.SetAxisTitle("闃�闂ㄥ紑搴�", "鎹熷け绯绘暟"); } } } \ No newline at end of file -- Gitblit v1.9.3