2014-06-10 127 views

回答

1

開始在這裏更新發票的例子:

你會首先檢索從QuickBooks發票:

$invoices = $InvoiceService->query($Context, $realm, "SELECT * FROM Invoice WHERE Id = '34' "); 
$Invoice = $invoices[0]; 

然後你就可以得到第三訂單項:

$Line = $Invoice->getLine(2); // zero-indexed, so "2" is the third line item 

然後你可以改變它:

$Line->setDescription('Here is my updated description'); 

然後更新發票:

$resp = $InvoiceService->update($Context, $realm, $Invoice->getId(), $Invoice); 
+0

感謝。按行更新工作。是否可以刪除發票? – Shino

+0

@Shino刪除發票的示例https://github.com/consolibyte/quickbooks-php/blob/master/docs/partner_platform/example_app_ipp_v3/example_invoice_delete.php –

相關問題