1

我似乎无法显示测试对话框。当我打电话payments.purchaseAync时,我总是看到一个真正的 Checkout 对话框,而不是一个测试对话框。

在此处输入图像描述

我已经将测试用户添加到测试人员。我错过了什么吗?还是目前还不支持此功能?

在此处输入图像描述

我正在使用的临时代码:

let supportedAPIs:any = FBInstant.getSupportedAPIs();
if(supportedAPIs.includes('payments.purchaseAsync'))
{
    console.log('payments supported...');

    FBInstant.payments.onReady(() => {
        console.log('payments ready...');

        FBInstant.payments.purchaseAsync({
            productID: 'test_product',
            developerPayload: 'foobar',
        }).then(function (purchase) {
            console.log(purchase);
        });
    });
}
else
{
    console.log('payments not supported...');
}
4

0 回答 0