|
|
@@ -190,37 +190,6 @@ namespace UAS_MES.Make
|
|
|
pa_currentqty.Text = dh.getFieldDataByCondition("package", "pa_currentqty", "pa_outboxcode='" + pa_outboxcode.Text + "'").ToString();
|
|
|
}
|
|
|
|
|
|
- private void InsertDetail()
|
|
|
- {
|
|
|
- if (dh.getFieldDataByCondition("makeserial", "ms_sncode", "ms_id='" + oMsID + "'").ToString() == sn_code.Text)
|
|
|
- {
|
|
|
- if (int.Parse(pa_currentqty.Text == "" ? "0" : pa_currentqty.Text) < int.Parse(pr_outboxinnerqty.Text))
|
|
|
- {
|
|
|
- if (LogicHandler.SetStepResult(pa_makecode.Text, User.UserSourceCode, sn_code.Text, "包装采集", "装箱成功", User.UserCode, out ErrorMessage))
|
|
|
- {
|
|
|
- LoadCheckQTY();
|
|
|
- OperateResult.AppendText(">>序列号" + sn_code.Text + "采集成功!\n", Color.Green);
|
|
|
- //满箱更新状态为1
|
|
|
- if (int.Parse(pa_currentqty.Text == "" ? "0" : pa_currentqty.Text) + 1 == int.Parse(pr_outboxinnerqty.Text))
|
|
|
- {
|
|
|
- //检查重量合格
|
|
|
- if (float.Parse(weight.Text) > MinWeight && float.Parse(weight.Text) < MaxWeight)
|
|
|
- {
|
|
|
- dh.UpdateByCondition("package", "pa_status=1", "pa_outboxcode='" + pa_outboxcode.Text + "'");
|
|
|
- if (AutoPrint.Checked)
|
|
|
- Print_Click(new object(), new EventArgs());
|
|
|
- }
|
|
|
- else OperateResult.AppendText(">>箱号" + pa_outboxcode.Text + "重量不符合标准重量\n", Color.Red);
|
|
|
- }
|
|
|
- LoadGridData();
|
|
|
- sn_code.Clear();
|
|
|
- }
|
|
|
- }
|
|
|
- else OperateResult.AppendText(">>箱号" + pa_outboxcode.Text + "已采集满\n", Color.Red);
|
|
|
- }
|
|
|
- else OperateResult.AppendText("序列号" + sn_code.Text + "不存在", Color.Red, sn_code);
|
|
|
- }
|
|
|
-
|
|
|
private void Print_Click(object sender, EventArgs e)
|
|
|
{
|
|
|
if (PrintLabel.Items.Count != 0)
|
|
|
@@ -339,7 +308,7 @@ namespace UAS_MES.Make
|
|
|
////箱号不存在的情况
|
|
|
if (LogicHandler.Packing(sn_code.Text, pa_outboxcode.Text, AutoGenBoxCode.Checked, "标准", User.UserSourceCode, User.UserCode, pr_outboxinnerqty.Text, Cancel.Checked, out oOutBoxCode, out ErrorMessage))
|
|
|
{
|
|
|
- if (LogicHandler.SetStepResult(pa_makecode.Text, User.UserSourceCode, sn_code.Text, "包装采集", "装箱成功", User.UserCode, out ErrorMessage))
|
|
|
+ if (LogicHandler.SetStepResult(ms_makecode.Text, User.UserSourceCode, sn_code.Text, "包装采集", "装箱成功", User.UserCode, out ErrorMessage))
|
|
|
{
|
|
|
LoadCheckQTY();
|
|
|
OperateResult.AppendText(">>序列号" + sn_code.Text + "采集成功!\n", Color.Green);
|