index.vue
2.88 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
<template>
<div class="container">
<h3>客户分群</h3>
<search-form class="searchTop border-shadow" :formModel="searchForm" :formList="clientPartFormList">
<span class="inline-b" slot="form-slot">
<!-- :id="tableParams.btnId" -->
<el-button type="primary" :size="btn_size" icon="el-icon-search" :id="tableParams.btnId" ref="searchButton">查询</el-button>
</span>
</search-form>
<basic-table ref="clientMassTable" :tableParams="tableParams" :getListApi="getListApi" :searchForm="searchForm" :hasNum="true">
<span slot="table-button" slot-scope="scope">
<el-button v-for="(j, idx) in tableParams.tableOption.btnList" :key="idx" :type="j.type || 'text'" :size="btn_size" @click="btnClick(j.pType, scope.scope)">{{ j.name }}</el-button>
</span>
</basic-table>
</div>
</template>
<script>
export default {
name: 'clientPartGroup',
data() {
return {
searchForm: {},
clientPartFormList: [
{
type: 'daterange',
prop: 'daterange',
pickerOptions: {
disabledDate(time) {
return time.getTime() > Date.now() || time.getTime() < new Date('2017-12-31').getTime()
}
}
},
{
type: 'select',
prop: 'status',
placeholder: '请选择更新机制',
options: [
{
label: '全部',
value: null
},
{
label: '自动(每天更新)',
value: 1
},
{
label: '手动(每天更新)',
value: 1
}
]
},
{
type: 'input',
inputType: 'text',
prop: 'name3',
placeholder: '请输入客户分群名称'
}
],
tableParams: {
btnId: new Date().getTime() + parseInt(Math.random() * 1000),
listName: 'list',
tableColumns: [
{
label: '客户分群名称',
prop: 'clientGroupName'
},
{
label: '客户数',
prop: 'gender'
},
{
label: '更新机制',
prop: 'createdDate'
},
{
label: '创建人',
prop: 'source'
},
{
label: '更新时间',
prop: 'isAddWeChat'
}
],
tableOption: {
width: 170,
btnList: [
// {
// name: "编辑",
// pType: "edit",
// },
// {
// name: "删除",
// pType: "delete",
// },
{
name: '人群圈像',
pType: 'detail'
}
]
}
},
getListApi: ''
}
},
methods: {
name() {}
}
}
</script>
<style lang="scss" scoped>
</style>