From f2436df23b6449554ecb1b4af0c84596886766ee Mon Sep 17 00:00:00 2001 From: wangwei <1610949092@qq.com> Date: Fri, 27 Dec 2024 15:09:08 +0800 Subject: [PATCH] =?UTF-8?q?12/27=20=E9=80=89=E5=85=A5=E9=98=BF=E9=87=8C?= =?UTF-8?q?=E5=8D=95=E6=8D=AEloading1.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../distribution/selectMsfxOrderDialog.vue | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/src/views/pharmaceuticals/distribution/selectMsfxOrderDialog.vue b/src/views/pharmaceuticals/distribution/selectMsfxOrderDialog.vue index 0440b11..151340b 100644 --- a/src/views/pharmaceuticals/distribution/selectMsfxOrderDialog.vue +++ b/src/views/pharmaceuticals/distribution/selectMsfxOrderDialog.vue @@ -263,20 +263,31 @@ export default { } this.orderFormData.orderEntity = JSON.parse(JSON.stringify(this.orderFormData)); this.orderFormData.aliData = this.currentRow - this.loading = true + // this.loading = true + // 显示加载状态 + const loading = this.$loading({ + lock: true, + text: '选入中...', + spinner: 'el-icon-loading', + background: 'rgba(0, 0, 0, 0.7)' + }); addAliBizProduct(this.orderFormData).then((res) => { if (res.code === 20000) { this.codeDetailVisible = false this.$message.success('选入成功') - this.loading = false + // this.loading = false this.closeDialog(res.data) + // 关闭加载状态 + loading.close(); } else { this.$message.error(res.message) - this.loading = false + // this.loading = false + loading.close(); } }).catch((error) => { this.$message.error('选入失败') - this.loading = false + // this.loading = false + loading.close(); }) }, hideSearch() {