|
|
|
@ -18,8 +18,7 @@
|
|
|
|
:columns="columns1"
|
|
|
|
:columns="columns1"
|
|
|
|
:data="data1"
|
|
|
|
:data="data1"
|
|
|
|
style="margin-top: 20px;"
|
|
|
|
style="margin-top: 20px;"
|
|
|
|
size="small"
|
|
|
|
size="small">
|
|
|
|
>
|
|
|
|
|
|
|
|
<template slot-scope="{ row }" slot="qrCodeAction">
|
|
|
|
<template slot-scope="{ row }" slot="qrCodeAction">
|
|
|
|
<img
|
|
|
|
<img
|
|
|
|
:src="require('../../../static/img/qrCode-init.png')"
|
|
|
|
:src="require('../../../static/img/qrCode-init.png')"
|
|
|
|
@ -27,16 +26,16 @@
|
|
|
|
style="margin-left: 5px;margin-top: 5px;width:30px;height:30px;"
|
|
|
|
style="margin-left: 5px;margin-top: 5px;width:30px;height:30px;"
|
|
|
|
/>
|
|
|
|
/>
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
<template slot-scope="{ row, index }" slot="state">
|
|
|
|
<!-- <template slot-scope="{ row, index }" slot="accountFlag">-->
|
|
|
|
<i-switch
|
|
|
|
<!-- <i-switch-->
|
|
|
|
size="large"
|
|
|
|
<!-- size="large"-->
|
|
|
|
:value="row.qrCodeState"
|
|
|
|
<!-- :value="row.accountFlag"-->
|
|
|
|
@on-change="onSwitchChangeLister(row, index)"
|
|
|
|
<!-- @on-change="onSwitchChangeLister"-->
|
|
|
|
>
|
|
|
|
<!-- >-->
|
|
|
|
<span slot="open">开启</span>
|
|
|
|
<!-- <span slot="open">开启</span>-->
|
|
|
|
<span slot="close">关闭</span>
|
|
|
|
<!-- <span slot="close">关闭</span>-->
|
|
|
|
</i-switch>
|
|
|
|
<!-- </i-switch>-->
|
|
|
|
</template>
|
|
|
|
<!-- </template>-->
|
|
|
|
|
|
|
|
|
|
|
|
<template slot-scope="{ row }" slot="action">
|
|
|
|
<template slot-scope="{ row }" slot="action">
|
|
|
|
<Button
|
|
|
|
<Button
|
|
|
|
@ -44,17 +43,15 @@
|
|
|
|
type="primary"
|
|
|
|
type="primary"
|
|
|
|
size="small"
|
|
|
|
size="small"
|
|
|
|
style="border: 0px;color:#2074E2"
|
|
|
|
style="border: 0px;color:#2074E2"
|
|
|
|
@click="open(2, row)"
|
|
|
|
@click="open(2, row)">修改
|
|
|
|
>修改
|
|
|
|
|
|
|
|
</Button>
|
|
|
|
</Button>
|
|
|
|
<Button
|
|
|
|
<Button
|
|
|
|
ghost
|
|
|
|
ghost
|
|
|
|
type="error"
|
|
|
|
type="error"
|
|
|
|
size="small"
|
|
|
|
size="small"
|
|
|
|
style="border: 0px"
|
|
|
|
style="border: 0px"
|
|
|
|
@click="remove(row)"
|
|
|
|
@click="remove(row)">删除
|
|
|
|
>删除</Button
|
|
|
|
</Button>
|
|
|
|
>
|
|
|
|
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</Table>
|
|
|
|
</Table>
|
|
|
|
|
|
|
|
|
|
|
|
@ -63,8 +60,7 @@
|
|
|
|
v-model="isShow"
|
|
|
|
v-model="isShow"
|
|
|
|
:footer-hide="true"
|
|
|
|
:footer-hide="true"
|
|
|
|
width="230"
|
|
|
|
width="230"
|
|
|
|
class-name="vertical-center-modal"
|
|
|
|
class-name="vertical-center-modal">
|
|
|
|
>
|
|
|
|
|
|
|
|
<div slot="header">
|
|
|
|
<div slot="header">
|
|
|
|
<p></p>
|
|
|
|
<p></p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
@ -130,18 +126,21 @@
|
|
|
|
</CheckboxGroup>
|
|
|
|
</CheckboxGroup>
|
|
|
|
</FormItem>
|
|
|
|
</FormItem>
|
|
|
|
<FormItem v-if="flag !== 1 && formValidate.role === 'DZ-DIANZHANG'" label="主店长" prop="type">
|
|
|
|
<FormItem v-if="flag !== 1 && formValidate.role === 'DZ-DIANZHANG'" label="主店长" prop="type">
|
|
|
|
<Checkbox :disabled="formValidate.type === 1 ? true : false" v-model="formValidate.type" :true-value="1" :false-value="2"></Checkbox>
|
|
|
|
<Checkbox :disabled="formValidate.type === 1 ? true : false" v-model="formValidate.type"
|
|
|
|
|
|
|
|
:true-value="1" :false-value="2"></Checkbox>
|
|
|
|
</FormItem>
|
|
|
|
</FormItem>
|
|
|
|
<FormItem style="text-align: left;">
|
|
|
|
<FormItem style="text-align: left;">
|
|
|
|
<Row>
|
|
|
|
<Row>
|
|
|
|
<i-col span="16">
|
|
|
|
<i-col span="16">
|
|
|
|
<Button type="primary" @click="handleSubmit(formValidate)"
|
|
|
|
<Button type="primary" @click="handleSubmit(formValidate)"
|
|
|
|
>保存</Button
|
|
|
|
>保存
|
|
|
|
|
|
|
|
</Button
|
|
|
|
>
|
|
|
|
>
|
|
|
|
<Button
|
|
|
|
<Button
|
|
|
|
@click="handleReset('formValidate')"
|
|
|
|
@click="handleReset('formValidate')"
|
|
|
|
style="margin-left: 8px"
|
|
|
|
style="margin-left: 8px"
|
|
|
|
>取消</Button
|
|
|
|
>取消
|
|
|
|
|
|
|
|
</Button
|
|
|
|
>
|
|
|
|
>
|
|
|
|
</i-col>
|
|
|
|
</i-col>
|
|
|
|
</Row>
|
|
|
|
</Row>
|
|
|
|
@ -167,7 +166,8 @@
|
|
|
|
type="error"
|
|
|
|
type="error"
|
|
|
|
style="width: 100px;margin-left: 20px"
|
|
|
|
style="width: 100px;margin-left: 20px"
|
|
|
|
@click="deleteStaff"
|
|
|
|
@click="deleteStaff"
|
|
|
|
>确认删除</Button
|
|
|
|
>确认删除
|
|
|
|
|
|
|
|
</Button
|
|
|
|
>
|
|
|
|
>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</Modal>
|
|
|
|
</Modal>
|
|
|
|
@ -188,7 +188,7 @@
|
|
|
|
<script>
|
|
|
|
<script>
|
|
|
|
import data from "../../utils/PhoneRegionData";
|
|
|
|
import data from "../../utils/PhoneRegionData";
|
|
|
|
import http from "../../services/store/IncreaseStoreManager";
|
|
|
|
import http from "../../services/store/IncreaseStoreManager";
|
|
|
|
|
|
|
|
import accountManagementService from '../../services/account/AccountManagement';
|
|
|
|
import staff from "../../services/staff/staff";
|
|
|
|
import staff from "../../services/staff/staff";
|
|
|
|
|
|
|
|
|
|
|
|
export default {
|
|
|
|
export default {
|
|
|
|
@ -257,7 +257,30 @@ import staff from "../../services/staff/staff";
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
{
|
|
|
|
title: '停用/启用',
|
|
|
|
title: '停用/启用',
|
|
|
|
slot: 'status',
|
|
|
|
key: 'accountFlag',
|
|
|
|
|
|
|
|
render: (h, params) => {
|
|
|
|
|
|
|
|
let _this = this;
|
|
|
|
|
|
|
|
return h('div', [
|
|
|
|
|
|
|
|
h('i-switch', {
|
|
|
|
|
|
|
|
props: {
|
|
|
|
|
|
|
|
value: params.row.accountFlag,
|
|
|
|
|
|
|
|
'true-value': true,//开启值
|
|
|
|
|
|
|
|
'false-value': false,//关闭值
|
|
|
|
|
|
|
|
size: 'large'
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
on: { //操作事件
|
|
|
|
|
|
|
|
'on-change': function (value) {
|
|
|
|
|
|
|
|
//修改后请求方法
|
|
|
|
|
|
|
|
_this.modifyStatus(params.row.accountId, value);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
scopedSlots: {
|
|
|
|
|
|
|
|
open: () => h('span', '开启'),
|
|
|
|
|
|
|
|
close: () => h('span', '关闭')
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
])
|
|
|
|
|
|
|
|
}
|
|
|
|
},
|
|
|
|
},
|
|
|
|
{
|
|
|
|
{
|
|
|
|
title: '操作',
|
|
|
|
title: '操作',
|
|
|
|
@ -338,7 +361,12 @@ import staff from "../../services/staff/staff";
|
|
|
|
if (datas.records == null) {
|
|
|
|
if (datas.records == null) {
|
|
|
|
datas.records = [];
|
|
|
|
datas.records = [];
|
|
|
|
}
|
|
|
|
}
|
|
|
|
that.data1 = datas.records;
|
|
|
|
|
|
|
|
|
|
|
|
for (let i = 0; i < datas.records.length; i++) {
|
|
|
|
|
|
|
|
let item = datas.records[i];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
that.data1.push(item);
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}, function () {
|
|
|
|
}, function () {
|
|
|
|
that.loading = false;
|
|
|
|
that.loading = false;
|
|
|
|
@ -444,7 +472,8 @@ import staff from "../../services/staff/staff";
|
|
|
|
downRegionChange: function () {
|
|
|
|
downRegionChange: function () {
|
|
|
|
this.downShopData();
|
|
|
|
this.downShopData();
|
|
|
|
},
|
|
|
|
},
|
|
|
|
onChangeDateLister: function() {},
|
|
|
|
onChangeDateLister: function () {
|
|
|
|
|
|
|
|
},
|
|
|
|
// 预览二维码
|
|
|
|
// 预览二维码
|
|
|
|
show: function (index) {
|
|
|
|
show: function (index) {
|
|
|
|
this.isShow = true;
|
|
|
|
this.isShow = true;
|
|
|
|
@ -461,7 +490,8 @@ import staff from "../../services/staff/staff";
|
|
|
|
url: index.epWechatQrCode,
|
|
|
|
url: index.epWechatQrCode,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
name,
|
|
|
|
name,
|
|
|
|
function(/*data*/) {}
|
|
|
|
function (/*data*/) {
|
|
|
|
|
|
|
|
}
|
|
|
|
);
|
|
|
|
);
|
|
|
|
},
|
|
|
|
},
|
|
|
|
// 添加、修改推广人员
|
|
|
|
// 添加、修改推广人员
|
|
|
|
@ -519,7 +549,28 @@ import staff from "../../services/staff/staff";
|
|
|
|
});
|
|
|
|
});
|
|
|
|
},
|
|
|
|
},
|
|
|
|
// switch开关
|
|
|
|
// switch开关
|
|
|
|
onSwitchChangeLister: function() {},
|
|
|
|
modifyStatus(accountId, val) {
|
|
|
|
|
|
|
|
debugger
|
|
|
|
|
|
|
|
let that = this;
|
|
|
|
|
|
|
|
let status;
|
|
|
|
|
|
|
|
if (val) {
|
|
|
|
|
|
|
|
status = 1;
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
|
|
|
status = 2;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
let request = {
|
|
|
|
|
|
|
|
accountId: accountId,
|
|
|
|
|
|
|
|
status: status
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
accountManagementService.postAccountModifyStatus(request, function (res) {
|
|
|
|
|
|
|
|
let data = res.data;
|
|
|
|
|
|
|
|
if (data.code !== "0000") {
|
|
|
|
|
|
|
|
that.$Message.error("修改失败");
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}, function (res) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
},
|
|
|
|
handleSubmit(value) {
|
|
|
|
handleSubmit(value) {
|
|
|
|
if (value) {
|
|
|
|
if (value) {
|
|
|
|
let request = {};
|
|
|
|
let request = {};
|
|
|
|
|