From 199cc238b3d4fdef9c5dc697ad0759d146465cb9 Mon Sep 17 00:00:00 2001 From: williamet Date: Sat, 7 Sep 2024 22:48:51 +0800 Subject: [PATCH] =?UTF-8?q?bug=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/dataApproval/count.js | 2 +- src/layout/components/Sidebar/SidebarItem.vue | 21 ++++++++++++------- src/store/modules/user.js | 12 ++++++++--- src/views/components/ExpertForm/index.vue | 2 +- .../Enterpriseproducts/approval.vue | 4 ++-- .../Enterpriseproducts/index.vue | 7 +++---- .../dataAuditList/achievement/approval.vue | 9 ++++++-- src/views/dataAuditList/achievement/index.vue | 14 ++++++------- src/views/website/activity/active/signUp.vue | 6 ++++-- 9 files changed, 48 insertions(+), 29 deletions(-) diff --git a/src/api/dataApproval/count.js b/src/api/dataApproval/count.js index 17331ad..894ee57 100644 --- a/src/api/dataApproval/count.js +++ b/src/api/dataApproval/count.js @@ -6,7 +6,7 @@ export const getUnApprovalCount = (name) => method: "get", params: { name, - type: "1", + type: "0", }, }); diff --git a/src/layout/components/Sidebar/SidebarItem.vue b/src/layout/components/Sidebar/SidebarItem.vue index 018f6b4..7af7f6e 100644 --- a/src/layout/components/Sidebar/SidebarItem.vue +++ b/src/layout/components/Sidebar/SidebarItem.vue @@ -12,6 +12,7 @@ `/approval/data-list/laboratory`, ].includes(basePath) " + :value="getCount(basePath)" class="count-badge" > @@ -41,6 +42,12 @@ " /> + @@ -114,17 +121,17 @@ const onlyOneChild = ref({}); const userStore = useUserStore(); const getCount = (basePath) => { - if (basePath == "/approval/list") { + if (basePath === "/approval/list") { return userStore.unApprovedBusiness; - } else if (props.basePath == "/approval/dataList/approval") { + } else if (props.basePath === "/approval/dataList/approval") { return userStore.unApprovedExpert; - } else if (props.basePath == "/auditing/achievement") { + } else if (props.basePath === "/auditing/achievement") { return userStore.unApprovedAchivement; - } else if (props.basePath == "/auditing/demand") { + } else if (props.basePath === "/auditing/demand") { return userStore.unApprovedTechnology; - } else if (props.basePath == "/auditing/Enterpriseproducts") { + } else if (props.basePath === "/auditing/Enterpriseproducts") { return userStore.unApprovedProduct; - } else if (props.basePath == "/auditing/serviceDemand") { + } else if (props.basePath === "/auditing/serviceDemand") { return userStore.unApprovedService; } else if (props.basePath === "/approval/data-list/laboratory") { return userStore.unApprovedLab; diff --git a/src/store/modules/user.js b/src/store/modules/user.js index 164c396..ea9b7a0 100644 --- a/src/store/modules/user.js +++ b/src/store/modules/user.js @@ -114,7 +114,7 @@ const useUserStore = defineStore("user", { pageSize: 1, pageNum: 10, }); - this.unApprovedExpert = resp.total; + this.unApprovedExpert = resp.rows.length; }, async getUnApprovedAchivement() { const resp = await getUnApprovalCount("achievement"); @@ -125,12 +125,18 @@ const useUserStore = defineStore("user", { this.unApprovedTechnology = resp.data ?? 0; }, async getUnApprovedService() { + // const resp = await getUnApprovalCount("service"); const resp = await getUnApprovalCount("service"); this.unApprovedService = resp.data ?? 0; }, async getUnApprovedProduct() { - const resp = await getUnApprovalCount("product"); - this.unApprovedProduct = resp.data ?? 0; + // const resp = await getUnApprovalCount("product"); + const resp = await enterpriseProductApprovalList({ + status: 0, + pageSize: 1, + pageNum: 10, + }) + this.unApprovedProduct = resp.total ?? 0; }, async getServiceDemandTotal() { diff --git a/src/views/components/ExpertForm/index.vue b/src/views/components/ExpertForm/index.vue index 729decf..7b43794 100644 --- a/src/views/components/ExpertForm/index.vue +++ b/src/views/components/ExpertForm/index.vue @@ -233,7 +233,7 @@ - + diff --git a/src/views/dataAuditList/Enterpriseproducts/approval.vue b/src/views/dataAuditList/Enterpriseproducts/approval.vue index a93ed49..5499988 100644 --- a/src/views/dataAuditList/Enterpriseproducts/approval.vue +++ b/src/views/dataAuditList/Enterpriseproducts/approval.vue @@ -228,8 +228,8 @@
- 审核拒绝 - 通过审核 + + 审阅
diff --git a/src/views/dataAuditList/Enterpriseproducts/index.vue b/src/views/dataAuditList/Enterpriseproducts/index.vue index 1f80a46..641b9a9 100644 --- a/src/views/dataAuditList/Enterpriseproducts/index.vue +++ b/src/views/dataAuditList/Enterpriseproducts/index.vue @@ -11,7 +11,7 @@ @change="handleQuery" > - 待审核 + 已通过 已驳回 @@ -101,9 +101,8 @@ type="primary" round size="small" - :disabled="queryParams.status != 0" @click="handleApproval(row.id)" - >审批 + >审阅
- 审核拒绝 - 通过审核 + + + 返回
@@ -224,6 +225,10 @@ const submitForm = async (status) => { router.back(); }; +const submitBack = () => { + router.back(); +}; + getAchievementInfo(); diff --git a/src/views/dataAuditList/achievement/index.vue b/src/views/dataAuditList/achievement/index.vue index 00b0ffe..4f77186 100644 --- a/src/views/dataAuditList/achievement/index.vue +++ b/src/views/dataAuditList/achievement/index.vue @@ -12,7 +12,7 @@ @change="handleQuery" > - 待审核 + 已通过 已驳回 @@ -92,11 +92,11 @@ }} - + prop="workplace" + > - + />--> + +