From a985c4d4b80fbf3eb4abbe385adcd0536fd29eda Mon Sep 17 00:00:00 2001
From: 啊鑫 <t2856754968@163.com>
Date: 星期五, 22 十一月 2024 15:04:23 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 DevApp/Gs.DevApp/DevFrm/Warehouse/Frm_InitialBarcode.cs |   65 ++++++++++++++++++++++++++++----
 1 files changed, 56 insertions(+), 9 deletions(-)

diff --git a/DevApp/Gs.DevApp/DevFrm/Warehouse/Frm_InitialBarcode.cs b/DevApp/Gs.DevApp/DevFrm/Warehouse/Frm_InitialBarcode.cs
index 1e6fb42..8c6ef5a 100644
--- a/DevApp/Gs.DevApp/DevFrm/Warehouse/Frm_InitialBarcode.cs
+++ b/DevApp/Gs.DevApp/DevFrm/Warehouse/Frm_InitialBarcode.cs
@@ -1,3 +1,4 @@
+using DevExpress.XtraGrid.Views.Grid;
 using Gs.DevApp.Entity;
 using Gs.DevApp.ToolBox;
 using Newtonsoft.Json;
@@ -19,7 +20,8 @@
             InitializeComponent();
             this.toolBarMenu1.btnLoadClick += ToolBarMenu1_btnLoadClick;
             this.toolBarMenu1.btnQueryClick += ToolBarMenu1_btnQueryClick;
-            this.toolBarMenu1.btnPrintClick += ToolBarMenu1_btnPrintClick;
+            toolBarMenu1.btnReportClick += ToolBarMenu1_btnReportClick;
+            toolBarMenu1.btnDesignClick += ToolBarMenu1_btnDesignClick;
             gcMain.MouseDoubleClick += GcMain_MouseDoubleClick;
             getPageList(1, UtilityHelper.GetPageSize());
             pageBar1.PagerEvent += PageBar1_PagerEvent;
@@ -43,8 +45,10 @@
             {
                 txt_suppId.Text = this.txt_suppNo_1.GetId();
             };
+          
         }
 
+      
         /// <summary>
         /// 鍙屽嚮浜嬩欢
         /// </summary>
@@ -99,15 +103,55 @@
             else
                 getPageList(1, UtilityHelper.GetPageSize());
         }
-
-        /// <summary>
-        /// 鎵撳嵃
-        /// </summary>
-        /// <param name="sender"></param>
-        /// <param name="e"></param>
-        private void ToolBarMenu1_btnPrintClick(object sender, EventArgs e)
+        private void ToolBarMenu1_btnDesignClick(object sender, EventArgs e)
         {
-
+            toolBarMenu1.guidKey = "";
+            string rowGuid, rowName;
+            (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
+                lbGuid, txt_itemName, gridView1);
+            toolBarMenu1.guidKey = rowGuid;
+            toolBarMenu1.rptParameter = "rpt_ItemInv{}";
+        }
+        private void ToolBarMenu1_btnReportClick(object sender, EventArgs e)
+        {
+            toolBarMenu1.guidKey = "";
+            string rowGuid, rowName;
+            (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
+                lbGuid, txt_itemName, gridView1);
+            toolBarMenu1.guidKey = rowGuid;
+            if (xtraTabControl1.SelectedTabPageIndex == 0)
+            {
+                getModel(rowGuid, false, 999);
+                this.toolBarMenu1.rptParameter = "return false";
+                return;
+            }
+            if (string.IsNullOrEmpty(txt_suppNo_1.GetCode()))
+            {
+                Gs.DevApp.ToolBox.MsgHelper.ShowError("璇烽�夋嫨渚涘簲鍟嗭紒");
+                txt_suppNo_1.Focus();
+                this.toolBarMenu1.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";
+                return;
+            }
+            if (string.IsNullOrEmpty(txt_psnQty_1.Text.Trim()))
+            {
+                Gs.DevApp.ToolBox.MsgHelper.ShowError("璇烽�夋嫨鎵撳嵃鏉$爜鏁伴噺锛�");
+                txt_psnQty_1.Focus();
+                this.toolBarMenu1.rptParameter = "return false";
+                return;
+            }
+            this.toolBarMenu1.rptParameter = "rpt_ItemInv{" + txt_createDate1.Text.Trim()
+                   + "," + txt_tc_1.Checked.ToString().ToUpper()
+                   + "," + txt_suppNo_1.GetId()
+                   + "," + txt_iCount_1.Text.Trim()
+                   + "," + txt_psnQty_1.Text.Trim()
+                   + "}";
         }
 
         /// <summary>
@@ -159,6 +203,9 @@
                 return;
             }
             UtilityHelper.JumpToTab(xtraTabControl1, tabIdx);
+            txt_iCount_1.Text = "";
+            txt_psnQty_1.Text = "";
+            txt_suppNo_1.SetIdOrCode("-1");
             var _obj = new
             {
                 guid = strGuid,//涓诲缓

--
Gitblit v1.9.3