From 74fae92c3fd076359385d27c5ac4e769a38522ab Mon Sep 17 00:00:00 2001
From: songshankun <songshankun@foxmail.com>
Date: 星期二, 10 十月 2023 15:41:15 +0800
Subject: [PATCH] feat: 销售机会/报价单销售总单/销售子单 列表添加序号
---
src/views/client/contacts/index.vue | 38 ++++++++++++++++++++++++++++----------
1 files changed, 28 insertions(+), 10 deletions(-)
diff --git a/src/views/client/contacts/index.vue b/src/views/client/contacts/index.vue
index 93e61cd..00dfcf3 100644
--- a/src/views/client/contacts/index.vue
+++ b/src/views/client/contacts/index.vue
@@ -31,6 +31,7 @@
@selContactsClick="selContactsClick"
@selClientClick="selClientClick"
@getSelectArray="getSelectArray"
+ @selTableCol="selTableCol"
>
<template slot="tableButton">
<el-table-column label="鎿嶄綔" width="90" fixed="right">
@@ -128,7 +129,17 @@
title: "鏂板缓",
infomation: {}
},
- search_map: {}
+ search_map: {},
+ tableColumn: [
+ { label: "鑱旂郴浜哄鍚�", prop: "name", min: 100, isContactClick: true, default: true }, // 鑱旂郴浜哄鍚�
+ { label: "瀹㈡埛鍚嶇О", prop: "client_name", min: 190, isClientClick: true }, // 瀹㈡埛鍚嶇О
+ { label: "鑱旂郴浜虹紪鍙�", prop: "number", min: 100 }, // 鑱旂郴浜虹紪鍙�
+ { label: "鑱屽姟", prop: "position", min: 120 }, // 鑱屽姟
+ { label: "鎵嬫満", prop: "phone", min: 100 }, // 鎵嬫満鍙风爜
+ { label: "閿�鍞礋璐d汉", prop: "member_name", min: 120 }, // 閿�鍞礋璐d汉
+ { label: "棣栬鑱旂郴浜�", prop: "is_first", isFirst: true, min: 90 } // 棣栬鑱旂郴浜�
+ ],
+ showCol: ['鑱旂郴浜哄鍚�','瀹㈡埛鍚嶇О','鑱旂郴浜虹紪鍙�','鑱屽姟','鎵嬫満','閿�鍞礋璐d汉','棣栬鑱旂郴浜�']
}
},
created() {
@@ -146,16 +157,11 @@
setTable() {
this.tableList = {
tableInfomation: [],
- tableColumn: [
- { label: "鑱旂郴浜哄鍚�", prop: "name", min: 100, isContactClick: true }, // 鑱旂郴浜哄鍚�
- { label: "瀹㈡埛鍚嶇О", prop: "client_name", min: 190, isClientClick: true }, // 瀹㈡埛鍚嶇О
- { label: "鑱旂郴浜虹紪鍙�", prop: "number", min: 100 }, // 鑱旂郴浜虹紪鍙�
- { label: "鑱屽姟", prop: "position", min: 120 }, // 鑱屽姟
- { label: "鎵嬫満", prop: "phone", min: 100 }, // 鎵嬫満鍙风爜
- { label: "閿�鍞礋璐d汉", prop: "member_name", min: 120 }, // 閿�鍞礋璐d汉
- { label: "棣栬鑱旂郴浜�", prop: "is_first", isFirst: true, min: 90 } // 棣栬鑱旂郴浜�
- ]
+ allcol: [],
+ showcol: this.showCol,
+ tableColumn:this.setColumnVisible(this.showCol)
}
+ this.tableList.allcol = this.tableList.tableColumn.filter(ele=>!ele.default).map(ele=>ele.label);
this.searchOptions = []
for (let i = 0; i < this.tableList.tableColumn.length; i++) {
const label = this.tableList.tableColumn[i].label
@@ -163,6 +169,18 @@
this.searchOptions.push({ value: value, label: label })
}
},
+ setColumnVisible(showCol){
+ return this.tableColumn.map(ele=>{
+ return {
+ ...ele,
+ isShowColumn:showCol.includes(ele.label)
+ }
+ })
+ },
+ selTableCol(val) {
+ this.showcol = val;
+ this.tableList.tableColumn = this.setColumnVisible(val);
+ },
// 璇锋眰鏁版嵁
async getData() {
this.loading = true
--
Gitblit v1.8.0