From 4a06cb018cb916d4028700b73eeca267fd52a62f Mon Sep 17 00:00:00 2001 From: lihanbo Date: Fri, 8 Nov 2024 15:27:46 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=AF=BC=E5=87=BA=E5=AE=8C?= =?UTF-8?q?=E6=88=90=E6=8F=90=E7=A4=BA=E6=A1=86=E5=92=8C=E5=BF=BD=E7=95=A5?= =?UTF-8?q?=E5=BC=82=E5=B8=B8=E7=A1=AE=E8=AE=A4=E5=AF=B9=E8=AF=9D=E6=A1=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 在 `MainWindow.xaml.cs` 文件中,`saveFileDialog.ShowDialog()` 方法调用后,添加了一行代码 `FlexMessageBox.Info($"导出完成!");`,用于在导出完成后显示信息提示框。 在 `IgnoreSelectedError_Click` 方法中添加了一段代码,用于在用户点击忽略异常按钮后,弹出一个警告对话框,询问用户是否继续操作。如果用户选择继续,则设置 `isContinue` 为 `true`,并继续执行后续代码。 --- Sinvo.EplanHpD.Plugin.WPFUI/MainWindow.xaml.cs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Sinvo.EplanHpD.Plugin.WPFUI/MainWindow.xaml.cs b/Sinvo.EplanHpD.Plugin.WPFUI/MainWindow.xaml.cs index 066e751..b4f269d 100644 --- a/Sinvo.EplanHpD.Plugin.WPFUI/MainWindow.xaml.cs +++ b/Sinvo.EplanHpD.Plugin.WPFUI/MainWindow.xaml.cs @@ -216,6 +216,7 @@ public partial class MainWindow : Window if (saveFileDialog.ShowDialog() == true) { ExcelHelper.SaveByTemplate(ViewModel.ExportData, Path.Combine(FlexIOBase.GetParentPath(saveFileDialog.FileName), saveFileDialog.FileName)); + FlexMessageBox.Info($"导出完成!"); } } @@ -232,6 +233,14 @@ public partial class MainWindow : Window /// private void IgnoreSelectedError_Click(object sender, RoutedEventArgs e) { + bool isContinue = false; + if (FlexMessageBox.Warning(FlexMessageBox.Buttons.OK_CANCEL, + "Report", + "忽略异常后在导出下单报表时,将不会再进行管控,是否继续?", false) == System.Windows.Forms.DialogResult.OK) + { + isContinue = true; + } + if (isContinue) if (ModelGenDataGrid.SelectedItems != null) { var selectedRows = ModelGenDataGrid.SelectedItems;