Browse Source

Merge branch 'master' of ssh://10.10.100.21/source/mes-client

callm 5 years ago
parent
commit
d661a08b46
1 changed files with 7 additions and 5 deletions
  1. 7 5
      UAS-MES/FunctionCode/Make/Make_RePrintLabel.cs

+ 7 - 5
UAS-MES/FunctionCode/Make/Make_RePrintLabel.cs

@@ -149,7 +149,7 @@ namespace UAS_MES.Make
                 else if (CartonBox.Checked||BigBox.Checked)
                 {
                     //查询箱号是否存在
-                    dt = (DataTable)dh.ExecuteSql("select pa_id,pa_prodcode pr_code,pa_makecode ms_makecode,pr_detail from package left join product on pr_code=pa_prodcode where pa_outboxcode='" + inputText.Text + "' and pa_type=1", "select");
+                    dt = (DataTable)dh.ExecuteSql("select pa_id,pa_prodcode pr_code,pa_makecode ms_makecode,pr_detail from package left join product on pr_code=pa_prodcode where pa_outboxcode='" + inputText.Text + "' and (pa_type=1 OR PA_TYPE = 2)", "select");
                     if (dt.Rows.Count == 0)
                     {
                         //无值,返回提示用户“箱号不存在”, “>>请输入卡通箱号”
@@ -177,8 +177,10 @@ namespace UAS_MES.Make
                 type = "机身标";
             else if (giftBox.Checked)
                 type = "彩盒标";
-            else
+            else if (CartonBox.Checked)
                 type = "卡通箱标";
+            else
+                type = "大箱标";
 
             getlabel = "select la_id,substr(la_url,instr(la_url,'\\',-1)+1)la_name,la_url,la_isdefault from label where la_prodcode='" + pr_code.Text + "' and la_templatetype='" + type + "' and la_statuscode='AUDITED' order by la_isdefault";
 
@@ -382,11 +384,11 @@ namespace UAS_MES.Make
                     //第一次输入
                     if (TSN == "")
                     {
-                        infoc = (DataTable)dh.ExecuteSql("select pa_prodcode,pa_makecode,pa_downstatus from package where pa_outboxcode='" + rePrintCheck.Text + "' and pa_type=1", "select");
+                        infoc = (DataTable)dh.ExecuteSql("select pa_prodcode,pa_makecode,pa_downstatus from package where pa_outboxcode='" + rePrintCheck.Text + "' and (pa_type=1 or pa_type =2)", "select");
                         //如果查询无值,提示用户卡通箱号不存在,请输入卡通箱号
                         if (infoc.Rows.Count == 0)
                         {
-                            OperateResult.AppendText("<<卡通箱号:" + rePrintCheck.Text + "不存在\n", Color.Red, rePrintCheck);
+                            OperateResult.AppendText("<<箱号:" + rePrintCheck.Text + "不存在\n", Color.Red, rePrintCheck);
                             OperateResult.AppendText(">>请输入箱号\n", Color.Black);
                             return;
                         }
@@ -415,7 +417,7 @@ namespace UAS_MES.Make
                             }
                             printBtn.Enabled = true;
                             //记录操作日志commandlog , 补打核对,核对成功
-                            LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, infoc.Rows[0]["pa_makecode"].ToString(), User.UserLineCode, User.UserSourceCode, "标签补打核对,卡通箱号:" + TSN, "核对成功", TSN, "");
+                            LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, infoc.Rows[0]["pa_makecode"].ToString(), User.UserLineCode, User.UserSourceCode, "标签补打核对,箱号:" + TSN, "核对成功", TSN, "");
                         }
                         else
                         {