|
|
@@ -1,7 +1,7 @@ |
|
|
|
<!-- |
|
|
|
* @Date: 2022-03-29 16:57:58 |
|
|
|
* @LastEditors: JinxChen |
|
|
|
* @LastEditTime: 2023-02-27 18:25:19 |
|
|
|
* @LastEditTime: 2023-02-28 14:58:08 |
|
|
|
* @FilePath: \TelpoH5FrontendWeb\src\views\package-list\index.vue |
|
|
|
* @description: TODO 小台风充值h5 |
|
|
|
--> |
|
|
@@ -125,7 +125,7 @@ |
|
|
|
</template> |
|
|
|
</van-radio> |
|
|
|
</van-radio-group> --> |
|
|
|
<van-radio-group v-model="radio" @change="onRaidoChange"> |
|
|
|
<!-- <van-radio-group v-model="radio" @change="onRaidoChange"> |
|
|
|
<van-cell-group border > |
|
|
|
<van-cell clickable @click="radio = '1'" center> |
|
|
|
<template #default> |
|
|
@@ -161,8 +161,9 @@ |
|
|
|
</template> |
|
|
|
</van-cell> |
|
|
|
</van-cell-group> |
|
|
|
</van-radio-group> |
|
|
|
</van-radio-group> --> |
|
|
|
</div> |
|
|
|
|
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</template> |
|
|
@@ -174,6 +175,7 @@ let wx = require("weixin-js-sdk"); // TODO 再封装,可拦截错误提示等 |
|
|
|
import APICore from "@/api/core"; |
|
|
|
import axios from "axios"; |
|
|
|
import { isNotNull } from "@/utils/index"; |
|
|
|
import AppId from "@/config/appId"; |
|
|
|
export default { |
|
|
|
name: "packageList", |
|
|
|
data() { |
|
|
@@ -328,7 +330,7 @@ export default { |
|
|
|
APIWx.createJSSDK({ |
|
|
|
sUrl: window.location.href.split("#")[0], |
|
|
|
userId: '', |
|
|
|
appId: this.params.appId |
|
|
|
appId: this.params.appId || AppId |
|
|
|
}) |
|
|
|
.then(res => { |
|
|
|
let item = res.data.data; |
|
|
@@ -359,7 +361,7 @@ export default { |
|
|
|
// 需要区分是要用微信支付还是支付宝花呗支付 |
|
|
|
if (this.payType === '2') { |
|
|
|
this.payProductId = process.env.NODE_ENV === "production" ? '1629407413618294784' : '1629405716684029952', //支付宝全额支付 |
|
|
|
this.packageIssue = 1; |
|
|
|
this.packageIssue = 0; |
|
|
|
this.aliPay(data); |
|
|
|
} else if (this.payType === '3') { |
|
|
|
this.payProductId = process.env.NODE_ENV === "production" ? '1629407705558630400': '1629405558344859648', //支付宝花呗支付 |
|
|
@@ -370,17 +372,17 @@ export default { |
|
|
|
let openId = this.$store.getters.openId; |
|
|
|
if(openId === null || openId === 'null') { |
|
|
|
this.$dialog.confirm({ |
|
|
|
message: '微信支付在调整中,请选择其它支付方式', |
|
|
|
message: '获取OpenId失败,请您重新进入', |
|
|
|
showCancelButton: false, |
|
|
|
}) |
|
|
|
} else { |
|
|
|
this.packageIssue = 1; |
|
|
|
/* this.packageIssue = 1; |
|
|
|
this.$dialog.confirm({ |
|
|
|
message: '微信支付在调整中,请选择其它支付方式', |
|
|
|
showCancelButton: false, |
|
|
|
}) |
|
|
|
}) */ |
|
|
|
// todo 暂时取消开放微信支付 |
|
|
|
//this.wxPay(data); |
|
|
|
this.wxPay(data); |
|
|
|
console.log("openid为空"); |
|
|
|
} |
|
|
|
} |
|
|
@@ -526,6 +528,10 @@ export default { |
|
|
|
}) |
|
|
|
.catch(error => { |
|
|
|
console.log("error", error); |
|
|
|
this.$dialog.confirm({ |
|
|
|
message: `${error.message}`, |
|
|
|
showCancelButton: false |
|
|
|
}) |
|
|
|
}) |
|
|
|
.finally(() => { |
|
|
|
this.$toast.clear(); |
|
|
@@ -561,14 +567,14 @@ export default { |
|
|
|
height: 100vh; |
|
|
|
.topup-container { |
|
|
|
position: relative; |
|
|
|
margin: 20px; |
|
|
|
/* margin: 20px; */ |
|
|
|
display: flex; |
|
|
|
justify-content: space-between; |
|
|
|
align-items: center; |
|
|
|
flex-direction: column; |
|
|
|
background-color: white; |
|
|
|
overflow: scroll; |
|
|
|
/* height: calc(100vh - 4rem); */ |
|
|
|
height: calc(100vh - 88px); |
|
|
|
.main { |
|
|
|
display: flex; |
|
|
|
justify-content: center; |
|
|
@@ -609,10 +615,8 @@ export default { |
|
|
|
} |
|
|
|
.package-order-container { |
|
|
|
position: relative; |
|
|
|
/* height: 140px; */ |
|
|
|
width: 300px; |
|
|
|
margin: 10px 0; |
|
|
|
padding: 0 10px; |
|
|
|
padding: 0 20px; |
|
|
|
z-index: 999; |
|
|
|
box-shadow: rgba(14, 30, 37, 0.12) 0 3px 5px 0, |
|
|
|
rgba(14, 30, 37, 0.32) 0 2px 16px 0; |
|
|
@@ -683,19 +687,20 @@ export default { |
|
|
|
.price { |
|
|
|
font-size: 16px; |
|
|
|
} |
|
|
|
.buy-btn { |
|
|
|
/* .buy-btn { |
|
|
|
height: 30px; |
|
|
|
width: 90px; |
|
|
|
width: 100px; |
|
|
|
display: flex; |
|
|
|
justify-content: center; |
|
|
|
align-items: center; |
|
|
|
background: orange; |
|
|
|
border-radius: 20px; |
|
|
|
border-radius: 45px; |
|
|
|
p { |
|
|
|
font-size: 16px; |
|
|
|
padding: 0; |
|
|
|
color: white; |
|
|
|
color: red; |
|
|
|
} |
|
|
|
} |
|
|
|
} */ |
|
|
|
} |
|
|
|
.remark { |
|
|
|
display: flex; |
|
|
@@ -715,8 +720,9 @@ export default { |
|
|
|
justify-content: center; |
|
|
|
align-items: center; |
|
|
|
background: orange; |
|
|
|
border-radius: 30px; |
|
|
|
border-radius: 20px; |
|
|
|
p { |
|
|
|
font-size: 16px; |
|
|
|
padding: 0; |
|
|
|
color: white; |
|
|
|
} |
|
|
@@ -775,7 +781,7 @@ export default { |
|
|
|
justify-content: flex-start; |
|
|
|
align-items: flex-start; |
|
|
|
flex-direction: column; |
|
|
|
padding: 5px 0 10px 25px; |
|
|
|
padding: 5px 0 10px 10px; |
|
|
|
h5 { |
|
|
|
font-size: 14px; |
|
|
|
padding: 10px 0 0 0; |
|
|
|