From 1f45918504bfdafae93b6fc7a5823a48d73e4d3c Mon Sep 17 00:00:00 2001
From: lu <99954486@qq.com>
Date: 星期二, 31 十二月 2024 14:51:58 +0800
Subject: [PATCH] 工单细节

---
 DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.cs |   60 ++++++++++++++++++++++++++++++------------------------------
 1 files changed, 30 insertions(+), 30 deletions(-)

diff --git a/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.cs b/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.cs
index 9a1e814..e77afd7 100644
--- a/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.cs
+++ b/DevApp/Gs.DevApp/DevFrm/WOM/Frm_Womdaa.cs
@@ -27,9 +27,9 @@
             this.toolBarMenu1.btnTzblClick += ToolBarMenu1_btnTzblClick;
             this.toolBarMenu1.btnKgClick += ToolBarMenu1_btnKgClick;
             this.toolBarMenu1.btnWgClick += ToolBarMenu1_btnWgClick;
-            toolBarMenu1.btnReportClick += ToolBarMenu1_btnReportClick;
-            toolBarMenu1.btnDesignClick += ToolBarMenu1_btnDesignClick;
+            toolBarMenu1.btnLogClick += ToolBarMenu1_btnLogClick;
             Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(gvMx1);
+            Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameterMx(gvMx2);
             Gs.DevApp.ToolBox.UtilityHelper.SetGridViewParameter(gridView1, null, null, null, "", (value) =>
             {
                 Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 0);
@@ -44,6 +44,14 @@
             getPageList(1);
             pageBar1.PagerEvent += PageBar1_PagerEvent;
             txt_sjXt.getSuppler("");
+            this.ucBtnPrint1.btnDesignClick += (s, e) =>
+            {
+                ucBtnPrint1.rptParameter = "rpt_daa{}";
+            };
+            this.ucBtnPrint1.btnReportClick += (s, e) =>
+            {
+                _print();
+            };
         }
         private void GridView1_ColumnFilterChanged(object sender, EventArgs e)
         {
@@ -115,7 +123,19 @@
         {
             _toolCk(8);
         }
-
+        /// <summary>
+        /// 鏃ュ織
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void ToolBarMenu1_btnLogClick(object sender, EventArgs e)
+        {
+            toolBarMenu1.guidKey = "";
+            string rowGuid, rowName;
+            (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
+                lbGuid, txt_daa001, gridView1);
+            toolBarMenu1.guidKey = rowGuid;
+        }
         /// <summary>
         /// 鍙栨秷浜嬩欢
         /// </summary>
@@ -268,6 +288,7 @@
                     lbGuid.Text = strGuid;
                     List<DevExpress.XtraGrid.Views.Grid.GridView> gvList = new List<DevExpress.XtraGrid.Views.Grid.GridView>();
                     gvList.Add(gvMx1);
+                    gvList.Add(gvMx2);
                     UtilityHelper.SetValueByObj(this.panel1.Controls, dy, isEdit, gvList);
                     JObject _job = JObject.Parse(strJson);
                     JArray array = new JArray();
@@ -292,7 +313,7 @@
                         array2.Add(a);
                     }
                     DataTable dt2 = JsonConvert.DeserializeObject<DataTable>(array2.ToString());
-                    if (dt.Rows.Count > 0)
+                    if (dt2.Rows.Count > 0)
                     {
                         gcMx2.BindingContext = new BindingContext();
                         gcMx2.DataSource = dt2;
@@ -310,20 +331,6 @@
             {
                 ToolBox.MsgHelper.Warning("鎻愮ず锛�" + ex.Message);
             }
-        }
-
-        private void ToolBarMenu1_btnDesignClick(object sender, EventArgs e)
-        {
-            toolBarMenu1.guidKey = "";
-            string rowGuid, rowName;
-            (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
-                lbGuid, txt_daa001, gridView1);
-            toolBarMenu1.guidKey = rowGuid;
-            toolBarMenu1.rptParameter = "rpt_daa{}";
-        }
-        private void ToolBarMenu1_btnReportClick(object sender, EventArgs e)
-        {
-            _print();
         }
 
         /// <summary>
@@ -402,38 +409,31 @@
 
         private void _print()
         {
-            toolBarMenu1.guidKey = "";
             string rowGuid, rowName;
             (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
                 lbGuid, txt_daa001, gridView1);
-            toolBarMenu1.guidKey = rowGuid;
-            if (xtraTabControl1.SelectedTabPageIndex == 0)
-            {
-                Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 5);
-                this.toolBarMenu1.rptParameter = "return false";
-                return;
-            }
+            ucBtnPrint1.guidKey = rowGuid;
             if (rowGuid.Length < 36)
             {
                 Gs.DevApp.ToolBox.MsgHelper.ShowError("璇烽�夋嫨浣犺鎵撳嵃鐨勮锛�");
-                this.toolBarMenu1.rptParameter = "return false";
+                this.ucBtnPrint1.rptParameter = "return false";
                 return;
             }
             if (string.IsNullOrEmpty(txt_iCount_1.Text.Trim()))
             {
                 Gs.DevApp.ToolBox.MsgHelper.ShowError("璇烽�夋嫨鎵撳嵃鏉$爜寮犳暟锛�");
                 txt_iCount_1.Focus();
-                this.toolBarMenu1.rptParameter = "return false";
+                this.ucBtnPrint1.rptParameter = "return false";
                 return;
             }
             if (string.IsNullOrEmpty(txt_psnQty_1.Text.Trim()))
             {
                 Gs.DevApp.ToolBox.MsgHelper.ShowError("璇烽�夋嫨鎵撳嵃鏉$爜鏁伴噺锛�");
                 txt_psnQty_1.Focus();
-                this.toolBarMenu1.rptParameter = "return false";
+                this.ucBtnPrint1.rptParameter = "return false";
                 return;
             }
-            this.toolBarMenu1.rptParameter = "rpt_daa{" + ""
+            this.ucBtnPrint1.rptParameter = "rpt_daa{" + ""
                    + "," + txt_printRemark.Text.Trim()
                    + "," + ""
                    + "," + txt_iCount_1.Text.Trim()

--
Gitblit v1.9.3