|
|
@@ -361,6 +361,8 @@ namespace UAS_LabelMachine
|
|
|
//计算当前采集数量
|
|
|
string collectqty = dh.getFieldDataByCondition("prodiobarcode", "sum(pib_qty)", "pib_inoutno='" + pi_inoutno.Text + "' and pib_prodcode='" + CurrentPrCode + "' and pib_pdno='" + CurrentPDNO + "'").ToString();
|
|
|
double CollectQty = (collectqty == "" ? 0 : double.Parse(collectqty));
|
|
|
+ Console.WriteLine(CollectQty + CollectNum);
|
|
|
+ Console.WriteLine(CurrentPrCount);
|
|
|
if (Convert.ToDouble((CollectQty + CollectNum).ToString("0.000")) > Convert.ToDouble(double.Parse(CurrentPrCount).ToString("0.000")))
|
|
|
{
|
|
|
MessageBox.Show("物料" + Data["PRCODE"] + "采集后数量为" + (CollectQty + CollectNum) + ",【超出】本行出货数量" + CurrentPrCount, "提示");
|
|
|
@@ -403,8 +405,9 @@ namespace UAS_LabelMachine
|
|
|
{
|
|
|
rowsnum = dh.BatchInsert(sql.ToString(), new string[] { "PIB_ID", "PIB_CUSTBARCODE" }, PIBID, CustBarCode.ToArray());
|
|
|
}
|
|
|
- catch (Exception)
|
|
|
+ catch (Exception e)
|
|
|
{
|
|
|
+ Console.WriteLine(e.Message + e.StackTrace);
|
|
|
if (ReSetType != " ")
|
|
|
{
|
|
|
dh.UpdateByCondition("RULEMAXNUM", "rmn_maxnumber='" + (MaxNum + 1) + "'", "rmn_nrcode='" + (NrCode == "" ? "Default" : NrCode) + "' and nvl(rmn_type,' ')='" + ReSetType + "'");
|
|
|
@@ -657,6 +660,7 @@ namespace UAS_LabelMachine
|
|
|
GridPrcode.FirstDisplayedScrollingRowIndex = i;
|
|
|
}
|
|
|
}
|
|
|
+ pib_indate.Text = dh.getFieldDataByCondition("prodiobarcode", "min(to_char(pib_indate,'yyyy-mm-dd'))", "pib_inoutno='" + pi_inoutno.Text + "'").ToString();
|
|
|
bi_inman.Text = dh.getFieldDataByCondition("barcodeio left join employee on bi_inman=em_code", "wm_concat(distinct em_name)", "bi_piid=" + PI_ID).ToString();
|
|
|
pib_inman.Text = dh.getFieldDataByCondition("prodiobarcode left join employee on pib_inman=em_code", "wm_concat(distinct em_name)", "pib_piid=" + PI_ID).ToString();
|
|
|
Attach = (DataTable)dh.ExecuteSql("select lap_param lp_name,lap_value lp_sql from LABELATTACHPARAMETER where lap_custcode='" + pi_cardcode.Text + "' and lap_inman='" + User.UserCode + "'", "select");
|
|
|
@@ -1952,13 +1956,15 @@ namespace UAS_LabelMachine
|
|
|
string FDC = LabelInf.Rows[i].Cells["pib_datecode"].Value.ToString();
|
|
|
string FLOTNO = LabelInf.Rows[i].Cells["pib_lotno"].Value.ToString();
|
|
|
string FPDCustProdCode = LabelInf.Rows[i].Cells["pd_custprodcode"].Value.ToString();
|
|
|
+ string FPDNO = LabelInf.Rows[i].Cells["pib_pdno"].Value.ToString();
|
|
|
string BPrcode = LabelInf.Rows[i + 1].Cells["pib_prodcode"].Value.ToString();
|
|
|
string BPocode = LabelInf.Rows[i + 1].Cells["pd_pocode"].Value.ToString();
|
|
|
string BWhcode = LabelInf.Rows[i + 1].Cells["pib_brand"].Value.ToString();
|
|
|
string BDC = LabelInf.Rows[i + 1].Cells["pib_datecode"].Value.ToString();
|
|
|
string BLOTNO = LabelInf.Rows[i + 1].Cells["pib_lotno"].Value.ToString();
|
|
|
string BPDCustProdCode = LabelInf.Rows[i + 1].Cells["pd_custprodcode"].Value.ToString();
|
|
|
- if ((DiffCPN.Checked && FPDCustProdCode != BPDCustProdCode) || FPrcode != BPrcode || FPocode != BPocode || FWhcode != BWhcode || (DiffDC.Checked && FDC != BDC) || (DiffLotNo.Checked && FLOTNO != BLOTNO))
|
|
|
+ string BPDNO = LabelInf.Rows[i + 1].Cells["pib_pdno"].Value.ToString();
|
|
|
+ if ((DiffDetno.Checked && BPDNO != FPDNO) || (DiffCPN.Checked && FPDCustProdCode != BPDCustProdCode) || FPrcode != BPrcode || FPocode != BPocode || FWhcode != BWhcode || (DiffDC.Checked && FDC != BDC) || (DiffLotNo.Checked && FLOTNO != BLOTNO))
|
|
|
{
|
|
|
MaxNum = MaxNum + 1;
|
|
|
}
|