From 19ffce9c62c4c65de166a1aa5e491ecad6e7ffb9 Mon Sep 17 00:00:00 2001
From: lu <99954486@qq.com>
Date: 星期一, 17 二月 2025 14:42:29 +0800
Subject: [PATCH] 生产退料入库

---
 DevApp/Gs.DevApp/UserControl/UcLookDaa.cs |   27 ++++++++++++++++++++++++---
 1 files changed, 24 insertions(+), 3 deletions(-)

diff --git a/DevApp/Gs.DevApp/UserControl/UcLookDaa.cs b/DevApp/Gs.DevApp/UserControl/UcLookDaa.cs
index 94e319d..1e9886c 100644
--- a/DevApp/Gs.DevApp/UserControl/UcLookDaa.cs
+++ b/DevApp/Gs.DevApp/UserControl/UcLookDaa.cs
@@ -22,7 +22,7 @@
             lookSearchSupplier.Properties.NullText = "璇烽�夋嫨";
             lookSearchSupplier.EditValueChanged +=
                 LookSearchSupplier_EditValueChanged;
-            getSuppler();
+           // getSuppler();
         }
 
         public bool IsReadly { get; set; }
@@ -38,9 +38,13 @@
             if (EditChanged != null) EditChanged(this, e);
         }
 
-        private void getSuppler()
+        public void getSuppler(string orgId)
         {
-            var pgq = new PageQueryModel(1, 999999, "a.daa001", "asc", "", " and 1=1");
+            string _keyWhere = "";
+            if (!string.IsNullOrEmpty(orgId))
+                _keyWhere = " and a.erp_sczz ='" + orgId + "'";
+            var pgq = new PageQueryModel(1, 999999, "a.daa001", "asc", "",
+                " and 1=1" + _keyWhere);
             var json = JsonConvert.SerializeObject(pgq);
             try
             {
@@ -50,6 +54,8 @@
                 lookSearchSupplier.Properties.DataSource = dt;
                 lookSearchSupplier.Properties.DisplayMember = "daa001";
                 lookSearchSupplier.Properties.ValueMember = "guid";
+                lookSearchSupplier.ForceInitialize();
+                lookSearchSupplier.Properties.BestFitMode = DevExpress.XtraEditors.Controls.BestFitMode.BestFitResizePopup;
             }
             catch (Exception ex)
             {
@@ -194,5 +200,20 @@
             }
             return "";
         }
+
+        /// <summary>
+        /// 绾垮埆
+        /// </summary>
+        /// <returns></returns>
+        public string GetRwd()
+        {
+            var row = lookSearchSupplier.GetSelectedDataRow() as DataRowView;
+            if (row != null)
+            {
+                string id = row["daa021"].ToString();
+                return id;
+            }
+            return "";
+        }
     }
 }

--
Gitblit v1.9.3