【发布时间】:2017-05-10 15:56:46
【问题描述】:
我正在尝试使用 RazorPay 支付网关完成我的支付交易,我尝试如下:
var options = {
"key": "XXX",
"amount": 100, // 2000 paise = INR 20
"name": "Ezshipp",
"description": this.itemName,
"image": "../images/logo-blue-1.png",
"handler": function (response) {
this.paymentId = response.razorpay_payment_id;
console.log("payment id "+this.paymentId);
this.orderanything(this.paymentId);
},
"prefill": {
"name": this.UserName
},
"notes": {
"address": this.pickAddress
},
"theme": {
"color": "#12a6f1"
}
};
当我试图在处理程序响应中调用另一个方法时,我收到如下错误:
this.orderanything 不是函数
但我在我的组件中声明了 orderanything(paymentId) 函数。
【问题讨论】:
标签: angular typescript