Browse Source

优化数据读取BUG

callm 5 days ago
parent
commit
ed98aac55e
1 changed files with 3 additions and 3 deletions
  1. 3 3
      UAS_MES_JH/FunctionCode/Make/Make_TestCollectionqrcode.cs

+ 3 - 3
UAS_MES_JH/FunctionCode/Make/Make_TestCollectionqrcode.cs

@@ -319,7 +319,7 @@ namespace UAS_MES_NEW.Make
                         }
 
                         listmac = dh.getFieldDataByCondition("makeserial", "ms_sncode", "ms_mac='" + mac + "' and  ms_sncode <>'" + ms_sncode.Text + "'").ToString();
-                        if (listmac != ""&& dh.CheckExist("product", "pr_code  = '" + ma_prodcode.Text + "' and pr_palletheight = -1 "))
+                        if (listmac != ""&& dh.CheckExist("product", "pr_code  = '" + ma_prodcode.Text + "' and pr_height = -1 "))
                         {
                             OperateResult.AppendText("<<序列号:" + listmac + " 已使用MAC:[" + mac + "]\n", Color.Red);
                             return;
@@ -750,7 +750,7 @@ namespace UAS_MES_NEW.Make
                         }
 
                         listmac = dh.getFieldDataByCondition("makeserial", "ms_sncode", "ms_mac='" + mac + "' and  ms_sncode <>'" + ms_sncode.Text + "'").ToString();
-                        if (listmac != "")
+                        if (listmac != "" && dh.CheckExist("product", "pr_code  = '" + ma_prodcode.Text + "' and pr_height = -1 "))
                         {
                             OperateResult.AppendText("<<序列号:" + listmac + " 已使用MAC:[" + mac + "]\n", Color.Red);
                             return;
@@ -764,7 +764,7 @@ namespace UAS_MES_NEW.Make
                         }
 
                         listbt = dh.getFieldDataByCondition("makeserial", "ms_sncode", "ms_mac='" + bt + "' and ms_sncode <>'" + ms_sncode.Text + "'").ToString();
-                        if (listbt != "")
+                        if (listbt != "" && dh.CheckExist("product", "pr_code  = '" + ma_prodcode.Text + "' and pr_volume = -1 "))
                         {
                             OperateResult.AppendText("<<序列号:" + listbt + " 已使用BT:[" + bt + "]\n", Color.Red);
                             return;