have a problem with QB PHP api, when creating Invoices I can not set the email address. Here is the code;
$InvoiceService = new QuickBooks_IPP_Service_Invoice();
$Invoice = new QuickBooks_IPP_Object_Invoice();
$Invoice->setDocNumber($sale->ID);
$Invoice->setDueDate($sale->duedate);
$Invoice->setCustomerRef($customer->qbID);
$Invoice->setBillEmail("at@at.com");
setBillEmail should work, but can not understand why it is not working.
The QuickBooks PHP libs exactly mirror the Intuit schema. That means that when you see a nested object in the schema like this:
"BillEmail": {
"Address": "Familiystore@intuit.com"
},
You need a nested object in your PHP code too:
$BillEmail = new QuickBooks_IPP_Object_BillEmail();
$BillEmail->setAddress('you@youremail.com');
$Invoice->setBillEmail($BillEmail);
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.