quickbooks 桌面网络连接器 qbxml:使用 CLASS 字段添加发票
quickbooks desktop web connector qbxml: add invoice with CLASS field
我正在尝试添加发票并用一个值填充其 CLASS 字段(我无法 post 发票 "CLASS" 字段的屏幕截图,因为我不知道t have the reputation, its the field just to the right of "PRICE EACH" field), 我不知道如何在 qbxml 中添加 CLASS 值。
这是我正在使用的 xml,它可以工作:
$xml = '<?xml version="1.0" encoding="utf-8"?>
<?qbxml version="2.0"?>
<QBXML>
<QBXMLMsgsRq onError="stopOnError">
<InvoiceAddRq requestID="xxxxxxxx">
<InvoiceAdd>
<CustomerRef>
<FullName>Some company:12 street gotham</FullName>
</CustomerRef>
<TxnDate>2015-01-23</TxnDate>
<RefNumber>TPY125</RefNumber>
<BillAddress>
<Addr1>some bill address</Addr1>
<City>some bill city</City>
<State>some bill state</State>
<PostalCode>some bill zip</PostalCode>
<Country>United States</Country>
</BillAddress>
<ShipAddress>
<Addr1>some ship address</Addr1>
<City>some ship address</City>
<State>some ship state</State>
<PostalCode>some ship zip</PostalCode>
<Country>United States</Country>
</ShipAddress>
<PONumber></PONumber>
<TermsRef>
<FullName>Net 120</FullName>
</TermsRef>
<Memo></Memo>
<InvoiceLineAdd>
<ItemRef>
<FullName>16 Electrical and Lighting</FullName>
</ItemRef>
<Desc>Item 1 Description Goes Here</Desc>
<Quantity>1</Quantity>
<Rate>33.00</Rate>
</InvoiceLineAdd>
</InvoiceAdd>
</InvoiceAddRq>
</QBXMLMsgsRq>
</QBXML>';
我正在使用 QuickBooks Enterprise,Web 连接器版本:2.1.0.30。那么我必须在 "CLASS" 字段的 xml 中添加什么?
提前致谢。
您始终可以参考 QuickBooks OSR 以获得 XML QuickBooks 桌面参考:
在这种特定情况下,您可以像这样在每个订单项的基础上设置 Class
:
...
<InvoiceLineAdd>
<ItemRef>
<FullName>16 Electrical and Lighting</FullName>
</ItemRef>
<Desc>Item 1 Description Goes Here</Desc>
<Quantity>1</Quantity>
<Rate>33.00</Rate>
<ClassRef>
<ListID> ... specify a ListID here ...</ListID
<!-- Or, instead of ListID you can specify: -->
<FullName> ... specify Class FullName here ...</FullName>
</InvoiceLineAdd>
...
我正在尝试添加发票并用一个值填充其 CLASS 字段(我无法 post 发票 "CLASS" 字段的屏幕截图,因为我不知道t have the reputation, its the field just to the right of "PRICE EACH" field), 我不知道如何在 qbxml 中添加 CLASS 值。 这是我正在使用的 xml,它可以工作:
$xml = '<?xml version="1.0" encoding="utf-8"?>
<?qbxml version="2.0"?>
<QBXML>
<QBXMLMsgsRq onError="stopOnError">
<InvoiceAddRq requestID="xxxxxxxx">
<InvoiceAdd>
<CustomerRef>
<FullName>Some company:12 street gotham</FullName>
</CustomerRef>
<TxnDate>2015-01-23</TxnDate>
<RefNumber>TPY125</RefNumber>
<BillAddress>
<Addr1>some bill address</Addr1>
<City>some bill city</City>
<State>some bill state</State>
<PostalCode>some bill zip</PostalCode>
<Country>United States</Country>
</BillAddress>
<ShipAddress>
<Addr1>some ship address</Addr1>
<City>some ship address</City>
<State>some ship state</State>
<PostalCode>some ship zip</PostalCode>
<Country>United States</Country>
</ShipAddress>
<PONumber></PONumber>
<TermsRef>
<FullName>Net 120</FullName>
</TermsRef>
<Memo></Memo>
<InvoiceLineAdd>
<ItemRef>
<FullName>16 Electrical and Lighting</FullName>
</ItemRef>
<Desc>Item 1 Description Goes Here</Desc>
<Quantity>1</Quantity>
<Rate>33.00</Rate>
</InvoiceLineAdd>
</InvoiceAdd>
</InvoiceAddRq>
</QBXMLMsgsRq>
</QBXML>';
我正在使用 QuickBooks Enterprise,Web 连接器版本:2.1.0.30。那么我必须在 "CLASS" 字段的 xml 中添加什么? 提前致谢。
您始终可以参考 QuickBooks OSR 以获得 XML QuickBooks 桌面参考:
在这种特定情况下,您可以像这样在每个订单项的基础上设置 Class
:
...
<InvoiceLineAdd>
<ItemRef>
<FullName>16 Electrical and Lighting</FullName>
</ItemRef>
<Desc>Item 1 Description Goes Here</Desc>
<Quantity>1</Quantity>
<Rate>33.00</Rate>
<ClassRef>
<ListID> ... specify a ListID here ...</ListID
<!-- Or, instead of ListID you can specify: -->
<FullName> ... specify Class FullName here ...</FullName>
</InvoiceLineAdd>
...