index.vue
3.48 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
<template>
<div class="container">
<GLCombiForm :formObj="searchForm" :rowNumber="1" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<div class="table-header">
<div class="header-text">已激活列表</div>
<div>
<el-button class="table-btn" @click="handleSync" :size="size" type="primary" plain mode="el-button">企微接入授权</el-button>
</div>
</div>
<GLTable ref="activeTable" :noDataImg="url" :getListApi="getListApi" :searchForm="searchForm" :tableParams="tableParams" :pageConf="pageConf" @setTableFinishFun="setTableFinishFun"></GLTable>
</div>
</template>
<script>
import url from '@/assets/empty.png'
export default {
name: 'collocation',
data() {
return {
url,
searchForm: {
belongWechat: '',
staffName: '',
telphone: '',
status: ''
},
searchFormData: [
{
label: '所属企微',
name: 'belongWechat',
type: 'input',
isClear: true
},
{
label: '员工姓名',
name: 'staffName',
type: 'input',
isClear: true
},
{
label: '手机号码',
name: 'telphone',
type: 'input',
isClear: true
},
{
label: '状态',
name: 'status',
type: 'select',
optionList: [
{
label: '全部',
value: ''
},
{
label: '是',
value: 1
},
{
label: '否',
value: 0
}
],
optionId: 'value',
optionLabel: 'label',
isClear: true
}
],
tableParams: {
listName: 'list',
tableColumns: [
{
label: '员工姓名',
prop: 'staffName'
},
{
label: '员工企微号',
prop: 'staffNum'
},
{
label: '手机号码',
prop: 'telphone'
},
{
label: '所属门店',
prop: 'belongStore'
},
{
label: '所属企微',
prop: 'belongWechat'
},
{
label: '最后同步时间',
prop: 'time'
},
{
label: '状态',
prop: 'status'
}
]
},
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'total' }
// getListApi: this.$apis.accountConfig.listCustomizedAgentWithPage,
}
},
methods: {
handleSearch() {
this.$refs.activeTable.refreshTable()
},
// 重置搜索框搜索
handleReset() {
this.searchForm = {
isBuyPermit: '',
merchantId: '',
merchantName: ''
}
this.handleSearch()
},
setTableFinishFun() {
//接收到的数据为空
this.$refs.activeTable.data.length ? (this.$refs.activeTable.tableHeightValues = '') : this.$refs.activeTable.setTableHeightFun()
}
}
}
</script>
<style lang="scss" scoped>
.container {
padding: 20px;
background-color: #fff;
.table-header {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 10px;
.header-text {
font-size: 16px;
color: #333333;
font-weight: 600;
}
}
.table-btn {
color: #5850ff;
border: 1px solid #5850ff;
}
}
</style>