初始化
parent
f4bbf03b3d
commit
47aad76274
|
@ -4,7 +4,7 @@ import request from '@/utils/request'
|
||||||
export function pay(query) {
|
export function pay(query) {
|
||||||
return request({
|
return request({
|
||||||
url: '/pay/alipay/pay',
|
url: '/pay/alipay/pay',
|
||||||
method: 'post',
|
method: 'get',
|
||||||
params: query
|
params: query
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
|
@ -59,7 +59,7 @@
|
||||||
<el-col :span="8" v-for="customer in apitypeList" v-if="apitypeList.length != 0&&activeNameL=='全部类型'||customer.sysLeixingpick==activeNameL">
|
<el-col :span="8" v-for="customer in apitypeList" v-if="apitypeList.length != 0&&activeNameL=='全部类型'||customer.sysLeixingpick==activeNameL">
|
||||||
<el-card class="box-card">
|
<el-card class="box-card">
|
||||||
<div slot="header" class="clearfix">
|
<div slot="header" class="clearfix">
|
||||||
<el-image :src="customer.sysTypes" @click="goToPaySuccess(customer)">
|
<el-image :src="customer.sysTypes" @click="gotoMaintained(customer)">
|
||||||
<div slot="placeholder" class="image-slot">
|
<div slot="placeholder" class="image-slot">
|
||||||
加载中<span class="dot">...</span>
|
加载中<span class="dot">...</span>
|
||||||
</div>
|
</div>
|
||||||
|
@ -145,18 +145,22 @@ export default {
|
||||||
// 表单校验
|
// 表单校验
|
||||||
rules: {
|
rules: {
|
||||||
},
|
},
|
||||||
|
pay:{
|
||||||
|
|
||||||
|
},
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getList();
|
this.getList();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
gotoMaintained(customer){
|
||||||
async goToPaySuccess(customer){
|
this.pay.subject=customer.sysIntro
|
||||||
//在这里我选择了window.open(url,'_self')形式,也就是不跳转新的页面,在本页面直接跳转
|
this.pay.traceNo=Math.floor(Math.random() * 900000) + 100000
|
||||||
window.open("http://10.0.2.1:80/alipay/pay?subject="+customer.sysIntro+"&traceNo="+Math.floor(Math.random() * 900000) + 100000+"&totalAmount="+customer.sysNumber,'_self')
|
this.pay.totalAmount=customer.sysNumber
|
||||||
|
const url = `http://47.116.173.119:80/alipay/pay?subject=${this.pay.subject}&traceNo=${this.pay.traceNo}&totalAmount=${this.pay.totalAmount}`;
|
||||||
|
window.open(url, '_self'); // 如果您想在当前页面加载新 URL,这样是正确的
|
||||||
},
|
},
|
||||||
|
|
||||||
getType(activeNameL){
|
getType(activeNameL){
|
||||||
this.activeNameL=activeNameL
|
this.activeNameL=activeNameL
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue