我有Create a Vendor Payment
代码,代码为Vendor Bill
:
InitializeRecord ir = new InitializeRecord();
ir.type = InitializeType.vendorPayment;
InitializeRef iref = new InitializeRef();
iref.typeSpecified = true;
iref.type = InitializeRefType.vendorBill;
iref.internalId = vendorBillId;
ir.reference = iref;
Login();
ReadResponse getInitResp = _service.initialize(ir);
if (getInitResp.status.isSuccess)
{
Record rec = getInitResp.record;
((VendorPayment)rec).total = (double)amount; //I don't want to pall all, just pay a half or just an amount less than the total
((VendorPayment)rec).totalSpecified = true;
WriteResponse writeRes = _service.add(rec);
return writeRes.status;
}
这可以创建付款,但总金额不适用,付款是支付所有供应商账单的总额。
我不知道我在这里缺少什么。
答案 0 :(得分:1)
在向帐单付款时,您无法更改正文级别金额字段。您必须更改amount
订单项记录中的apply
行级字段。我不确定Suitetalk的语法,但是,这应该有用。