|
@@ -120,19 +120,19 @@ namespace UAS_MES.Make
|
|
|
OperateResult.AppendText(">>箱号不存在\n", Color.Red);
|
|
OperateResult.AppendText(">>箱号不存在\n", Color.Red);
|
|
|
return;
|
|
return;
|
|
|
}
|
|
}
|
|
|
- int ActualWeight = int.Parse(weight.Text == "" ? "0" : weight.Text);
|
|
|
|
|
|
|
+ double ActualWeight = double.Parse(weight.Text == "" ? "0" : weight.Text.Replace("kg", "").Trim());
|
|
|
if (ActualWeight > 0)
|
|
if (ActualWeight > 0)
|
|
|
{
|
|
{
|
|
|
//更新大箱重量
|
|
//更新大箱重量
|
|
|
sql.Clear();
|
|
sql.Clear();
|
|
|
sql.Append("update package set pa_weight='" + ActualWeight + "' where pa_outboxcode= '" + pa_outboxcode.Text + "'");
|
|
sql.Append("update package set pa_weight='" + ActualWeight + "' where pa_outboxcode= '" + pa_outboxcode.Text + "'");
|
|
|
dh.ExecuteSql(sql.GetString(), "update");
|
|
dh.ExecuteSql(sql.GetString(), "update");
|
|
|
- OperateResult.AppendText("<<<箱号:" + pa_outboxcode.Text + ",重量:" + ActualWeight + "克\n", Color.Green);
|
|
|
|
|
|
|
+ OperateResult.AppendText("<<<箱号:" + pa_outboxcode.Text + ",重量:" + weight.Text + "\n", Color.Green);
|
|
|
LogicHandler.InsertMakeProcess(pa_outboxcode.Text, pa_makecode.Text, User.UserSourceCode, "大箱称量", "大箱称量合格", User.UserCode);
|
|
LogicHandler.InsertMakeProcess(pa_outboxcode.Text, pa_makecode.Text, User.UserSourceCode, "大箱称量", "大箱称量合格", User.UserCode);
|
|
|
OperateResult.AppendText("<<<更新成功\n", Color.Green);
|
|
OperateResult.AppendText("<<<更新成功\n", Color.Green);
|
|
|
//刷新grid的历史称重信息;
|
|
//刷新grid的历史称重信息;
|
|
|
recordResult(pa_outboxcode.Text, weight.Text, System.DateTime.Now.ToString());
|
|
recordResult(pa_outboxcode.Text, weight.Text, System.DateTime.Now.ToString());
|
|
|
- LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, pa_makecode.Text, User.UserLineCode, User.UserSourceCode, "大箱称重", "称重成功", "", "");
|
|
|
|
|
|
|
+ LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, pa_makecode.Text, User.UserLineCode, User.UserSourceCode, "大箱称重:"+weight.Text, "称重成功", "", "");
|
|
|
if (autoprint.Checked == true)
|
|
if (autoprint.Checked == true)
|
|
|
{
|
|
{
|
|
|
try
|
|
try
|