|
|
@@ -73,19 +73,18 @@ namespace UAS_MES.Make
|
|
|
OperateResult.Clear();
|
|
|
}
|
|
|
|
|
|
- //大箱号Enter事件
|
|
|
private void palletcode_KeyDown(object sender, KeyEventArgs e)
|
|
|
{
|
|
|
if (e.KeyCode == Keys.Enter)
|
|
|
{
|
|
|
if (palletcode.Text == "")
|
|
|
{
|
|
|
- OperateResult.AppendText(">>大箱号不能为空\n", Color.Red);
|
|
|
+ OperateResult.AppendText(">>栈板号不能为空\n", Color.Red);
|
|
|
return;
|
|
|
}
|
|
|
sql.Clear();
|
|
|
sql.Append("select pa_makecode,pa_packageqty,pa_prodcode,pa_outboxcode,pa_totalqty,pa_custcode,pa_salecode ");
|
|
|
- sql.Append("from package where pa_outboxcode='" + palletcode.Text + "' and pa_type =2");
|
|
|
+ sql.Append("from package where pa_outboxcode='" + palletcode.Text + "' and pa_type =3");
|
|
|
dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
|
|
|
BaseUtil.SetFormValue(Controls, dt);
|
|
|
if (dt.Rows.Count > 0)
|
|
|
@@ -97,7 +96,7 @@ namespace UAS_MES.Make
|
|
|
FillPrintLabel();
|
|
|
outboxcode.Focus();
|
|
|
}
|
|
|
- else OperateResult.AppendText(">>大箱号不存在\n", Color.Red);
|
|
|
+ else OperateResult.AppendText(">>栈板号不存在\n", Color.Red);
|
|
|
}
|
|
|
}
|
|
|
|
|
|
@@ -108,12 +107,12 @@ namespace UAS_MES.Make
|
|
|
{
|
|
|
if (outboxcode.Text == "")
|
|
|
{
|
|
|
- OperateResult.AppendText(">>卡通箱号不能为空\n", Color.Red);
|
|
|
+ OperateResult.AppendText(">>箱号不能为空\n", Color.Red);
|
|
|
return;
|
|
|
}
|
|
|
- if (!dh.CheckExist("package", "pa_outboxcode='" + palletcode.Text + "' and pa_type=2"))
|
|
|
+ if (!dh.CheckExist("package", "pa_outboxcode='" + palletcode.Text + "' and pa_type=3"))
|
|
|
{
|
|
|
- OperateResult.AppendText(">>大箱号不存在\n", Color.Red);
|
|
|
+ OperateResult.AppendText(">>栈板号不存在\n", Color.Red);
|
|
|
return;
|
|
|
}
|
|
|
sql.Clear();
|
|
|
@@ -132,22 +131,22 @@ namespace UAS_MES.Make
|
|
|
sql.Append("insert into packagedetail(pd_id, pd_paid, pd_outboxcode, pd_innerboxcode, pd_innerqty)");
|
|
|
sql.Append("values(packagedetail_seq.nextval,'" + pa_id + "','" + palletcode.Text + "','" + outboxcode.Text + "','" + pa_totalqty.Text + "')");
|
|
|
dh.ExecuteSql(sql.GetString(), "insert");
|
|
|
- dh.UpdateByCondition("package", "pa_totalqty=pa_totalqty+1", "pa_outboxcode='" + outboxcode.Text + "' and pa_type=2");
|
|
|
- OperateResult.AppendText(">>卡通箱号" + outboxcode.Text + "采集成功!\n", Color.Green, outboxcode);
|
|
|
+ dh.UpdateByCondition("package", "pa_totalqty=pa_totalqty+1", "pa_outboxcode='" + outboxcode.Text + "' and pa_type=3");
|
|
|
+ OperateResult.AppendText(">>箱号" + outboxcode.Text + "采集成功!\n", Color.Green, outboxcode);
|
|
|
LoadGridData();
|
|
|
LoadCollectNum();
|
|
|
//判断明细和箱内的件数的差是不是1,如果只相差1则表示此时已经采集慢了
|
|
|
if (packageqty + 1 == pa_packqty && AutoPrint.Checked)
|
|
|
{
|
|
|
- OperateResult.AppendText(">>箱已装满,自动打印!\n", Color.Green);
|
|
|
+ OperateResult.AppendText(">>栈板"+outboxcode.Text+"已装满,自动打印!\n", Color.Green);
|
|
|
Printlab.PerformClick();
|
|
|
}
|
|
|
}
|
|
|
- else OperateResult.AppendText(">>卡通箱号" + outboxcode.Text + "已采集\n", Color.Red, outboxcode);
|
|
|
+ else OperateResult.AppendText(">>箱号" + outboxcode.Text + "已采集\n", Color.Red, outboxcode);
|
|
|
}
|
|
|
- else OperateResult.AppendText(">>卡通箱号" + outboxcode.Text + "不存在\n", Color.Red, outboxcode);
|
|
|
+ else OperateResult.AppendText(">>箱号" + outboxcode.Text + "不存在\n", Color.Red, outboxcode);
|
|
|
}
|
|
|
- else OperateResult.AppendText(">>大箱" + palletcode.Text + "已装满\n", Color.Red, outboxcode);
|
|
|
+ else OperateResult.AppendText(">>栈板号" + palletcode.Text + "已装满\n", Color.Red, outboxcode);
|
|
|
}
|
|
|
}
|
|
|
|
|
|
@@ -156,7 +155,7 @@ namespace UAS_MES.Make
|
|
|
sql.Clear();
|
|
|
sql.Append("select pa_prodcode,nvl(pd_barcode,PD_INNERBOXCODE) code ,pd_innerqty,pa_salecode");
|
|
|
sql.Append(",pa_makecode,pa_custcode,pa_packageqty from packagedetail left join package on pd_paid=pa_id left ");
|
|
|
- sql.Append("join product on pr_code=pa_prodcode where pa_outboxcode ='" + palletcode.Text + "' and pa_type=2");
|
|
|
+ sql.Append("join product on pr_code=pa_prodcode where pa_outboxcode ='" + palletcode.Text + "' and pa_type=3");
|
|
|
dt = (DataTable)dh.ExecuteSql(sql.GetString(), "select");
|
|
|
BaseUtil.FillDgvWithDataTable(PackageInf, dt);
|
|
|
}
|
|
|
@@ -178,7 +177,7 @@ namespace UAS_MES.Make
|
|
|
|
|
|
private void LoadCollectNum()
|
|
|
{
|
|
|
- pa_totalqty.Text = dh.getFieldDataByCondition("package", "pa_totalqty", "pa_outboxcode='" + outboxcode.Text + "' and pa_type=2").ToString();
|
|
|
+ pa_totalqty.Text = dh.getFieldDataByCondition("package", "pa_totalqty", "pa_outboxcode='" + outboxcode.Text + "' and pa_type=3").ToString();
|
|
|
}
|
|
|
|
|
|
private void 栈板称重_SizeChanged(object sender, EventArgs e)
|
|
|
@@ -188,7 +187,7 @@ namespace UAS_MES.Make
|
|
|
|
|
|
private void NewPallet_Click(object sender, EventArgs e)
|
|
|
{
|
|
|
- Make_NewPallet NewPallet = new Make_NewPallet("PACKAGE", pa_makecode.Text);
|
|
|
+ Make_NewPallet NewPallet = new Make_NewPallet("PALLET", pa_makecode.Text);
|
|
|
BaseUtil.SetFormCenter(NewPallet);
|
|
|
NewPallet.ShowDialog();
|
|
|
}
|