From 1bf6b7a300e21e9b8996f9ebeeb55a1eccda7a02 Mon Sep 17 00:00:00 2001 From: Shuxia Ning <NingShuxia0927@outlook.com> Date: 星期五, 20 十二月 2024 10:50:36 +0800 Subject: [PATCH] 排除bug --- WinFrmUI/HStation.WinFrmUI.Assets.Core/20-exchanger/04-curveql/AssetsExchangerCurveQLMgrPage.cs | 14 ++++++++++---- 1 files changed, 10 insertions(+), 4 deletions(-) diff --git a/WinFrmUI/HStation.WinFrmUI.Assets.Core/20-exchanger/04-curveql/AssetsExchangerCurveQLMgrPage.cs b/WinFrmUI/HStation.WinFrmUI.Assets.Core/20-exchanger/04-curveql/AssetsExchangerCurveQLMgrPage.cs index d5ef738..a5b51ef 100644 --- a/WinFrmUI/HStation.WinFrmUI.Assets.Core/20-exchanger/04-curveql/AssetsExchangerCurveQLMgrPage.cs +++ b/WinFrmUI/HStation.WinFrmUI.Assets.Core/20-exchanger/04-curveql/AssetsExchangerCurveQLMgrPage.cs @@ -24,8 +24,6 @@ this.phartDiagramRelationListCtrl1.SelectedChangedEvent += PhartDiagramRelationListCtrl1_SelectedChangedEvent; } - - private AssetsExchangerMainVmo _vmo = null; private List<PhartDiagramRelationVmo> _allBindingList = null; private PhartDiagramRelationVmo _relation = null; @@ -51,19 +49,27 @@ //excel private void Excel() { + if (_vmo == null) + { + return; + } var dlg = new ImportAssetsExchangerCurveQLByExcelDlg(); dlg.ReloadDataEvent += (rhs) => { _allBindingList.Add(rhs); this.phartDiagramRelationListCtrl1.SetBindingData(_allBindingList); }; - dlg.SetBindingData(); + dlg.SetBindingData(_vmo); dlg.ShowDialog(); } //鍥剧墖 private void Picture() { + if (_vmo == null) + { + return; + } var vm = GetCurrentViewModel(); if (vm == null) { @@ -75,7 +81,7 @@ _allBindingList.Add(rhs); this.phartDiagramRelationListCtrl1.SetBindingData(_allBindingList); }; - dlg.SetBindingData(); + dlg.SetBindingData(_vmo); dlg.ShowDialog(); } -- Gitblit v1.9.3