|
|
@@ -372,6 +372,7 @@ namespace UAS_MES.Make
|
|
|
SQLS.Add("update package set pa_mothercode='' where pa_outboxcode='" + outboxcode.Text + "'");
|
|
|
dh.ExecuteSQLTran(SQLS.ToArray());
|
|
|
OperateResult.AppendText(">>箱号" + outboxcode.Text + "取消采集成功\n", Color.Green);
|
|
|
+ LogicHandler.DoCommandLog(Tag.ToString(), User.UserCode, pa_makecode.Text, User.UserLineCode, User.UserSourceCode, "大箱采集", "大箱" + pa_outboxcode.Text + "取消采集卡通箱" + outboxcode.Text + "成功", outboxcode.Text, "");
|
|
|
LoadCollectNum();
|
|
|
palletcode_KeyDown(sender, e);
|
|
|
outboxcode.Clear();
|
|
|
@@ -402,16 +403,11 @@ namespace UAS_MES.Make
|
|
|
|
|
|
private void FillPrintLabel()
|
|
|
{
|
|
|
- DataTable _dt = (DataTable)dh.ExecuteSql("select la_id,la_printnos,substr(la_url,instr(la_url,'\\',-1)+1)la_name,la_url,la_isdefault from label where la_prodcode='" + pa_prodcode.Text + "' and la_templatetype='大箱标' and la_statuscode='AUDITED' order by la_isdefault", "select");
|
|
|
+ DataTable _dt = (DataTable)dh.ExecuteSql("select la_id,substr(la_url,instr(la_url,'\\',-1)+1)la_name,la_url,la_isdefault from label where la_prodcode='" + pa_prodcode.Text + "' and la_templatetype='大箱标' and la_statuscode='AUDITED' order by la_isdefault", "select");
|
|
|
PrintLabel.DataSource = _dt;
|
|
|
- PrintLabel.DisplayMember = "la_name";
|
|
|
+ PrintLabel.DisplayMember = "la_url";
|
|
|
PrintLabel.ValueMember = "la_id";
|
|
|
- for (int i = 0; i < _dt.Rows.Count; i++)
|
|
|
- {
|
|
|
- BaseUtil.GetPrintLabel(_dt.Rows[i]["la_name"].ToString(), _dt.Rows[i]["la_url"].ToString());
|
|
|
- }
|
|
|
}
|
|
|
-
|
|
|
private void LoadCollectNum()
|
|
|
{
|
|
|
pa_totalqty.Text = dh.getFieldDataByCondition("package", "pa_totalqty", "pa_outboxcode='" + pa_outboxcode.Text + "' and pa_type=2").ToString();
|
|
|
@@ -442,14 +438,6 @@ namespace UAS_MES.Make
|
|
|
{
|
|
|
if (dh.getFieldDataByCondition("package", "pa_status", "pa_outboxcode='" + pa_outboxcode.Text + "'").ToString() == "1")
|
|
|
{
|
|
|
- if (Print.CodeSoft(Tag.ToString(), ref lbl, PrintLabel.Text, PrintLabel.SelectedValue.ToString(), PrinterList.Text, pa_outboxcode.Text, int.Parse(PrintNum.Text), pa_makecode.Text, pa_prodcode.Text, "大箱标", "0", out ErrorMessage))
|
|
|
- {
|
|
|
- OperateResult.AppendText(">>打印箱号" + pa_outboxcode.Text + "\n", Color.Black);
|
|
|
- }
|
|
|
- else
|
|
|
- {
|
|
|
- OperateResult.AppendText(ErrorMessage + "\n", Color.Red);
|
|
|
- }
|
|
|
if (!AutoOutBoxCode.Checked)
|
|
|
{
|
|
|
pa_outboxcode.Focus();
|
|
|
@@ -460,10 +448,19 @@ namespace UAS_MES.Make
|
|
|
outboxcode.Focus();
|
|
|
outboxcode.SelectAll();
|
|
|
}
|
|
|
+ //doc = lbl.Documents.Open(PrintLabel.Text);
|
|
|
+ if (Print.CodeSoft(Tag.ToString(), ref lbl, PrintLabel.Text, PrintLabel.SelectedValue.ToString(), PrinterList.Text, pa_outboxcode.Text, int.Parse(PrintNum.Text), pa_makecode.Text, pa_prodcode.Text, "大箱标", "0", out ErrorMessage))
|
|
|
+ {
|
|
|
+ OperateResult.AppendText(">>打印大箱" + pa_outboxcode.Text + "\n", Color.Black);
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ OperateResult.AppendText(ErrorMessage + "\n", Color.Red);
|
|
|
+ }
|
|
|
}
|
|
|
- else OperateResult.AppendText(">>必须封箱才能进行打印\n", Color.Red);
|
|
|
+ else OperateResult.AppendText(">>必须封大箱才能进行打印\n", Color.Red);
|
|
|
}
|
|
|
- else OperateResult.AppendText(">>产品" + pa_prodcode.Text + "未维护打印标签或者标签未审核\n", Color.Red);
|
|
|
+ else OperateResult.AppendText(">>产品" + pa_prodcode.Text + "未维护打印标签\n", Color.Red);
|
|
|
}
|
|
|
|
|
|
private void ReleasePallet_Click(object sender, EventArgs e)
|