Commit 51d1b989 51d1b9896bdacc0de054e89e7a46819fb58f71f0 by zhanghao

commit

1 parent 34286418
<template xmlns:el-col="http://www.w3.org/1999/html">
<div>
<br/>
<vue-qr :text="vueQrText" :size="180"></vue-qr>
<br/>
<br/>
</div>
</template>
<script>
import vueQr from 'vue-qr'
export default {
components: {
vueQr
},
data() {
return {
phone: this.$route.query.phone,
huanjing: this.$route.query.huanjing,
vueQrText: ''
}
},
mounted() {
this.activity()
},
methods: {
activity() {
const loading = this.$loading({
lock: true,
text: '加载中...',
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
let config = {
headers: {
'Content-Type': 'application/x-www-form-urlencoded'
}
}
this.$http.get('/tool/queryQRCode?'+this.$qs.stringify({
phone: this.phone,
type: this.huanjing
}),config).then((res)=>{
console.log(res.data)
this.vueQrText=res.data.qrcode
loading.close();
}).catch(error=>{
console.log(error);
loading.close();
this.$message({
showClose: true,
message: '服务器处理失败,请核对参数!',
type: 'error'
});
})
}
}
}
</script>
......@@ -826,6 +826,34 @@
</el-card>
</el-form>
</el-col>
<el-col :span="8">
<el-form ref="queryQRCode" :model="queryQRCode" label-width="0px">
<el-card class="darkred" shadow="always">
<div slot="header" class="clearfix">
<span>查询二维码</span>
</div>
<div class="text item">
<el-form-item>
<el-input placeholder="代理人手机号" v-model="queryQRCode.agentPhone" clearable></el-input>
</el-form-item>
<el-form-item>
<el-select v-model="queryQRCode.huanjing" placeholder="请选择执行环境">
<el-option
v-for="item in queryQRCodeOptions"
:key="item.value"
:label="item.label"
:value="item.value">
</el-option>
</el-select>
</el-form-item>
<div style="margin: 15px 0;"></div>
<el-form-item>
<el-button round @click="queryQRCodeSubmit">查询二维码</el-button>
</el-form-item>
</div>
</el-card>
</el-form>
</el-col>
</el-row>
</div>
</template>
......@@ -993,6 +1021,17 @@
value: '1',
label: '线上环境'
}],
queryQRCode: {
agentPhone: '',
huanjing: []
},
queryQRCodeOptions: [{
value: '0',
label: '测试环境'
}, {
value: '1',
label: '线上环境'
}],
queryPhoneCode: {
phone: '',
huanjing: []
......@@ -1689,6 +1728,11 @@
{phone: this.queryUserInfo.agentPhone, huanjing: this.queryUserInfo.huanjing.toString()}})
window.open(href, '_blank')
},
queryQRCodeSubmit() {
const {href} = this.$router.resolve({ name:'qrCode', query:
{phone: this.queryQRCode.agentPhone, huanjing: this.queryQRCode.huanjing.toString()}})
window.open(href, '_blank')
},
callLinuxCommandSubmit() {
const {href} = this.$router.resolve({ name:'callLinuxCommand', query:
{size: this.callLinuxCommand.size, huanjing: this.callLinuxCommand.huanjing.toString()}})
......
......@@ -28,7 +28,6 @@
min-width="1">
</el-table-column>
</el-table>
<vue-qr :text="vueQrText" :size="180"></vue-qr>
<br/>
<br/>
<span>激活此用户的代理人(tbl_agent_properties)</span>
......@@ -214,11 +213,7 @@
</template>
<script>
import vueQr from 'vue-qr'
export default {
components: {
vueQr
},
data() {
return {
phone: this.$route.query.phone,
......@@ -227,8 +222,7 @@
tblAgentProperties: [],
tblAgentCustomers: [],
tblAgentCustomersAll: [],
tblJiHuoAgentProperties: [],
vueQrText: 'Zn2YEd1Xq/qHH8B3j0KxsMSfsA55IsYY+lbrIdIZS62EHl45vYrVcfYejpjPwpEoFtO+yU66GxBGrU8lwJ3WmMzMzziUWIVeg75IYjzBIompmi/uFOHKxCTgC/rjtWW6/o4SFl0tWbU8M2RjLB1bYWJdf7PONFQeGOQ8gttIeTHPeOIROOWbLDcoPqzLWcnDaYkAM8g+fPvF9xMex32Rxg=='
tblJiHuoAgentProperties: []
}
},
mounted() {
......
......@@ -33,6 +33,7 @@ import selectActOnline from '@/page/selectActOnline'
import selectActOnlineShenZhen from '@/page/selectActOnlineShenZhen'
import toolWaiBao from '@/page/toolWaiBao'
import select20Act from '@/page/select20Act'
import qrCode from '@/page/qrCode'
Vue.use(Router)
......@@ -105,6 +106,14 @@ export default new Router({
}
},
{
path: '/qrCode',
component: qrCode,
name: 'qrCode',
meta: {
title: '测试工具平台'
}
},
{
path: '/callLinuxCommand',
component: callLinuxCommand,
name: 'callLinuxCommand',
......