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() {