From c1ab31299bf85d64377cfbdfa00c3fd02eee391e Mon Sep 17 00:00:00 2001 From: qb <1191961160@qq.com> Date: Sat, 11 May 2024 18:16:54 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E5=B9=B2=E7=BA=BF=E6=8F=90?= =?UTF-8?q?=E8=B4=A7=E6=93=8D=E4=BD=9CLoading?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../arteryDistrilbutionBillLadingList.vue | 26 ++++++++++++------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/src/views/distribution/inventory/arteryDistrilbutionBillLadingList.vue b/src/views/distribution/inventory/arteryDistrilbutionBillLadingList.vue index da47020b..322d9ee8 100644 --- a/src/views/distribution/inventory/arteryDistrilbutionBillLadingList.vue +++ b/src/views/distribution/inventory/arteryDistrilbutionBillLadingList.vue @@ -663,23 +663,29 @@ export default { confirmButtonText: '确定', cancelButtonText: '取消', type: 'success', - }) - .then(() => { - return postUpdateBillladingStatus({ + }).then(async () => { + try { + this.loadingObj.pageLoading = true; + + const res = await postUpdateBillladingStatus({ id: this.selectionList[0].id, type, }); - }) - .then(() => { + + const { code, msg } = res.data; + + if (code !== 200) return; + this.$message.success(msg); // 清空复选框 this.selectionClear(); // 刷新表格 this.onLoad(this.page); - this.$message({ - type: 'success', - message: '操作成功!', - }); - }); + } catch (error) { + console.log('error :>> ', error); + } finally { + this.loadingObj.pageLoading = false; + } + }); }, /** 开启添加提货数据弹窗 */ handleAddDistrilbution() {