diff --git a/src/components/AddSchedule/ScheduleForm.vue b/src/components/AddSchedule/ScheduleForm.vue index 878ebd7..c1d9192 100644 --- a/src/components/AddSchedule/ScheduleForm.vue +++ b/src/components/AddSchedule/ScheduleForm.vue @@ -155,7 +155,8 @@ import ExecuteTime from './ExecuteTime.vue' mixins: [ExecuteTime], computed: { ...mapState({ - lang: state => state.global.lang + lang: state => state.global.lang, + is_scheduler_enabled: state => state.global.is_scheduler_enabled }) }, methods: { @@ -250,6 +251,9 @@ export default class Addschedule extends Vue { } async querySchedules () { + if (!this.is_scheduler_enabled) { + return + } try { this.loadingScheduleList = true const res = await this.getSchedulesList() diff --git a/src/components/EditTask/index.vue b/src/components/EditTask/index.vue index c81bbb6..c1833d7 100644 --- a/src/components/EditTask/index.vue +++ b/src/components/EditTask/index.vue @@ -114,6 +114,9 @@ vuex.registerModule(['modals', 'EditTaskModal'], store) taskInfo: state => state.taskInfo, form: state => state.form, callback: state => state.callback + }), + ...mapState({ + is_scheduler_enabled: state => state.global.is_scheduler_enabled }) }, methods: { @@ -170,6 +173,9 @@ export default class EditTask extends Vue { } async querySchedules () { + if (!this.is_scheduler_enabled) { + return + } try { this.loadingScheduleList = true const res = await this.getSchedulesList() diff --git a/src/components/Header/HeaderMenu.vue b/src/components/Header/HeaderMenu.vue index dcdaa9c..363c9fd 100644 --- a/src/components/Header/HeaderMenu.vue +++ b/src/components/Header/HeaderMenu.vue @@ -19,7 +19,7 @@ {{$t('menu.jobs')}} - +