|
|
@@ -301,20 +301,24 @@ namespace UAS_MES.Make
|
|
|
{
|
|
|
if (dh.getRowCount("packagedetail", "pd_outboxcode='" + palletcode.Text + "'") > 0)
|
|
|
{
|
|
|
- //如果含有下一执行步骤的撤销过站,否则直接删除
|
|
|
- if (dh.getFieldDataByCondition("package", "pa_nextstep", "pa_mothercode='" + palletcode.Text + "'").ToString() != "")
|
|
|
- LogicHandler.OutBoxDrawStepPass(palletcode.Text, pa_makecode.Text, User.UserSourceCode);
|
|
|
- else
|
|
|
+ string Delete = MessageBox.Show(this.ParentForm, "是否确认拆栈板?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question).ToString();
|
|
|
+ if (Delete == "Yes")
|
|
|
{
|
|
|
- List<string> SQLS = new List<string>();
|
|
|
- SQLS.Add("delete from packagedetail where pd_outboxcode='" + palletcode.Text + "'");
|
|
|
- SQLS.Add("update package set pa_packageqty=0,pa_totalqty=0,pa_currentqty=0,pa_status=0 where pa_outboxcode='" + palletcode.Text + "'");
|
|
|
- SQLS.Add("update package set pa_mothercode='' where pa_mothercode='" + palletcode.Text + "'");
|
|
|
- dh.ExecuteSQLTran(SQLS.ToArray());
|
|
|
+ //如果含有下一执行步骤的撤销过站,否则直接删除
|
|
|
+ if (dh.getFieldDataByCondition("package", "pa_nextstep", "pa_mothercode='" + palletcode.Text + "'").ToString() != "")
|
|
|
+ LogicHandler.OutBoxDrawStepPass(palletcode.Text, pa_makecode.Text, User.UserSourceCode);
|
|
|
+ else
|
|
|
+ {
|
|
|
+ List<string> SQLS = new List<string>();
|
|
|
+ SQLS.Add("delete from packagedetail where pd_outboxcode='" + palletcode.Text + "'");
|
|
|
+ SQLS.Add("update package set pa_packageqty=0,pa_totalqty=0,pa_currentqty=0,pa_status=0 where pa_outboxcode='" + palletcode.Text + "'");
|
|
|
+ SQLS.Add("update package set pa_mothercode='' where pa_mothercode='" + palletcode.Text + "'");
|
|
|
+ dh.ExecuteSQLTran(SQLS.ToArray());
|
|
|
+ }
|
|
|
+ LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, pa_makecode.Text, User.UserLineCode, User.UserSourceCode, "栈板采集", "解除栈板" + palletcode.Text + "成功", palletcode.Text, "");
|
|
|
+ OperateResult.AppendText(">>栈板号" + palletcode.Text + "解除成功\n", Color.Green);
|
|
|
+ palletcode_KeyDown(new object(), new KeyEventArgs(Keys.Enter));
|
|
|
}
|
|
|
- LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, pa_makecode.Text, User.UserLineCode, User.UserSourceCode, "栈板采集", "解除栈板" + palletcode.Text + "成功", palletcode.Text, "");
|
|
|
- OperateResult.AppendText(">>栈板号" + palletcode.Text + "解除成功\n", Color.Green);
|
|
|
- palletcode_KeyDown(new object(), new KeyEventArgs(Keys.Enter));
|
|
|
}
|
|
|
else OperateResult.AppendText(">>栈板号" + palletcode.Text + "未采集箱\n", Color.Red);
|
|
|
}
|
|
|
@@ -336,10 +340,14 @@ namespace UAS_MES.Make
|
|
|
{
|
|
|
if (dt.Rows[0]["pa_status"].ToString() == "0")
|
|
|
{
|
|
|
- OperateResult.AppendText(">>栈板号" + palletcode.Text + "装栈板成功\n", Color.Green);
|
|
|
- LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, pa_makecode.Text, User.UserLineCode, User.UserSourceCode, "栈板采集", "装栈板" + palletcode.Text + "成功", outboxcode.Text, "");
|
|
|
- dh.ExecuteSql("update package set pa_status=1 where pa_outboxcode='" + palletcode.Text + "'", "update");
|
|
|
- pa_status.Text = "1";
|
|
|
+ string Seal = MessageBox.Show(this.ParentForm, "是否确认封栈板?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question).ToString();
|
|
|
+ if (Seal == "Yes")
|
|
|
+ {
|
|
|
+ OperateResult.AppendText(">>栈板号" + palletcode.Text + "装栈板成功\n", Color.Green);
|
|
|
+ LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, pa_makecode.Text, User.UserLineCode, User.UserSourceCode, "栈板采集", "装栈板" + palletcode.Text + "成功", outboxcode.Text, "");
|
|
|
+ dh.ExecuteSql("update package set pa_status=1 where pa_outboxcode='" + palletcode.Text + "'", "update");
|
|
|
+ pa_status.Text = "1";
|
|
|
+ }
|
|
|
}
|
|
|
else OperateResult.AppendText(">>栈板号" + palletcode.Text + "已封栈板\n", Color.Red);
|
|
|
}
|