From 0712b49e5538589dac4859ca8cebf196caa954ab Mon Sep 17 00:00:00 2001 From: zuozhengqing <a13193816592@163.com> Date: 星期二, 21 十一月 2023 11:28:09 +0800 Subject: [PATCH] fix:供应商管理添加产品,产品列表展示修改及采购管理bug修改 --- src/views/supplierManage/supplier/DetailSupplier.vue | 102 +++++++++++++++++++++++++++++++++++++++++++++++---- 1 files changed, 94 insertions(+), 8 deletions(-) diff --git a/src/views/supplierManage/supplier/DetailSupplier.vue b/src/views/supplierManage/supplier/DetailSupplier.vue index 509d4ca..c2765a1 100644 --- a/src/views/supplierManage/supplier/DetailSupplier.vue +++ b/src/views/supplierManage/supplier/DetailSupplier.vue @@ -72,12 +72,26 @@ </div> </div> </div> - <div v-if="activeName === 'second'" class="second"> - <!-- <FollowupRecords - :isDetail="true" - :follow-record="detailConfig.infomation.FollowRecord" - :add-config="addConfig" - /> --> + <div v-if="activeName === 'second'" class="detail"> + <!-- 閲囪喘璁㈠崟-鍩烘湰淇℃伅 --> + <!-- 浜у搧淇℃伅 --> + <div class="basic-info"> + <div class="basic-info-label" @click="expandClick('basic')"> + <i v-if="isBasicExpand" class="el-icon-arrow-down"></i> + <i v-else class="el-icon-arrow-up"></i> + <span style="margin-left: 10px">浜у搧淇℃伅</span> + </div> + <div v-show="isBasicExpand" class="basic-info-content"> + <TableCommonView + style="margin-top: 2px" + class="content-table" + ref="tableListRef" + :table-list="tableList" + @selTableCol="selTableCol" + > + </TableCommonView> + </div> + </div> </div> </div> </el-drawer> @@ -93,7 +107,8 @@ default: () => { return { visible: false, - infomation: {} + infomation: {}, + productListInfo:[] } } } @@ -111,10 +126,23 @@ addConfig: {}, record: "", // 鏈�鏂拌繘灞� noContactDays: 0, - newContactDays: "" + newContactDays: "", + tableList:{}, + showCol: ['浜у搧鍚嶇О', '浜у搧缂栫爜', '璁¢噺鍗曚綅', '瑙勬牸鍨嬪彿', '鏁伴噺', '閿�鍞崟浠�','浠风◣鍚堣','鎻忚堪'], + tableColumn: [ + { label: "浜у搧鍚嶇О", prop: "name", min: 160, }, + { label: "浜у搧缂栫爜", prop: "number", min: 130, }, + { label: "璁¢噺鍗曚綅", prop: "unit", min: 130 }, + { label: "瑙勬牸鍨嬪彿", prop: "specifications", min: 130 }, + { label: "鏁伴噺", prop: "amount", min: 130 }, + { label: "閿�鍞崟浠�", prop: "price", min: 130 }, + { label: "浠风◣鍚堣", prop: "total", min: 130 }, + { label: "鎻忚堪", prop: "remark", min: 130 }, + ], } }, created() { + console.log(this.detailConfig,"鎶藉眽缁勪欢") this.setData(this.detailConfig.infomation) this.addConfig = { id_name: "sales_leads_id", @@ -166,6 +194,44 @@ rightValue: "" } ] + this.purchaseList = [ + { + leftStr: "閲囪喘鍗曞彿", + leftValue: item.number, + rightStr: "閲囪喘鍗曞悕绉�", + rightValue: item.name + }, + { + leftStr: "渚涘簲鍟嗙被鍨�", + leftValue: item.supplierType, + rightStr: "鎵�灞炶涓�", + rightValue: item.industry + }, + { + leftStr: "鍗曟嵁绫诲瀷", + leftValue: item.contact, + rightStr: "渚涘簲鍟嗗悕绉�", + rightValue: item.phone + }, + { + leftStr: "閲囪喘鏁伴噺", + leftValue: item.responsiblePersonName, + rightStr: "鏀惰揣浠撳簱", + rightValue: item.url + }, + { + leftStr: "缁忓姙浜�", + leftValue: item.email, + rightStr: "鍒跺崟浜�", + rightValue: "" + }, + { + leftStr: "鐘舵��", + leftValue: item.email, + rightStr: "", + rightValue: "" + }, + ] this.dynamicInfoList = [ { leftStr: "鎴峰悕", @@ -180,6 +246,26 @@ rightValue: "" } ] + this.tableList = { + tableInfomation: this.detailConfig.productListInfo?this.detailConfig.productListInfo:[], + selectIndex: true, + showcol: this.showCol, + allcol:[], + tableColumn:this.setColumnVisible(this.showCol), + }; + this.tableList.allcol = this.tableList.tableColumn.filter(ele=>!ele.default).map(ele=>ele.label); + }, + selTableCol(val) { + this.showcol = val; + this.tableList.tableColumn = this.setColumnVisible(val); + }, + setColumnVisible(showCol){ + return this.tableColumn.map(ele=>{ + return { + ...ele, + isShowColumn:showCol.includes(ele.label) + } + }) }, handleClose() { this.detailConfig.visible = false -- Gitblit v1.8.0