|
|
@@ -289,7 +289,7 @@ namespace UAS_LabelMachine
|
|
|
string pib_outboxcode2 = "";
|
|
|
if (OutBoxNum.Text == "新增")
|
|
|
{
|
|
|
- string maxoutbox = dh.getFieldDataByCondition("prodiobarcode", "max(pib_outboxcode2)", "pib_inoutno='" + pi_inoutno.Text + "'").ToString();
|
|
|
+ string maxoutbox = dh.getFieldDataByCondition("prodiobarcode", "max(to_number(pib_outboxcode2))", "pib_inoutno='" + pi_inoutno.Text + "'").ToString();
|
|
|
//如果没有则从开始插入
|
|
|
if (maxoutbox == "")
|
|
|
{
|
|
|
@@ -987,7 +987,7 @@ namespace UAS_LabelMachine
|
|
|
|
|
|
try
|
|
|
{
|
|
|
- OutReport.Print();
|
|
|
+ OutReport.Show();
|
|
|
}
|
|
|
catch (Exception e)
|
|
|
{
|
|
|
@@ -1477,7 +1477,7 @@ namespace UAS_LabelMachine
|
|
|
private void PrintFooter_Click(object sender, EventArgs e)
|
|
|
{
|
|
|
DataTable dt = (DataTable)dh.ExecuteSql("select pib_outboxcode2,max(pib_id) pib_id from prodiobarcode where pib_inoutno='" + pi_inoutno.Text + "' group by pib_outboxcode2 order by pib_outboxcode2", "select");
|
|
|
- string SQL = "select pib_outboxcode2||'/'||(select max(pib_outboxcode2) from prodiobarcode where pib_inoutno='" + pi_inoutno.Text + "') from prodiobarcode where pib_id=";
|
|
|
+ string SQL = "select pib_outboxcode2||'/'||(select max(to_number(pib_outboxcode2)) from prodiobarcode where pib_inoutno='" + pi_inoutno.Text + "') from prodiobarcode where pib_id=";
|
|
|
for (int i = 0; i < dt.Rows.Count; i++)
|
|
|
{
|
|
|
DataTable dt1 = (DataTable)dh.ExecuteSql(SQL + dt.Rows[i]["pib_id"].ToString(), "select");
|
|
|
@@ -1590,7 +1590,7 @@ namespace UAS_LabelMachine
|
|
|
if (Radix > 0)
|
|
|
{
|
|
|
//生成中盒条码
|
|
|
- int pib_outboxcode1 = int.Parse(dh.getFieldDataByCondition("prodiobarcode", "nvl(max(pib_outboxcode1),0)", "pib_inoutno='" + pi_inoutno.Text + "'").ToString());
|
|
|
+ int pib_outboxcode1 = int.Parse(dh.getFieldDataByCondition("prodiobarcode", "max(to_number(nvl(pib_outboxcode1,0)))", "pib_inoutno='" + pi_inoutno.Text + "'").ToString());
|
|
|
MaxNum = MaxNum - 1;
|
|
|
for (int i = 0; i < dt.Rows.Count; i++)
|
|
|
{
|