index.vue
3.01 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
<template>
<div class="container">
<div>
<el-button @click="addSendGroup" :size="size" type="primary" mode="el-button">新建群发</el-button>
</div>
<GLCombiForm :formObj="searchForm" :rowNumber="1" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<GLTable ref="groupTable" :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: {
sendName: '',
sendTime: '',
store: ''
},
searchFormData: [
{
label: '群发名称',
name: 'sendName',
type: 'input',
isClear: true
},
{
label: '群发时间',
name: 'sendTime',
type: 'datePicker',
isClear: true
},
{
label: '群发门店',
name: 'store',
type: 'input',
isClear: true
}
],
tableParams: {
listName: 'list',
tableColumns: [
{
label: '群发名称',
prop: 'sendName'
},
{
label: '群发门店',
prop: 'senaStore'
},
{
label: '客户数',
prop: 'customerNum'
},
{
label: '标签/人群',
prop: 'tag'
},
{
label: '创建时间',
prop: 'creatTime'
},
{
label: '发送状态',
prop: 'sendStatus'
},
{
label: '完成情况(失败/成功)',
prop: 'finish',
width: '200'
}
]
},
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()
},
// 跳转新建群发
addSendGroup() {
this.$router.push('/wechatGroup/addWechatGroup')
}
}
}
</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>