From f29da14bacd8e0236eac721ab888319aefe056e1 Mon Sep 17 00:00:00 2001 From: binbin_pan Date: Wed, 10 Apr 2024 16:48:20 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BE=80=E6=9D=A5=E5=8D=95=E4=BD=8D=E7=AE=A1?= =?UTF-8?q?=E7=90=86-=E4=BF=AE=E5=A4=8D=E6=96=B0=E5=A2=9E=E6=8C=89?= =?UTF-8?q?=E9=92=AE=E5=A4=9A=E6=AC=A1=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- sgzb-ui/src/views/base/comeAndGo/index.vue | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/sgzb-ui/src/views/base/comeAndGo/index.vue b/sgzb-ui/src/views/base/comeAndGo/index.vue index 49ab431a..6428a798 100644 --- a/sgzb-ui/src/views/base/comeAndGo/index.vue +++ b/sgzb-ui/src/views/base/comeAndGo/index.vue @@ -201,7 +201,7 @@ @@ -220,6 +220,7 @@ export default { components: { Treeselect }, data() { return { + isLoading: false, //单位类型 typeList: [], chonsenData: {}, @@ -377,17 +378,24 @@ export default { submitForm: function () { this.$refs["form"].validate(valid => { if (valid) { + this.isLoading = true; if (this.form.unitId != undefined) { updateUnit(this.form).then(response => { this.$modal.msgSuccess("修改成功"); this.open = false; + this.isLoading = false; this.getList(); + }).catch(() => { + this.isLoading = false; }); } else { addUnit(this.form).then(response => { this.$modal.msgSuccess("新增成功"); this.open = false; + this.isLoading = false; this.getList(); + }).catch(() => { + this.isLoading = false; }); } }