This commit is contained in:
杰 朱
2022-05-20 09:10:08 +08:00
parent 192d432031
commit a997975bb9

View File

@@ -204,22 +204,22 @@ namespace NX.ERP.U8.AP
var id = Guid.NewGuid().ToString().Replace("-", "");
var vhobj = new NX.ERP.U8.VoucherHistory();
//var vhobj = new NX.ERP.U8.VoucherHistory();
var maxnumber = vhobj.getNumber("P0", "单据日期", ApVouch.Date.ToString("yyyyMM"));
//var maxnumber = vhobj.getNumber("P0", "单据日期", ApVouch.Date.ToString("yyyyMM"));
string temp = "";
//补足0
for (int i = 0; i < 5 - maxnumber.Length; i++)
{
temp += "0";
}
//string temp = "";
////补足0
//for (int i = 0; i < 5 - maxnumber.Length; i++)
//{
// temp += "0";
//}
var mouthstr = ApVouch.Date.ToString("yyyyMM").Substring(2, 4);
//var mouthstr = ApVouch.Date.ToString("yyyyMM").Substring(2, 4);
string cVouchID = "QTYF" + mouthstr + temp + maxnumber;
//string cVouchID = "QTYF" + mouthstr + temp + maxnumber;
@@ -247,7 +247,7 @@ namespace NX.ERP.U8.AP
headXml.setAttribute("VT_ID", 8056);
headXml.setAttribute("bd_c", false);
headXml.setAttribute("bStartFlag", false);
headXml.setAttribute("cVouchID", cVouchID);
headXml.setAttribute("cVouchID", "");
headXml.setAttribute("cFlag", "AP");
headXml.setAttribute("cDeptCode", ApVouch.DeptCode);
headXml.setAttribute("cDigest", ApVouch.Digest);