销售出库追加
This commit is contained in:
@@ -99,6 +99,60 @@ namespace NX.ERP.U8.Store
|
||||
|
||||
}
|
||||
|
||||
public bool UpdateVoucher(SaleStoreOut storeOut)
|
||||
{
|
||||
|
||||
VoucherParameter voucherParameter = this.LoadVoucher($"cCode='{storeOut.Code}'");
|
||||
|
||||
|
||||
|
||||
DOMDocument domBody = voucherParameter.DomBody;
|
||||
IXMLDOMElement bodyXml;
|
||||
|
||||
if (storeOut.Source == "发货单")
|
||||
{
|
||||
var dispatch = new Sale.DispatchListDAL().GetModel(storeOut.SourceCode);
|
||||
|
||||
for (var n = 0; n < storeOut.Details.Count; n++)
|
||||
{
|
||||
bodyXml = domBody.createElement("z:row");
|
||||
var detail = storeOut.Details[n];
|
||||
bodyXml.setAttribute("cinvcode", detail.InvCode);
|
||||
bodyXml.setAttribute("iquantity", detail.Quantity);
|
||||
|
||||
|
||||
|
||||
bodyXml.setAttribute("cposition", detail.Position);
|
||||
|
||||
bodyXml.setAttribute("editprop", "A");
|
||||
|
||||
|
||||
|
||||
bodyXml.setAttribute("irowno", domBody.selectSingleNode("//rs:data").childNodes.length + 1);
|
||||
domBody.selectSingleNode("//rs:data").appendChild(bodyXml);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
try
|
||||
{
|
||||
return UpdateRdVoucher(voucherParameter);
|
||||
}
|
||||
catch (Exception err)
|
||||
{
|
||||
|
||||
throw err;
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user