其他入库修改
This commit is contained in:
@@ -85,10 +85,35 @@ namespace NX.ERP.U8.Store
|
||||
}
|
||||
|
||||
|
||||
public bool UpdateVoucher(ProductStoreIn storeIn)
|
||||
|
||||
public string SaveVoucher(Model.Request.ProductStoreIn storeIn)
|
||||
{
|
||||
var voucherParameter = this.LoadVoucher($"id='{storeIn.Id}'");
|
||||
if (voucherParameter.DomHead.selectSingleNode("//rs:data").childNodes.length == 0)
|
||||
{
|
||||
return this.AddVoucher(storeIn);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (this.UpdateVoucher(storeIn, voucherParameter))
|
||||
{
|
||||
return storeIn.Id.ToString();
|
||||
}
|
||||
else
|
||||
{
|
||||
throw new Exception("保存错误");
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public bool UpdateVoucher(ProductStoreIn storeIn, VoucherParameter voucherParameter=null)
|
||||
{
|
||||
if (voucherParameter == null)
|
||||
{
|
||||
voucherParameter = this.LoadVoucher($"id='{storeIn.Id}'");
|
||||
}
|
||||
DOMDocument domBody = voucherParameter.DomBody;
|
||||
|
||||
if (storeIn.Source == "生产订单")
|
||||
|
||||
Reference in New Issue
Block a user