From d5bd0e88c1eec6bb2947d2bfa57348d89edbc1c3 Mon Sep 17 00:00:00 2001
From: zhouwx <1175765986@qq.com>
Date: 星期五, 18 七月 2025 16:20:45 +0800
Subject: [PATCH] 修改

---
 src/views/build/conpanyFunctionConsult/digitalFileDep/manageType/qualityManual/index.vue |   24 ++++++++++++++++++++++--
 1 files changed, 22 insertions(+), 2 deletions(-)

diff --git a/src/views/build/conpanyFunctionConsult/digitalFileDep/manageType/qualityManual/index.vue b/src/views/build/conpanyFunctionConsult/digitalFileDep/manageType/qualityManual/index.vue
index a5d5418..e71360a 100644
--- a/src/views/build/conpanyFunctionConsult/digitalFileDep/manageType/qualityManual/index.vue
+++ b/src/views/build/conpanyFunctionConsult/digitalFileDep/manageType/qualityManual/index.vue
@@ -80,7 +80,7 @@
   getStandardDetail,
   getStandardQuality
 } from "@/api/standardSys/standardSys";
-import {getDepart, getDistribution, getSysClause} from "@/api/orgStructure/depart";
+import {getDepart, getDistribution, getFunctionalRemarkList, getSysClause} from "@/api/orgStructure/depart";
 
 const userStore = useUserStore()
 const { proxy } = getCurrentInstance();
@@ -229,7 +229,8 @@
   if(res.code === 200){
     if(!res.data || (res.data.companyIndustryTemplates.length == 0 && res.data.companyQualityPolicies.length == 0 && res.data.companySummaries.length == 0 && res.data.sysFunctionalDistributions
         .length == 0 && res.data.treeSelects.length == 0)){
-      return Promise.reject(new Error('该企业暂无质量数据'));
+      loading.value = false
+      return Promise.reject(new Error('该企业暂无质量数据'))
     }
     data.companyInfo.summaries = res.data.companySummaries ? res.data.companySummaries[0]?.companySummary : []
     data.companyInfo.policies = res.data.companyQualityPolicies ? res.data.companyQualityPolicies[0]?.policy : []
@@ -243,6 +244,24 @@
         templateName: item.templateName
       }
     }) || []
+  }else{
+    ElMessage.warning(res.message)
+  }
+}
+
+const getRemarksList = async (companyId)=> {
+  const res = await getFunctionalRemarkList({companyId: companyId})
+  if(res.code == 200){
+    const originRemark = res.data
+    for(let item of originRemark){
+      const foundObj = data.caluseList.find(i=>i.clauseNum == item.clauseNum)
+      if(foundObj){
+        foundObj.remark = item.remark
+      }
+    }
+    data.companyInfo.remarks = originRemark.map(i=>{
+      return `${i.clauseNum}:${i.remark}`
+    }).join(';')
   }else{
     ElMessage.warning(res.message)
   }
@@ -294,6 +313,7 @@
     try {
       await getDeptList(val)
       await getInfo(val)
+      await getRemarksList(val.companyId)
       // 2. 等待DOM更新完成
       await nextTick();
 

--
Gitblit v1.9.2