From 118ff4c71c095961c2c4264bfb340ab3e56b600e Mon Sep 17 00:00:00 2001 From: yunkexin <760754045@qq.com> Date: Tue, 30 Jun 2026 09:37:59 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=A1=E6=89=B9=E5=A2=9E=E5=8A=A0loading?= =?UTF-8?q?=E8=B0=83=E8=8A=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/custom/check-action.vue | 37 ++++++++++++++++++------------ 1 file changed, 22 insertions(+), 15 deletions(-) diff --git a/components/custom/check-action.vue b/components/custom/check-action.vue index 6083e43..c4e14e1 100644 --- a/components/custom/check-action.vue +++ b/components/custom/check-action.vue @@ -5,8 +5,8 @@ - - + + @@ -53,25 +53,26 @@ data() { return { value: '', - localIsBtnRefuseDisable: this.isBtnRefuseDisable + localIsBtnRefuseDisable: this.isBtnRefuseDisable, + isDisabled: false } }, // beforeCreate() KO // beforeMount() mounted() OK created() { - if (this.refuseApi) { - this.localIsBtnRefuseDisable = false - } else { - const pages = getCurrentPages() - const currentPage = pages[pages.length - 1] - const query = currentPage.options || {} - this.localIsBtnRefuseDisable = !(query.refuseApi && query.refuseApi !== 'undefined') - } + if (this.refuseApi) { + this.localIsBtnRefuseDisable = false + } else { + const pages = getCurrentPages() + const currentPage = pages[pages.length - 1] + const query = currentPage.options || {} + this.localIsBtnRefuseDisable = !(query.refuseApi && query.refuseApi !== 'undefined') + } }, mounted() { - if (this.$route && this.$route.query) { - this.localIsBtnRefuseDisable = !(this.$route.query.refuseApi && this.$route.query.refuseApi !== 'undefined') - } + if (this.$route && this.$route.query) { + this.localIsBtnRefuseDisable = !(this.$route.query.refuseApi && this.$route.query.refuseApi !== 'undefined') + } }, watch: { isBtnRefuseDisable(newValue) { @@ -81,6 +82,7 @@ methods: { handlePass() { + this.isDisabled = true const genParams = this.handleGenParams(10) handlePassAudit(genParams, this.okApi).then(res => { // this.$emit('pass', this.dataSource) @@ -95,9 +97,11 @@ //最后一个节点处理问题 handlePassAuditCallBack(res.Data + "?id=" + genParams.DATA_ID).then( res2 => { + this.isDisabled = false uni.navigateBack() }) } else { + this.isDisabled = false uni.navigateBack() } // } @@ -105,14 +109,17 @@ }) }, handleReject() { + this.isDisabled = true if (this.value == undefined || this.value === '' || this.value.length < 1) { uni.$showErrorInfo('请输入驳回意见!') + this.isDisabled = false return false } const genParams = this.handleGenParams(20) handleRejestAudit(genParams, this.refuseApi).then(res => { // this.$emit('reject', this.dataSource) uni.$showMsgFunc('驳回成功!', () => { + this.isDisabled = false uni.navigateBack() }, 'success', 1000) @@ -133,7 +140,7 @@ this.dataSource.CurrentNode = currentNodes[0]; } } - if(this.TASK_ORGID&&this.TASK_ORGID.length>0){ + if (this.TASK_ORGID && this.TASK_ORGID.length > 0) { this.dataSource.Parameter22 = this.TASK_ORGID } const params = {