From 91ebefb76256987cf346efc805a2697870b9244b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E9=9C=84?= Date: Tue, 19 Sep 2023 18:07:13 +0800 Subject: [PATCH] =?UTF-8?q?update=20=E5=9B=BD=E5=86=85=E6=A0=87=E5=87=86-?= =?UTF-8?q?=E6=94=B6=E8=97=8F=E8=BF=9E=E7=82=B9=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../domesticStandard/DomesticStandardList.vue | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/views/standardRegulationLibrary/domesticStandard/DomesticStandardList.vue b/src/views/standardRegulationLibrary/domesticStandard/DomesticStandardList.vue index a3e21057..e342aa4a 100644 --- a/src/views/standardRegulationLibrary/domesticStandard/DomesticStandardList.vue +++ b/src/views/standardRegulationLibrary/domesticStandard/DomesticStandardList.vue @@ -258,7 +258,8 @@ export default { selectedTreeKeys: [], // 选中的树节点key selectedTreeNodeCodes: [], // 选中树节点的code tableSlotField: ['standard_name', 'standard_number'], // 表格中需要插槽的字段 - treeLoading: false + treeLoading: false, + isCollection: false } }, computed: { @@ -335,6 +336,10 @@ export default { * @param record */ handleCollection ({ collectionFlag, id: standardId, standard_number: standardNumber }) { + if (this.isCollection) { + return + } + this.isCollection = true let params let submitFunc // 取消收藏 @@ -346,16 +351,15 @@ export default { submitFunc = collectionDomesticStandard } // 收藏 - this.loading = true submitFunc(params).then(res => { if (res.success) { this.$message.success(res.message) - this.loadData(1) + this.loadData() } else { this.$message.warn(res.message) } }).finally(() => { - this.loading = false + this.isCollection = false }) }, /**