From d4f4c52402b91cb8e17c1845da71c5e39662fde0 Mon Sep 17 00:00:00 2001
From: yangfeng <wanwan926_4@163.com>
Date: 星期三, 03 一月 2024 15:28:06 +0800
Subject: [PATCH] 销售报价单列表页增加统计内容及接口联调、添加报价单天天客户名称及对应限制功能

---
 src/views/service/serviceContract/index.vue |   45 +++++++++++++++++++++++++++++++++++----------
 1 files changed, 35 insertions(+), 10 deletions(-)

diff --git a/src/views/service/serviceContract/index.vue b/src/views/service/serviceContract/index.vue
index 08cd136..d56d3d6 100644
--- a/src/views/service/serviceContract/index.vue
+++ b/src/views/service/serviceContract/index.vue
@@ -198,13 +198,36 @@
     // 璇锋眰鏁版嵁
     async getData() {
       this.loading = true
-      await getServiceContractList({
-        keyword: this.keyword,
-        keywordType: this.keywordType,
-        page: this.pagerOptions.currPage,
-        pageSize: this.pagerOptions.pageSize,
-        contactId:this.addConfig.client_id
-      })
+      let params = {}
+      console.log(this.addConfig)
+      if (this.addConfig.id && this.addConfig.keywordType === "閿�鍞満浼�") {
+        params = {
+          saleChanceId: this.addConfig.id,
+          page: this.pagerOptions.currPage,
+          pageSize: this.pagerOptions.pageSize
+        }
+      } else if (this.addConfig.id && this.addConfig.keywordType === "閿�鍞槑缁嗗崟") {
+        params = {
+          salesDetailsId: this.addConfig.id,
+          page: this.pagerOptions.currPage,
+          pageSize: this.pagerOptions.pageSize
+        }
+      } else if (this.addConfig.id && this.addConfig.keywordType === "鎶ヤ环鍗�") {
+        params = {
+          quotationId: this.addConfig.id,
+          page: this.pagerOptions.currPage,
+          pageSize: this.pagerOptions.pageSize
+        }
+      } else {
+        params = {
+          keyword: this.keyword,
+          keywordType: this.keywordType,
+          page: this.pagerOptions.currPage,
+          pageSize: this.pagerOptions.pageSize,
+          contactId: this.addConfig.client_id
+        }
+      }
+      await getServiceContractList(params)
         .then((res) => {
           console.log(res)
           if (res.code === 200) {
@@ -248,9 +271,9 @@
       this.editConfig.infomation = {
         ...this.addConfig,
         currency: "浜烘皯甯�",
-        client_name: "",
+        client_name: Object.keys(this.addConfig).length === 0 ? "" : this.addConfig.client_name,
         contact_name: "",
-        sale_chance_name: "",
+        sale_chance_name: Object.keys(this.addConfig).length === 0 ? "" : this.addConfig.sale_chance_name,
         contract_number: "",
         quotation_number: ""
       }
@@ -266,7 +289,9 @@
         quotation_number: row.quotation.number,
         currency: "浜烘皯甯�",
         sale_chance_name: row.SaleChance.name,
-        contact_name: row.contact.name
+        contact_name: row.contact.name,
+        serviceContractTypeId: row.serviceContractTypeId === 0 ? null : row.serviceContractTypeId,
+        serviceContractStatusId: row.serviceContractStatusId === 0 ? null : row.serviceContractStatusId
       }
     },
     // 鍒犻櫎

--
Gitblit v1.8.0