From a89f2c46d1f53a4d9e23dc76b949b40d2b2b18a6 Mon Sep 17 00:00:00 2001
From: lu <99954486@qq.com>
Date: 星期六, 08 二月 2025 08:22:22 +0800
Subject: [PATCH] 采购退货

---
 DevApp/Gs.DevApp/DevFrm/WW/Frm_WwGd.cs |   85 +++++++-----------------------------------
 1 files changed, 14 insertions(+), 71 deletions(-)

diff --git a/DevApp/Gs.DevApp/DevFrm/WW/Frm_WwGd.cs b/DevApp/Gs.DevApp/DevFrm/WW/Frm_WwGd.cs
index 66fd692..823787f 100644
--- a/DevApp/Gs.DevApp/DevFrm/WW/Frm_WwGd.cs
+++ b/DevApp/Gs.DevApp/DevFrm/WW/Frm_WwGd.cs
@@ -1,4 +1,3 @@
-using DevExpress.RichEdit.Export;
 using Gs.DevApp.Entity;
 using Gs.DevApp.ToolBox;
 using Gs.DevApp.UserControl;
@@ -7,7 +6,6 @@
 using System;
 using System.Collections.Generic;
 using System.Data;
-using System.Drawing;
 using System.Threading.Tasks;
 using System.Windows.Forms;
 
@@ -15,7 +13,7 @@
 {
     public partial class Frm_WwGd : DevExpress.XtraEditors.XtraForm
     {
-        string _webServiceName = "WomdaaManager/";
+        string _webServiceName = "WWGDManager/";
         List<FilterEntity> _filterList = new List<FilterEntity>();
         public Frm_WwGd()
         {
@@ -30,8 +28,7 @@
             this.toolBarMenu1.btnKgClick += ToolBarMenu1_btnKgClick;
             this.toolBarMenu1.btnWgClick += ToolBarMenu1_btnWgClick;
             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.SetGridViewParameter(gridView1, picCheckBox, this, "pcShChk", "", (value) =>
             {
                 Gs.DevApp.ToolBox.UtilityHelper.JumpTab(xtraTabControl1, 0);
             });
@@ -44,18 +41,10 @@
             });
             getPageList(1);
             pageBar1.PagerEvent += PageBar1_PagerEvent;
-            this.ucBtnPrint1.btnDesignClick += (s, e) =>
-            {
-                ucBtnPrint1.rptParameter = "rpt_daa{}";
-            };
-            this.ucBtnPrint1.btnReportClick += (s, e) =>
-            {
-                _print();
-            };
         }
         private void GridView1_ColumnFilterChanged(object sender, EventArgs e)
         {
-            _filterList = Gs.DevApp.ToolBox.UtilityHelper.GetDilter(gridView1.Columns);
+            Gs.DevApp.ToolBox.UtilityHelper.GetDilter(gridView1.Columns, gridView1);
             Task.Delay(100);
             getPageList(1);
         }
@@ -145,14 +134,15 @@
                 getModel(lbGuid.Text.Trim());
             else
             {
-                _filterList.Clear();
-                if (gridView1.ActiveFilter.Count > 0)
-                {
-                    gridView1.ColumnFilterChanged -= GridView1_ColumnFilterChanged;
-                    gridView1.ActiveFilter.Clear();
-                    gridView1.ColumnFilterChanged += GridView1_ColumnFilterChanged;
-                }
-                getPageList(1);
+                //_filterList.Clear();
+                //if (gridView1.ActiveFilter.Count > 0)
+                //{
+                //    gridView1.ColumnFilterChanged -= GridView1_ColumnFilterChanged;
+                //    gridView1.ActiveFilter.Clear();
+                //    gridView1.ColumnFilterChanged += GridView1_ColumnFilterChanged;
+                //}
+                //getPageList(1);
+                getPageList(this.pageBar1.CurrentPage);
             }
         }
         /// <summary>
@@ -230,6 +220,7 @@
                     {
                         gcMain.DataSource = dt;
                         gcMain.ForceInitialize();
+                        gridView1.BestFitColumns();
                     }
                     else
                         UtilityHelper.SetDefaultTable(gcMain, gridView1);
@@ -289,26 +280,11 @@
                         gcMx1.BindingContext = new BindingContext();
                         gcMx1.DataSource = dt;
                         gcMx1.ForceInitialize();
+                        gvMx1.BestFitColumns();
                     }
                     else
                     {
                         Gs.DevApp.ToolBox.UtilityHelper.SetDefaultTable(gcMx1, gvMx1);
-                    }
-                    JArray array2 = new JArray();
-                    foreach (var a in _job["rtnData"]["list2"])
-                    {
-                        array2.Add(a);
-                    }
-                    DataTable dt2 = JsonConvert.DeserializeObject<DataTable>(array2.ToString());
-                    if (dt.Rows.Count > 0)
-                    {
-                        gcMx2.BindingContext = new BindingContext();
-                        gcMx2.DataSource = dt2;
-                        gcMx2.ForceInitialize();
-                    }
-                    else
-                    {
-                        Gs.DevApp.ToolBox.UtilityHelper.SetDefaultTable(gcMx2, gvMx2);
                     }
                 }
                 else
@@ -394,38 +370,5 @@
             }
         }
 
-        private void _print()
-        {
-            string rowGuid, rowName;
-            (rowGuid, rowName) = UtilityHelper.GetCurrentRow(xtraTabControl1,
-                lbGuid, txt_daa001, gridView1);
-            ucBtnPrint1.guidKey = rowGuid;
-            if (rowGuid.Length < 36)
-            {
-                Gs.DevApp.ToolBox.MsgHelper.ShowError("璇烽�夋嫨浣犺鎵撳嵃鐨勮锛�");
-                this.ucBtnPrint1.rptParameter = "return false";
-                return;
-            }
-            if (string.IsNullOrEmpty(txt_iCount_1.Text.Trim()))
-            {
-                Gs.DevApp.ToolBox.MsgHelper.ShowError("璇烽�夋嫨鎵撳嵃鏉$爜寮犳暟锛�");
-                txt_iCount_1.Focus();
-                this.ucBtnPrint1.rptParameter = "return false";
-                return;
-            }
-            if (string.IsNullOrEmpty(txt_psnQty_1.Text.Trim()))
-            {
-                Gs.DevApp.ToolBox.MsgHelper.ShowError("璇烽�夋嫨鎵撳嵃鏉$爜鏁伴噺锛�");
-                txt_psnQty_1.Focus();
-                this.ucBtnPrint1.rptParameter = "return false";
-                return;
-            }
-            this.ucBtnPrint1.rptParameter = "rpt_daa{" + ""
-                   + "," + txt_printRemark.Text.Trim()
-                   + "," + ""
-                   + "," + txt_iCount_1.Text.Trim()
-                   + "," + txt_psnQty_1.Text.Trim()
-                   + "}";
-        }
     }
 }
\ No newline at end of file

--
Gitblit v1.9.3