|
@@ -21,13 +21,46 @@
|
|
|
/>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
+ <el-form-item label="客户标签" prop="tags">
|
|
|
+ <el-select style="width:220px" multiple filterable v-model="tagIds" placeholder="请选择客户标签" clearable size="small">
|
|
|
+ <el-option
|
|
|
+ v-for="item in tagsOptions"
|
|
|
+ :key="item.dictLabel"
|
|
|
+ :label="item.dictLabel"
|
|
|
+ :value="item.dictLabel"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="客户类型" prop="customerType">
|
|
|
+ <el-select style="width:220px" multiple filterable v-model="ctsTypeArr" placeholder="请选择客户类型" clearable size="small">
|
|
|
+ <el-option
|
|
|
+ v-for="item in typeOptions"
|
|
|
+ :key="item.dictValue"
|
|
|
+ :label="item.dictLabel"
|
|
|
+ :value="item.dictValue"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+
|
|
|
+ <el-form-item label="领取时间" prop="receiveTime">
|
|
|
+ <el-date-picker
|
|
|
+ style="width:220px"
|
|
|
+ clearable size="small"
|
|
|
+ v-model="dateRange"
|
|
|
+ type="daterange"
|
|
|
+ value-format="yyyy-MM-dd"
|
|
|
+ start-placeholder="开始日期"
|
|
|
+ end-placeholder="结束日期">
|
|
|
+ </el-date-picker>
|
|
|
+ </el-form-item>
|
|
|
|
|
|
<el-form-item>
|
|
|
<el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
|
|
|
|
- <el-table border v-loading="loading" :data="customerList">
|
|
|
+ <el-table border v-loading="loading" :data="customerList" height="550px" ref="dataList">
|
|
|
+ <el-table-column type="selection" width="55" align="center"/>
|
|
|
<el-table-column label="客户编码" align="center" prop="customerCode" />
|
|
|
<el-table-column label="客户名称" align="center" prop="customerName" :show-overflow-tooltip="true">
|
|
|
<template slot-scope="scope">
|
|
@@ -74,7 +107,7 @@
|
|
|
<el-table-column label="进线客户提交日期" align="center" prop="registerSubmitTime" /> -->
|
|
|
<el-table-column label="创建时间" width="100" align="center" prop="customerCreateTime" >
|
|
|
</el-table-column>
|
|
|
- <el-table-column label="操作" align="center" width="100px" >
|
|
|
+ <!-- <el-table-column label="操作" align="center" width="100px" >
|
|
|
<template slot-scope="scope">
|
|
|
<el-button
|
|
|
size="mini"
|
|
@@ -82,7 +115,7 @@
|
|
|
@click="handleSelect(scope.row)"
|
|
|
>选择</el-button>
|
|
|
</template>
|
|
|
- </el-table-column>
|
|
|
+ </el-table-column> -->
|
|
|
</el-table>
|
|
|
<pagination
|
|
|
style="padding-bottom:10px;"
|
|
@@ -92,6 +125,9 @@
|
|
|
:limit.sync="queryParams.pageSize"
|
|
|
@pagination="getList"
|
|
|
/>
|
|
|
+ <div class="footer">
|
|
|
+ <el-button type="primary" @click="handleSelect($refs.dataList)">添加</el-button>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -115,6 +151,9 @@ export default {
|
|
|
sexOptions:[],
|
|
|
tagsOptions:[],
|
|
|
customerList: [],
|
|
|
+ tagIds:[],
|
|
|
+ ctsTypeArr:[],
|
|
|
+ dateRange:[],
|
|
|
};
|
|
|
},
|
|
|
created() {
|
|
@@ -137,8 +176,11 @@ export default {
|
|
|
},
|
|
|
|
|
|
methods: {
|
|
|
- handleSelect(row){
|
|
|
- this.$emit('selectCustomer',row);
|
|
|
+ // handleSelect(row){
|
|
|
+ // this.$emit('selectCustomer',row);
|
|
|
+ // },
|
|
|
+ handleSelect(selectedRows){
|
|
|
+ this.$emit('selectCustomer',selectedRows);
|
|
|
},
|
|
|
/** 搜索按钮操作 */
|
|
|
handleQuery() {
|
|
@@ -147,13 +189,19 @@ export default {
|
|
|
},
|
|
|
getList(){
|
|
|
this.loading = true;
|
|
|
- // if(this.tagIds.length>0){
|
|
|
- // this.queryParams.tags=this.tagIds.toString();
|
|
|
- // }
|
|
|
- // else{
|
|
|
- // this.queryParams.tags=null
|
|
|
- // }
|
|
|
- getMyCustomerList(this.queryParams).then(response => {
|
|
|
+ if(this.tagIds.length>0){
|
|
|
+ this.queryParams.tags=this.tagIds.toString();
|
|
|
+ }
|
|
|
+ else{
|
|
|
+ this.queryParams.tags=null
|
|
|
+ }
|
|
|
+ if(this.ctsTypeArr.length>0){
|
|
|
+ this.queryParams.customerType=this.ctsTypeArr.toString();
|
|
|
+ }
|
|
|
+ else{
|
|
|
+ this.queryParams.customerType=null
|
|
|
+ }
|
|
|
+ getMyCustomerList(this.addDateRange(this.queryParams, this.dateRange)).then(response => {
|
|
|
this.customerList = response.rows;
|
|
|
this.total = response.total;
|
|
|
this.loading = false;
|
|
@@ -164,4 +212,10 @@ export default {
|
|
|
</script>
|
|
|
<style scoped>
|
|
|
|
|
|
+ .footer{
|
|
|
+ margin-top: 10px;
|
|
|
+ display: flex;
|
|
|
+ align-items: center;
|
|
|
+ justify-content: flex-end;
|
|
|
+}
|
|
|
</style>
|