From 4c873da777ea0c6ce0d342ce793fabae89b3f66d Mon Sep 17 00:00:00 2001 From: yangfeng <wanwan926_4@163.com> Date: 星期四, 24 八月 2023 19:29:00 +0800 Subject: [PATCH] 供应商和产品管理 --- src/views/supplierManage/supplier/index.vue | 69 ++++++++++++++++++++++++++-------- 1 files changed, 53 insertions(+), 16 deletions(-) diff --git a/src/views/supplierManage/supplier/index.vue b/src/views/supplierManage/supplier/index.vue index 5aa9d44..354b34f 100644 --- a/src/views/supplierManage/supplier/index.vue +++ b/src/views/supplierManage/supplier/index.vue @@ -23,7 +23,7 @@ <el-table-column label="鎿嶄綔" width="120"> <template slot-scope="scope"> <el-button @click="handleClick(scope.row)" type="text" size="small">鍚敤</el-button> - <el-button @click="followupClick(scope.row)" type="text" size="small">鍋滅敤</el-button> + <el-button @click="editClick(scope.row)" type="text" size="small">鍋滅敤</el-button> <el-button @click="modifyClick(scope.row)" type="text" size="small">淇敼</el-button> <!-- <el-button @click="delClick(scope.row.id)" type="text" size="small">鍒犻櫎</el-button> --> </template> @@ -49,7 +49,7 @@ @resetClick="resetClick" /> <div class="add-view"> - <el-button type="primary" size="mini">鏂板缓</el-button> + <el-button type="primary" size="mini" @click="addNewProductClick">娣诲姞鏂颁骇鍝�</el-button> </div> </div> <template> @@ -60,10 +60,10 @@ @getSelectArray="getSelectArray" > <template slot="tableButton"> - <el-table-column label="鎿嶄綔" width="120"> + <el-table-column label="鎿嶄綔" width="170"> <template slot-scope="scope"> - <el-button @click="handleClick(scope.row)" type="text" size="small">鐩稿叧渚涘簲鍟�</el-button> - <el-button @click="followupClick(scope.row)" type="text" size="small">淇敼</el-button> + <el-button @click="raleteClick(scope.row)" type="text" size="small">鐩稿叧渚涘簲鍟�</el-button> + <el-button @click="editClick(scope.row)" type="text" size="small">淇敼</el-button> <el-button @click="delClick(scope.row)" type="text" size="small">鍒犻櫎</el-button> <!-- <el-button @click="delClick(scope.row.id)" type="text" size="small">鍒犻櫎</el-button> --> </template> @@ -76,9 +76,13 @@ </template> </div> <!-- 鏂板缓/缂栬緫閿�鍞嚎绱� --> - <!-- <AddSalesLeadDialog v-if="editSalesLeadConfig.visible" :edit-rightContent-config="editSalesLeadConfig" /> --> + <AddSupplier v-if="editConfig.visible" :add-common-config="editConfig" /> <!-- 璇︽儏 --> <DetailSupplier v-if="commonDetail.visible" :common-detail="commonDetail" /> + <!-- 鐩稿叧渚涘簲鍟� --> + <RaleteSupplierList v-if="raleteSupplierConfig.visible" :common-config="raleteSupplierConfig" /> + <!-- 娣诲姞鏂颁骇鍝� --> + <AddNewProduct v-if="newProductConfig.visible" :add-common-config="newProductConfig" /> </div> </template> @@ -86,11 +90,14 @@ import pageMixin from "@/components/makepager/pager/mixin/pageMixin" import { getSalesLeadsList, getDeleteSalesLeads } from "@/api/client/salesLead" import DetailSupplier from "@/views/supplierManage/supplier/DetailSupplier" +import AddSupplier from "@/views/supplierManage/supplier/AddSupplier" +import RaleteSupplierList from "@/views/supplierManage/supplier/RaleteSupplierList" +import AddNewProduct from "@/views/supplierManage/supplier/AddNewProduct" export default { name: "SupplierManage", props: {}, - components: { DetailSupplier }, + components: { DetailSupplier, AddSupplier, RaleteSupplierList, AddNewProduct }, mixins: [pageMixin], computed: {}, data() { @@ -107,6 +114,15 @@ editConfig: { visible: false, title: "鏂板缓", + infomation: {} + }, + raleteSupplierConfig: { + visible: false, + infomation: {} + }, + newProductConfig: { + visible: false, + title: "娣诲姞", infomation: {} }, search_map: {} @@ -142,12 +158,16 @@ }, setProductTable() { this.productTableList = { - tableInfomation: [], + tableInfomation: [ + { + number: "aaaaa" + } + ], selectBox: true, selectIndex: true, tableColumn: [ - { label: "浜у搧缂栫爜", prop: "name", min: 190, isSalesLeadClick: true }, - { label: "浜у搧鍚嶇О", prop: "number", min: 130 }, + { label: "浜у搧缂栫爜", prop: "number", min: 190 }, + { label: "浜у搧鍚嶇О", prop: "name", min: 130 }, { label: "浜у搧瑙勬牸", prop: "contact_name", min: 130 }, { label: "鍗曚綅", prop: "contact_phone", min: 130 }, { label: "閲囪喘浠锋牸", prop: "sales_resources", min: 130 }, @@ -199,7 +219,10 @@ this.getData() }, // 鏂板缓渚涘簲鍟� - addBtnClick() {}, + addBtnClick() { + this.editConfig.visible = true + this.editConfig.title = "鏂板缓" + }, // 缂栬緫渚涘簲鍟� handleClick(row) { console.log(row) @@ -207,12 +230,26 @@ // 淇敼渚涘簲鍟� modifyClick(row) { console.log(row) - }, - // 璺熻繘 - followupClick(row) { this.editConfig.visible = true - this.editConfig.title = "鏂板缓" - this.editConfig.infomation = { sales_leads_name: row.name } + this.editConfig.title = "淇敼" + this.editConfig.infomation = { ...row } + }, + // 鐩稿叧渚涘簲鍟� + raleteClick(row) { + console.log(row) + this.raleteSupplierConfig.visible = true + this.raleteSupplierConfig.infomation = { ...row } + }, + // 娣诲姞鏂颁骇鍝� + addNewProductClick() { + this.newProductConfig.visible = true + this.newProductConfig.title = "娣诲姞" + }, + // 淇敼浜у搧 + editClick(row) { + console.log(row) + this.newProductConfig.visible = true + // this.newProductConfig.title = "淇敼" }, // 鍒犻櫎 delClick() { -- Gitblit v1.8.0