bfg-common 1.4.270 → 1.4.272

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -203,9 +203,8 @@ const newTaskForm = ref<UI_I_ScheduleNewTasksForm>(
203
203
  )
204
204
  watch(
205
205
  newTaskForm,
206
- (newValue) => {
207
- if (props.isScheduledTasks)
208
- wizard.setDisabledNextButton(!newValue.task_name || !newValue.frequency)
206
+ (newValue: UI_I_ScheduleNewTasksForm) => {
207
+ if (props.isScheduledTasks) wizard.setDisabledNextButton(newValue.isValid)
209
208
  },
210
209
  { immediate: true, deep: true }
211
210
  )
@@ -15,7 +15,7 @@
15
15
  <template #modalBody="{ selectedStep }">
16
16
  <common-pages-scheduled-tasks-modals-common-new-task-form
17
17
  v-if="selectedStep.id === 0"
18
- v-model="newScheduledTaskForm"
18
+ v-model="modelSchedulerTask"
19
19
  :target="selectedVirtualMachine"
20
20
  />
21
21
 
@@ -95,12 +95,9 @@ import type { UI_I_VmSettings } from '~/lib/models/store/vm/interfaces'
95
95
  import type { UI_I_TreeNode } from '~/components/common/recursionTree/lib/models/interfaces'
96
96
  import type { UI_I_StorageConfigurePerDiskItem } from '~/components/common/wizards/vm/migrate/select/storage/configure/disk/table/lib/models/interfaces'
97
97
  import type { UI_I_TableInfoItem } from '~/components/atoms/table/info/lib/models/interfaces'
98
- import type {UI_I_ScheduleNewTasksForm} from "~/components/common/pages/scheduledTasks/modals/lib/models/interfaces";
98
+ import type { UI_I_ScheduleNewTasksForm } from '~/components/common/pages/scheduledTasks/modals/lib/models/interfaces'
99
99
  import { constructDataReadyViewFunc } from '~/components/common/wizards/vm/migrate/lib/config/constructDataReady'
100
100
  import * as validation from '~/components/common/wizards/vm/migrate/lib/validations'
101
- import {
102
- scheduledTaskDefaultFormFunc
103
- } from "~/components/common/pages/scheduledTasks/modals/lib/config/createScheduledTask";
104
101
 
105
102
  const props = defineProps<{
106
103
  project: UI_T_Project
@@ -119,6 +116,10 @@ const emits = defineEmits<{
119
116
  (event: 'hide'): void
120
117
  (event: 'finish', value: UI_I_MigrateFormLocal): void
121
118
  }>()
119
+ const modelSchedulerTask = defineModel<UI_I_ScheduleNewTasksForm>(
120
+ 'schedulerForm',
121
+ { required: true }
122
+ )
122
123
 
123
124
  const localization = computed<UI_I_Localization>(() => useLocal())
124
125
 
@@ -166,9 +167,6 @@ const form = ref<UI_I_MigrateFormLocal>({
166
167
  },
167
168
  vMotion_priority: 'high',
168
169
  })
169
- const newScheduledTaskForm = ref<UI_I_ScheduleNewTasksForm>(
170
- useDeepCopy(scheduledTaskDefaultFormFunc())
171
- )
172
170
 
173
171
  const validationFunc = async (
174
172
  value: UI_I_WizardStep[],
@@ -236,6 +234,14 @@ watch(
236
234
  { deep: true, immediate: true }
237
235
  )
238
236
 
237
+ watch(
238
+ modelSchedulerTask,
239
+ (newValue: UI_I_ScheduleNewTasksForm) => {
240
+ if (props.isScheduledTasks) wizard.setDisabledNextButton(newValue.isValid)
241
+ },
242
+ { immediate: true, deep: true }
243
+ )
244
+
239
245
  const loading = ref<boolean>(false)
240
246
 
241
247
  const connectedStorageIdOnVm = computed<string>(
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "bfg-common",
3
3
  "private": false,
4
- "version": "1.4.270",
4
+ "version": "1.4.272",
5
5
  "scripts": {
6
6
  "build": "nuxt build",
7
7
  "dev": "nuxt dev --port=3002",