diff --git a/sgzb-ui/src/views/base/section/index.vue b/sgzb-ui/src/views/base/section/index.vue index e112ced0..0104bdcb 100644 --- a/sgzb-ui/src/views/base/section/index.vue +++ b/sgzb-ui/src/views/base/section/index.vue @@ -198,7 +198,7 @@ @@ -217,6 +217,7 @@ export default { components: { Treeselect }, data() { return { + isLoading: false, // 遮罩层 loading: true, // 选中数组 @@ -382,17 +383,24 @@ export default { submitForm: function () { this.$refs["form"].validate(valid => { if (valid) { + this.isLoading = true; if (this.form.lotId != undefined) { updateProjectLot(this.form).then(response => { this.$modal.msgSuccess("修改成功"); this.open = false; + this.isLoading = false; this.getList(); + }).catch(() => { + this.isLoading = false; }); } else { addProjectLot(this.form).then(response => { this.$modal.msgSuccess("新增成功"); this.open = false; + this.isLoading = false; this.getList(); + }).catch(() => { + this.isLoading = false; }); } }