add Overlay: 禁用页面鼠标

This commit is contained in:
lb
2023-04-23 13:50:46 +08:00
parent 9a27c7f55e
commit aaa571d77b
3 changed files with 56 additions and 3 deletions

View File

@@ -14,6 +14,9 @@
<DialogJustForm ref="edit-dialog" v-if="!!dialogConfigs" :dialog-visible.sync="dialogVisible" :configs="dialogConfigs"
@refreshDataList="getList" />
<!-- :bom-code="dialogBomCode" -->
<Overlay v-if="overlayVisible" />
</div>
</template>
@@ -21,11 +24,13 @@
import BaseListTable from "@/components/BaseListTable.vue";
import BaseSearchForm from "@/components/BaseSearchForm.vue";
import DialogJustForm from "./edit-dialog.vue";
import Overlay from '@/components/Overlay.vue';
import moment from "moment";
export default {
name: "ListViewWithHead",
components: { BaseSearchForm, BaseListTable, DialogJustForm },
components: { BaseSearchForm, BaseListTable, DialogJustForm, Overlay },
props: {
tableConfig: {
type: Object,
@@ -64,6 +69,7 @@ export default {
tableLoading: false,
refreshLayoutKey: null,
dialogBomCode: "",
overlayVisible: false
};
},
inject: ["urls"],
@@ -211,6 +217,7 @@ export default {
type: "warning",
})
.then(() => {
this.overlayVisible = true;
const realUrl = type === 'detach' ? this.urls.detach : type === 'pause-blender' ? this.urls.pauseBlender : this.urls.startBlender
return this.$http
.post(realUrl, data /* { id: data } */, { headers: { "Content-Type": "application/json" } })
@@ -231,6 +238,7 @@ export default {
duration: 1500,
});
}
this.overlayVisible = false;
});
});
}