应用内购买屏幕返回:
错误是:
发生意外的错误。请稍后再试。解雇
如您所见,其中一半也是黑色的。
Buy.js:
/*GOOGLE's CODE
...
*/
/*CODE FOR IN-APP PURCHASES*/
var prodButPrefix = "btnProdID-";
var statusDiv;
function init() {
console.log("App Init");
statusDiv = $("#status");
// getProductList();
}
$("#div1").click(function() {
checkIfBought("package2016");
});
/*****************************************************************************
* Get the list of purchased products from the Chrome Web Store
*****************************************************************************/
var purchased = false;
function getLicenses() {
console.log("google.payments.inapp.getPurchases");
console.log("Retreiving list of purchased products...");
google.payments.inapp.getPurchases({
'parameters': {env: "prod"},
'success': onLicenseUpdate,
'failure': onLicenseUpdateFailed
});
}
function checkIfBought(sku_init){
getLicenses();
function getLicenses() {
console.log("google.payments.inapp.getPurchases");
console.log("Retreiving …
Run Code Online (Sandbox Code Playgroud)