PopupSubmit.cs 969 B

123456789101112131415161718192021222324252627282930313233343536
  1. using Core.Mes.Client.Comm.Tool;
  2. using CoreFS.CA06;
  3. using System;
  4. using System.Windows.Forms;
  5. namespace Core.StlMes.Client.Judge.Forms
  6. {
  7. public partial class PopupSubmit : FrmBase
  8. {
  9. private bool _mustInputMemo = false;
  10. private string _tips = "";
  11. public PopupSubmit(string caption, bool mustInputMemo, string tips)
  12. {
  13. InitializeComponent();
  14. this.Text = caption;
  15. _mustInputMemo = mustInputMemo;
  16. _tips = tips;
  17. }
  18. private void btnSubmit_Click(object sender, EventArgs e)
  19. {
  20. if (_mustInputMemo && txtAudit.Text.Trim() == "")
  21. {
  22. MessageUtil.ShowWarning(_tips);
  23. return;
  24. }
  25. this.DialogResult = DialogResult.Yes;
  26. }
  27. private void button1_Click(object sender, EventArgs e)
  28. {
  29. this.DialogResult = System.Windows.Forms.DialogResult.No;
  30. }
  31. }
  32. }