| | |
| | | couponId: '', |
| | | isbutton: false |
| | | }) |
| | | var jsonData = res.data.data; |
| | | var jsonData = JSON.parse(res.data.data.data.res); |
| | | |
| | | let url = res.data.data |
| | | wx.navigateTo({ |
| | | url: '/invoicePackage/pages/webview/webview?src=' + encodeURIComponent(url) |
| | | }) |
| | | // wx.requestPayment({ |
| | | // "timeStamp": jsonData.timeStamp, |
| | | // "nonceStr": jsonData.nonceStr, |
| | | // "package": jsonData.package, |
| | | // "signType": jsonData.signType, |
| | | // "paySign": jsonData.sign, |
| | | // "success": (res) => { |
| | | // let that = this |
| | | // that.setData({ |
| | | // showPayVan: false, |
| | | // couponId: '', |
| | | |
| | | // payEnd: true, |
| | | // isbutton: false |
| | | // }) |
| | | // app.showToastSuccess("支付成功", null, "success", 1500) |
| | | |
| | | // // 弹出优惠券 领弹框 |
| | | // this.getGiveAwayMerchantCoupon(); |
| | | |
| | | // this.setData({ |
| | | // money: this.data.calcMoney |
| | | // }) |
| | | // wx.setNavigationBarTitle({ |
| | | // title: "行程结束", //页面标题为路由参数 |
| | | // }); |
| | | // }, |
| | | // "fail": (res) => { |
| | | // console.log(res) |
| | | // this.setData({ |
| | | // isbutton: false |
| | | // }) |
| | | // } |
| | | // let url = res.data.data |
| | | // wx.navigateTo({ |
| | | // url: '/invoicePackage/pages/webview/webview?src=' + encodeURIComponent(url) |
| | | // }) |
| | | console.log(jsonData) |
| | | wx.requestPayment({ |
| | | "timeStamp": jsonData.timestamp, |
| | | "nonceStr": jsonData.nonceStr, |
| | | "package": jsonData.packageStr, |
| | | "signType": jsonData.signType, |
| | | "paySign": jsonData.sign, |
| | | "success": (res) => { |
| | | let that = this |
| | | that.setData({ |
| | | showPayVan: false, |
| | | couponId: '', |
| | | |
| | | payEnd: true, |
| | | isbutton: false |
| | | }) |
| | | app.showToastSuccess("支付成功", null, "success", 1500) |
| | | |
| | | // 弹出优惠券 领弹框 |
| | | this.getGiveAwayMerchantCoupon(); |
| | | |
| | | this.setData({ |
| | | money: this.data.calcMoney |
| | | }) |
| | | wx.setNavigationBarTitle({ |
| | | title: "行程结束", //页面标题为路由参数 |
| | | }); |
| | | }, |
| | | "fail": (res) => { |
| | | console.log(res) |
| | | this.setData({ |
| | | isbutton: false |
| | | }) |
| | | } |
| | | }) |
| | | } else { |
| | | app.showToastSuccess('支付失败', null, "none", 1500) |
| | | } |
| | |
| | | Authorization: "Bearer" + " " + wx.getStorageSync('token'), |
| | | }, |
| | | method: "POST", |
| | | success: (res) => { |
| | | success: (res) => {invoicePackage/pages/webview/webview |
| | | console.log(res) |
| | | if (res.data.code == 200) { |
| | | this.setData({ |