This commit is contained in:
gongxh
2021-03-15 13:34:02 +08:00
parent 01e1f930e9
commit f56c8806e7
14 changed files with 45 additions and 39 deletions

View File

@@ -61,7 +61,7 @@ namespace NX.ERP.U8.Store
bodyXml.setAttribute("iprice", new Account.Accinformation().FormatMoney(_cost * detail.Quantity));
bodyXml.setAttribute("irowno", n + 1);
bodyXml.setAttribute("editprop", "A");
bodyXml.setAttribute("cbatch", detail.Batch);
bodyXml.setAttribute("cposition", detail.Position);
var momOrderDetail = momOrder.ProductDtlLst.First(m => { return m.ProductOrderDtlId == detail.SourceDetailId; });
@@ -87,14 +87,14 @@ namespace NX.ERP.U8.Store
public bool UpdateVoucher(ProductStoreIn storeIn)
{
var voucherParameter = this.LoadVoucher($"cCode='{storeIn.Code}'");
var voucherParameter = this.LoadVoucher($"id='{storeIn.Id}'");
DOMDocument domBody = voucherParameter.DomBody;
if (storeIn.Source == "生产订单")
{
var momOrder = new Mom.MomOrderDAL().GetModel(storeIn.SourceCode);
IXMLDOMElement bodyXml;
for (var n = 0; n < storeIn.Details.Count; n++)
{
@@ -105,20 +105,20 @@ namespace NX.ERP.U8.Store
var _cost = new MaterialDAL().GetCost(detail.InvCode, 0);
bodyXml.setAttribute("iunitcost", _cost);
bodyXml.setAttribute("iprice", new Account.Accinformation().FormatMoney(_cost * detail.Quantity));
bodyXml.setAttribute("editprop", "A");
bodyXml.setAttribute("cbatch", detail.Batch);
bodyXml.setAttribute("cposition", detail.Position);
var momOrderDetail = momOrder.ProductDtlLst.First(m => { return m.ProductOrderDtlId == detail.SourceDetailId; });
bodyXml.setAttribute("cmocode", momOrder.ProductOrderNo);
bodyXml.setAttribute("impoids", detail.SourceDetailId);
bodyXml.setAttribute("irowno", domBody.selectSingleNode("//rs:data").childNodes.length + 1);
domBody.selectSingleNode("//rs:data").appendChild(bodyXml);
}
}
try
{
return UpdateRdVoucher(voucherParameter);