Commit 1636222e by 前端

Merge branch 'xuyl_dev_v2.8.0' into 'v2.8.0'

更新最新代码到2.8

See merge request !143
2 parents 66b3833c 10623846
......@@ -137,6 +137,7 @@ export default {
handleExport() {
const params = {
...JSON.parse(JSON.stringify({ tagLists: this.allListParams })),
...this.searchForm,
combineType: 2
}
exportLabelList(params).then(res => {
......@@ -146,8 +147,8 @@ export default {
//客户列表
getCustomersListData() {
if (this.searchForm.createTime) {
this.searchForm.beginTime = new Date(this.searchForm.createTime[0]).toLocaleDateString().replace(/-/g, '/')
this.searchForm.endTime = new Date(this.searchForm.createTime[1]).toLocaleDateString().replace(/-/g, '/')
this.searchForm.beginCarBuyDate = new Date(this.searchForm.createTime[0]).toLocaleDateString().replace(/-/g, '/')
this.searchForm.endCarBuyDate = new Date(this.searchForm.createTime[1]).toLocaleDateString().replace(/-/g, '/')
}
delete this.searchForm.createTime
const tagLists = this.$common.utils.deepClone(this.allListParams)
......
......@@ -13,7 +13,7 @@
<div class="back color-58 font-14" @click="goBack">返回人群管理</div>
</div>
<div class="main-container">
<GLCombiForm ref="formSearch" :formObj="tableSearchForm" :formData="tagsPartFormList" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<GLCombiForm ref="formSearch" :formObj="searchForm" :formData="tagsPartFormList" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<div class="main-container-head flex-between">
<div class="main-container-head-title color-3 font-20">
全部客户
......@@ -21,9 +21,7 @@
</div>
<div>
<el-button size="small" @click="handleExport" class="export">导出</el-button>
<el-button plain size="small" @click="createMarketSOP()">
营销SOP
</el-button>
<el-button plain size="small" @click="createMarketSOP()">营销SOP</el-button>
</div>
</div>
<GLTable ref="groupRef" :getListApi="getListApi" :searchForm="tableSearchForm" :tableParams="tableParams" :noDataImg="url" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun">
......@@ -72,15 +70,16 @@ export default {
corwdId: '', //传到营销SOP的crowId
getListApi: this.$route.params.crowdType == '1' || this.$route.params.crowdType == '2' ? getcrowdManageList : getCustomerList,
pageConf: { pageSize: 'pageSize', pageNum: 'pageNum', totalCount: 'count' },
tableSearchForm: {
customerPhone: '',
nickName: '',
customerName: '',
followStaff: '',
audi: '',
carNumber: '',
isJoin: ''
searchForm: {
// customerPhone: '',
// nickName: '',
// customerName: '',
// followStaff: '',
// audi: '',
// carNumber: '',
// isJoin: ''
},
tableSearchForm: {},
tagsPartFormList: [
{
type: 'select',
......@@ -273,12 +272,13 @@ export default {
})
},
getParams() {
var params = JSON.parse(JSON.stringify(this.tableSearchForm))
var params = JSON.parse(JSON.stringify(this.searchForm))
if (this.crowdType == 1 || this.crowdType == 2) params.customCrowd = true
if (params.daterange) {
params.beginTime = this.tableSearchForm.daterange[0]
params.endTime = this.tableSearchForm.daterange[1]
params.beginCarBuyDate = params.daterange[0]
params.endCarBuyDate = params.daterange[1]
} else {
if (params.beginTime) delete params.beginTime && delete params.endTime
if (params.beginCarBuyDate) delete params.beginCarBuyDate && delete params.endCarBuyDate
}
delete params.daterange
return params
......@@ -346,13 +346,13 @@ export default {
this.$refs.groupRef.refreshTable()
},
handleReset() {
this.tableSearchForm = {
this.searchForm = {
crowdId: this.id
}
this.$refs.groupRef.refreshTable()
},
init(id) {
this.tableSearchForm = {
this.searchForm = {
crowdId: id
}
// 通过人群Id查询人群详情
......@@ -377,12 +377,9 @@ export default {
},
//导出
handleExport() {
var params = {
crowdId: this.id,
pageSize: 10,
pageNum: 1
}
if (this.crowdType == 1 || this.crowdType == 2) params.customCrowd = true
var params = this.getParams()
params.pageSize = 10
params.pageNum = 1
customerClusterListExport(params).then(res => {
this.$Utils.exportFn(res)
})
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!