交易市场新增微信支付

This commit is contained in:
唐明明
2021-11-04 16:49:09 +08:00
parent f8aed4d12c
commit 5f7c8c36ca
4 changed files with 13 additions and 11 deletions

View File

@@ -10,8 +10,8 @@ import router from '../router'
// 基础配置
const config = {
apiUrl : 'https://oapi.lianshang.vip/api/', // 正式环境
// apiUrl : 'http://api.ahxh.shangkelian.cn/api/', // 测试环境
// apiUrl : 'https://oapi.lianshang.vip/api/', // 正式环境
apiUrl : 'http://api.ahxh.shangkelian.cn/api/', // 测试环境
apiUrls : 'https://storage.lianshang.vip/', // 图片路径(测试/正式)
timeout : 60000
}

View File

@@ -83,6 +83,7 @@
<script>
import { marketsInfo, marketsBuy, marketsPay } from '@/apis/interfaces/market'
import userAuth from '@/public/userAuth'
import cashierPay from '@/public/cashierPay'
export default {
data() {
return {
@@ -149,12 +150,11 @@
marketsPay(this.orderNo, this.payValue).then(res => {
switch (this.payValue){
case 'wechat':
let payConfigObj = JSON.parse(res)
cashierPay.pay('wxpay', payConfigObj, 'market')
break
case 'alipay':
cashierPay.pay('alipay', res, 'market').then(payRes => {
console.log(payRes)
})
cashierPay.pay('alipay', res, 'market')
break
}
}).catch(err => {

View File

@@ -266,7 +266,9 @@
let identity = this.identitie[this.tabsIndex].identity_id
vipOrder(identity, {
year: 1,
}).then(res => {
}).then(res => {
if (payType === 0) this.wechatAppPay(res.id)
if (payType === 1) this.aliPayConfig(res.id)
}).catch(err => {
@@ -277,7 +279,7 @@
})
},
// 支付宝支付
// 支付
aliPayConfig(orderId) {
getAliPayConfig(orderId, {
type: 'app'

File diff suppressed because one or more lines are too long