Browse Source

优化箱号拆解逻辑

callm 3 days ago
parent
commit
0768172f8e
1 changed files with 1 additions and 1 deletions
  1. 1 1
      UAS_MES_YDCY/PublicMethod/LogicHandler.cs

+ 1 - 1
UAS_MES_YDCY/PublicMethod/LogicHandler.cs

@@ -655,7 +655,7 @@ namespace UAS_MES_NEW.PublicMethod
             sql.Append("and sp_makecode='" + iMakeCode + "' and sp_stepcode='" + CurrentStep + "'");
             sql.Append("and sp_makecode='" + iMakeCode + "' and sp_stepcode='" + CurrentStep + "'");
             ExeSQL.Add(sql.ToString());
             ExeSQL.Add(sql.ToString());
             //更新大箱或栈板的母箱编号为空
             //更新大箱或栈板的母箱编号为空
-            ExeSQL.Add("update package set pa_mothercode='' where pa_outboxcode in(select PD_INNERBOXCODE from package left join packagedetail on pa_id=pd_paid where pa_outboxcode='" + iOutBoxCode + "')");
+            ExeSQL.Add("update package set pa_mothercode='' where pa_mothercode='" + iOutBoxCode + "')");
             //删除从表明细
             //删除从表明细
             ExeSQL.Add("delete from packagedetail where pd_paid=(select pa_id from package where pa_outboxcode='" + iOutBoxCode + "')");
             ExeSQL.Add("delete from packagedetail where pd_paid=(select pa_id from package where pa_outboxcode='" + iOutBoxCode + "')");
             //设置大箱或栈板的已装数量为0
             //设置大箱或栈板的已装数量为0