まずオフOAuthのプロセスを介して取得することはできませんしかし、それは間違いだったようです。QuickBooksのPHPのAPI再び
もう一度承認プロセスを再試行しようとしていますが、クイックスタートに記載されている「docs/example_app_ipp_v3 /」ページの「QuickBooksに接続」ボタンをクリックするとエラーが表示されますガイド。
ここに何か不足していますか?私はまだAPIエクスプローラを介してクエリを実行できますが、コード内で$ InvoiceService->クエリを使用すると、データを取得できないように見えます(falseを返す)。
//get invoice info
require_once '../includes/quickbooks-php/config.php';
// Set up the IPP instance
$IPP = new QuickBooks_IPP($dsn);
// Get our OAuth credentials from the database
$creds = $IntuitAnywhere->load($the_username, $the_tenant);
//error_reporting(0);
//ini_set('display_errors', 1);
// Tell the framework to load some data from the OAuth store
$IPP->authMode(
QuickBooks_IPP::AUTHMODE_OAUTH,
$the_username,
$creds);
// This is our current realm
$realm = $creds['qb_realm'];
// Load the OAuth information from the database
if ($Context = $IPP->context())
{
// Set the IPP version to v3
$IPP->version(QuickBooks_IPP_IDS::VERSION_3);
$CustomerService = new QuickBooks_IPP_Service_Customer();
$InvoiceService = new QuickBooks_IPP_Service_Invoice();
$ItemService = new QuickBooks_IPP_Service_Item();
$PaymentService = new QuickBooks_IPP_Service_Payment();
$invoice_query = $InvoiceService->query($Context, $realm, "SELECT *, Line.* FROM Invoice WHERE Id = '" .QuickBooks_IPP_IDS::usableIDType($main_invoice['qb_invoice_id']). "'");
$this_invoice = array();
var_dump($invoice_query);
if (count($invoice_query)){
foreach ($invoice_query as $Invoice){
//do stuff with invoice here
}
}
}
私はそれが私が訪れたときに
そして、もし(()$コンテキスト= $ IPP->コンテキスト)を介して取得するにもかかわらずのvar_dump($のinvoice_query)からブール値(false)を取得しています"docs/example_app_ipp_v3 /"ページは、現在の認証情報に更新された設定だけが表示され、「Quickbooksに接続」ボタン(下記HTML)は404ページに移動します。
<ipp:connecttointuit><a href="javascript:void(0)" class="intuitPlatformConnectButton">Connect with QuickBooks</a></ipp:connecttointuit>
あなたはコードを投稿していないので、お手伝いできません。あなたのコードを投稿してください。 –
@KeithPalmerJr。申し訳ありません、更新されました。 – cellen