我刚刚设法为Phonegap(Iphone - https://github.com/phonegap/phonegap-plugins/tree/master/iPhone/PayPalPlugin)设置了Paypal插件,它适用于个人支付。
但是有谁知道这种方法是否可以用来触发定期付款?
这是当前的触发代码 -
function onDeviceReady()
{
try {
// do your thing!
document.addEventListener(PayPal.PaymentEvent.Success, onPaymentSuccess,false);
document.addEventListener(PayPal.PaymentEvent.Canceled, onPaymentCanceled,false);
document.addEventListener(PayPal.PaymentEvent.Failed, onPaymentFailed,false);
window.plugins.paypal.prepare(PayPal.PaymentType.DONATION);
window.plugins.paypal.setPaymentInfo({
paymentCurrency : "USD",
paymentAmount : "00.10",
itemDesc : "network cable",
recipient : "pabs_1355160222_biz@liquidsolution.co.uk",
merchantName : "test Account"
});
} catch (e) {
debug.error(e);
}
}