php - How to add phone number in quickbook vendor? -
i unable add primaryphone, alternativephone, primaryemailaddr, webaddr and, billaddr in vendor. thing wrong pass value vendor api? please me how pass value.
$dataservice = quickbookconnection::createqbconnection(); $servicetype = intuitservicestype::qbo; $vendobj = new ippvendor(); $vendobj->synctoken = $venddata['contactid']; $vendobj->givenname = $venddata['fname']; $vendobj->familyname = $venddata['lname']; $vendobj->displayname = $venddata['cname']; $vendobj->companyname = $venddata['cname']; $vendobj->primaryphone = $venddata['phone']; $vendobj->alternatephone = $venddata['altphone']; $vendobj->primaryemailaddr = $venddata['email']; $vendobj->webaddr = $venddata['web']; $vendobj->billaddr = $venddata['address'] ." ". $venddata['citystate']; $vendobj->active = true; $resultingobj = $dataservice->add($vendobj); $qbvendorid = $resultingobj->id;
all above mentioned properties complex types. see- https://developer.intuit.com/docs/api/accounting/vendor
primaryemailaddr has child attribute 'address' same way other above fields have child attribute need set instead of top property name.
Comments
Post a Comment