bfg-common 1.4.158 → 1.4.160
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.
- package/components/common/mainNavigationPanel/MainNavigationPanelNew.vue +307 -307
- package/components/common/monitor/advanced/tools/chartOptionsModal/counters/timespan/object/Object.vue +1 -4
- package/components/common/select/input/lib/models/interfaces.ts +1 -0
- package/components/common/wizards/vm/common/computeResource/TreeView.vue +3 -6
- package/components/common/wizards/vm/common/tooltip/Tooltip.vue +5 -5
- package/components/common/wizards/vm/migrate/Migrate.vue +161 -188
- package/components/common/wizards/vm/migrate/lib/config/constructDataReady.ts +166 -53
- package/components/common/wizards/vm/migrate/lib/config/steps.ts +93 -0
- package/components/common/wizards/vm/migrate/lib/models/interfaces.ts +26 -19
- package/components/common/wizards/vm/migrate/lib/utils.ts +0 -80
- package/components/common/wizards/vm/migrate/lib/validations.ts +57 -0
- package/components/common/wizards/vm/migrate/select/computeResource/ComputeResource.vue +18 -52
- package/components/common/wizards/vm/migrate/select/computeResource/lib/config/tabsPannel.ts +1 -1
- package/components/common/wizards/vm/migrate/select/computeResource/lib/models/interfaces.ts +2 -1
- package/components/common/wizards/vm/migrate/select/computeResource/tableView/TableView.vue +9 -18
- package/components/common/wizards/vm/migrate/select/computeResource/tableView/lib/config/clusterTable.ts +1 -1
- package/components/common/wizards/vm/migrate/select/computeResource/tableView/lib/config/resourcePoolTable.ts +1 -1
- package/components/common/wizards/vm/migrate/select/computeResource/tableView/lib/config/vappsTable.ts +20 -18
- package/components/common/wizards/vm/migrate/select/network/Network.vue +16 -11
- package/components/common/wizards/vm/migrate/select/network/lib/models/interfaces.ts +4 -0
- package/components/common/wizards/vm/migrate/select/network/table/network/Network.vue +16 -17
- package/components/common/wizards/vm/migrate/select/priority/Priority.vue +2 -16
- package/components/common/wizards/vm/migrate/select/storage/Storage.vue +29 -61
- package/components/common/wizards/vm/migrate/select/storage/configure/batch/Batch.vue +28 -33
- package/components/common/wizards/vm/migrate/select/storage/configure/batch/config/virtualDiskFormat.ts +30 -0
- package/components/common/wizards/vm/migrate/select/storage/{table/datastore/Datastore.vue → configure/batch/table/Table.vue} +48 -34
- package/components/common/wizards/vm/migrate/select/storage/configure/batch/table/lib/config/datastoreTable.ts +177 -0
- package/components/common/wizards/vm/migrate/select/storage/{table/datastore → configure/batch/table}/lib/models/types.ts +2 -2
- package/components/common/wizards/vm/migrate/select/storage/configure/disk/Disk.vue +11 -30
- package/components/common/wizards/vm/migrate/select/storage/{table/disk/Disk.vue → configure/disk/table/Table.vue} +5 -17
- package/components/common/wizards/vm/migrate/select/storage/{table/disk/lib/config/config.ts → configure/disk/table/lib/config/diskTable.ts} +36 -23
- package/components/common/wizards/vm/migrate/select/storage/{table/disk → configure/disk/table}/lib/config/tableKeys.ts +1 -1
- package/components/common/wizards/vm/migrate/select/storage/{table/disk → configure/disk/table}/lib/models/interfaces.ts +5 -0
- package/components/common/wizards/vm/migrate/select/storage/lib/models/interfaces.ts +0 -14
- package/components/common/wizards/vm/migrate/select/storage/selectedPerDisk/SelectedPerDisk.vue +14 -22
- package/components/common/wizards/vm/migrate/select/targetServer/new/New.vue +111 -144
- package/components/common/wizards/vm/migrate/select/targetServer/new/lib/models/interfaces.ts +8 -10
- package/components/common/wizards/vm/migrate/select/targetServer/targetServer.vue +11 -1
- package/components/common/wizards/vm/migrate/select/type/Type.vue +8 -19
- package/package.json +1 -1
- package/components/common/wizards/vm/migrate/contentHeading/ContentHeading.vue +0 -106
- package/components/common/wizards/vm/migrate/contentHeading/lib/models/interfaces.ts +0 -7
- package/components/common/wizards/vm/migrate/select/storage/diskFormat/DiskFormat.vue +0 -69
- package/components/common/wizards/vm/migrate/select/storage/diskFormat/lib/config/formatOptions.ts +0 -26
- package/components/common/wizards/vm/migrate/select/storage/table/datastore/lib/config/config.ts +0 -179
- package/components/common/wizards/vm/migrate/select/targetServer/new/lib/config/defaultForm.ts +0 -36
- /package/components/common/wizards/vm/migrate/select/storage/{table/disk → configure/disk/table}/lib/models/types.ts +0 -0
- /package/components/common/wizards/vm/migrate/{lib → select/type/lib}/models/types.ts +0 -0
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="new-server">
|
|
3
|
+
<atoms-alert
|
|
4
|
+
v-show="alertErrors.length"
|
|
5
|
+
:status="alertStatus"
|
|
6
|
+
:items="alertErrors"
|
|
7
|
+
hide-close-icon
|
|
8
|
+
test-id="create-backup-alert"
|
|
9
|
+
class="new-server__alert"
|
|
10
|
+
/>
|
|
11
|
+
|
|
3
12
|
<div>
|
|
4
13
|
<div class="clr-form-control clr-row">
|
|
5
14
|
<label for="" class="clr-control-label clr-col-md-4">
|
|
@@ -8,51 +17,54 @@
|
|
|
8
17
|
|
|
9
18
|
<div
|
|
10
19
|
class="clr-control-container"
|
|
11
|
-
:class="
|
|
20
|
+
:class="addressErrorText && 'clr-error'"
|
|
12
21
|
>
|
|
13
22
|
<div class="flex-align-center">
|
|
14
23
|
<input
|
|
15
24
|
id="configuration-name-input"
|
|
16
|
-
v-model="
|
|
25
|
+
v-model="model.fqdn"
|
|
17
26
|
data-id="configuration-name-input"
|
|
18
27
|
type="text"
|
|
19
28
|
class="clr-input"
|
|
20
|
-
@blur="
|
|
21
|
-
@input="
|
|
29
|
+
@blur="onInitValidation(true, ['address'])"
|
|
30
|
+
@input="onInitValidation(false, ['address'])"
|
|
22
31
|
/>
|
|
23
32
|
<atoms-the-icon class="error-icon" name="info-circle" />
|
|
24
33
|
</div>
|
|
25
34
|
|
|
26
|
-
<div class="clr-subtext
|
|
27
|
-
{{
|
|
35
|
+
<div v-if="addressErrorText" class="clr-subtext">
|
|
36
|
+
{{ addressErrorText }}
|
|
37
|
+
</div>
|
|
38
|
+
<div v-else class="clr-subtext">
|
|
39
|
+
vCenter Server FQDN or IP address
|
|
28
40
|
</div>
|
|
29
41
|
</div>
|
|
30
42
|
</div>
|
|
31
43
|
|
|
32
44
|
<div class="clr-form-control clr-row">
|
|
33
45
|
<label class="clr-control-label clr-col-md-4">
|
|
34
|
-
{{ localization.
|
|
46
|
+
{{ localization.auth.username }}
|
|
35
47
|
</label>
|
|
36
48
|
|
|
37
49
|
<div
|
|
38
50
|
class="clr-control-container"
|
|
39
|
-
:class="
|
|
51
|
+
:class="usernameErrorText && 'clr-error'"
|
|
40
52
|
>
|
|
41
53
|
<div class="flex-align-center">
|
|
42
54
|
<input
|
|
43
55
|
id="configuration-folder-input"
|
|
44
|
-
v-model="
|
|
56
|
+
v-model="model.user"
|
|
45
57
|
data-id="configuration-folder-input"
|
|
46
58
|
type="text"
|
|
47
59
|
class="clr-input"
|
|
48
|
-
@blur="
|
|
49
|
-
@input="
|
|
60
|
+
@blur="onInitValidation(true, ['username'])"
|
|
61
|
+
@input="onInitValidation(false, ['username'])"
|
|
50
62
|
/>
|
|
51
63
|
<atoms-the-icon class="error-icon" name="info-circle" />
|
|
52
64
|
</div>
|
|
53
65
|
|
|
54
|
-
<div v-if="
|
|
55
|
-
{{
|
|
66
|
+
<div v-if="usernameErrorText" class="clr-subtext">
|
|
67
|
+
{{ usernameErrorText }}
|
|
56
68
|
</div>
|
|
57
69
|
<div v-else class="clr-subtext">example@domain.local</div>
|
|
58
70
|
</div>
|
|
@@ -60,27 +72,28 @@
|
|
|
60
72
|
|
|
61
73
|
<div class="nd-mt-0 clr-form-control clr-row">
|
|
62
74
|
<label class="clr-control-label clr-col-md-4">
|
|
63
|
-
{{ localization.
|
|
75
|
+
{{ localization.auth.password }}
|
|
64
76
|
</label>
|
|
65
77
|
|
|
66
78
|
<div
|
|
67
79
|
class="clr-control-container"
|
|
68
|
-
:class="
|
|
80
|
+
:class="passwordErrorText && 'clr-error'"
|
|
69
81
|
>
|
|
70
82
|
<div class="flex-align-center input-action-wrapper">
|
|
71
83
|
<input
|
|
72
84
|
id="configuration-folder-input"
|
|
73
|
-
v-model="
|
|
85
|
+
v-model="model.password"
|
|
74
86
|
data-id="configuration-folder-input"
|
|
75
|
-
type="
|
|
87
|
+
type="password"
|
|
88
|
+
autocomplete="new-password"
|
|
76
89
|
class="clr-input"
|
|
77
|
-
@blur="
|
|
78
|
-
@input="
|
|
90
|
+
@blur="onInitValidation(true, ['password'])"
|
|
91
|
+
@input="onInitValidation(false, ['password'])"
|
|
79
92
|
/>
|
|
80
93
|
<atoms-the-icon class="error-icon" name="info-circle" />
|
|
81
94
|
</div>
|
|
82
|
-
<div v-if="
|
|
83
|
-
{{
|
|
95
|
+
<div v-if="passwordErrorText" class="clr-subtext">
|
|
96
|
+
{{ passwordErrorText }}
|
|
84
97
|
</div>
|
|
85
98
|
<div v-else class="clr-subtext">Password</div>
|
|
86
99
|
</div>
|
|
@@ -100,156 +113,103 @@
|
|
|
100
113
|
</div>
|
|
101
114
|
|
|
102
115
|
<button
|
|
103
|
-
class="btn btn-primary btn-sm mt-2
|
|
104
|
-
:disabled="
|
|
116
|
+
class="btn btn-primary btn-sm mt-2"
|
|
117
|
+
:disabled="disabledSignInButton"
|
|
105
118
|
data-id="sign-in-button"
|
|
106
|
-
@click="
|
|
119
|
+
@click="onConnectServer"
|
|
107
120
|
>
|
|
108
|
-
{{ localization.
|
|
121
|
+
{{ localization.auth.login }}
|
|
109
122
|
</button>
|
|
110
123
|
</div>
|
|
111
124
|
</template>
|
|
112
125
|
|
|
113
126
|
<script lang="ts" setup>
|
|
114
|
-
import type { UI_I_ValidationTouchResult } from '~/lib/models/plugins/validation/interfaces'
|
|
115
127
|
import type { UI_I_Localization } from '~/lib/models/interfaces'
|
|
116
|
-
import type {
|
|
117
|
-
import {
|
|
118
|
-
import {
|
|
128
|
+
import type { UI_T_AlertStatus } from '~/components/atoms/alert/lib/models/types'
|
|
129
|
+
import type { UI_I_InitialValidationFields } from '~/components/common/wizards/vm/migrate/select/targetServer/new/lib/models/interfaces'
|
|
130
|
+
import type { UI_I_ConnectEsxiServerForm } from '~/components/common/wizards/vm/migrate/select/targetServer/new/lib/models/interfaces'
|
|
131
|
+
import type Wizard from '~/components/atoms/wizard/lib/utils/utils'
|
|
119
132
|
|
|
120
133
|
const props = defineProps<{
|
|
121
|
-
|
|
134
|
+
wizard: Wizard
|
|
122
135
|
}>()
|
|
136
|
+
const model = defineModel<UI_I_ConnectEsxiServerForm>({ required: true })
|
|
137
|
+
const modelConnectServer = defineModel<boolean>('connectServer')
|
|
123
138
|
const localization = computed<UI_I_Localization>(() => useLocal())
|
|
124
|
-
const emits = defineEmits<{
|
|
125
|
-
(event: 'loading', value: boolean): void
|
|
126
|
-
(event: 'next', value: UI_I_TargetServerData): void
|
|
127
|
-
}>()
|
|
128
|
-
const { $validation } = useNuxtApp()
|
|
129
|
-
|
|
130
|
-
const validation = $validation.call({})
|
|
131
|
-
const defaultForm: UI_I_FormValidationTargetServer = defaultFormFunc(
|
|
132
|
-
localization.value
|
|
133
|
-
)
|
|
134
|
-
const form = ref<UI_I_FormValidationTargetServer>(useDeepCopy(defaultForm))
|
|
135
|
-
const setForm = (): void => {
|
|
136
|
-
form.value = useDeepCopy(defaultForm)
|
|
137
|
-
validation.setForm(form)
|
|
138
|
-
}
|
|
139
|
-
setForm()
|
|
140
|
-
|
|
141
|
-
const validForm = ref<UI_I_ValidationTouchResult | null>(null)
|
|
142
|
-
|
|
143
|
-
/* Validation for Name input */
|
|
144
|
-
const isInitNameValidation = ref<boolean>(false)
|
|
145
|
-
const onBlurInputName = (): void => {
|
|
146
|
-
validForm.value = validation.touch()
|
|
147
|
-
isInitNameValidation.value = true
|
|
148
|
-
}
|
|
149
|
-
const onInputName = (): void => {
|
|
150
|
-
validForm.value = validation.touch()
|
|
151
|
-
}
|
|
152
139
|
|
|
153
|
-
const
|
|
154
|
-
|
|
155
|
-
|
|
140
|
+
const initValidationFields = ref<UI_I_InitialValidationFields>({
|
|
141
|
+
address: false,
|
|
142
|
+
username: false,
|
|
143
|
+
password: false,
|
|
156
144
|
})
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
/* Validation for Folder input */
|
|
160
|
-
const isInitFolderValidation = ref<boolean>(false)
|
|
161
|
-
const onBlurInputFolder = (): void => {
|
|
162
|
-
validForm.value = validation.touch()
|
|
163
|
-
isInitFolderValidation.value = true
|
|
164
|
-
}
|
|
165
|
-
const onInputFolder = (): void => {
|
|
166
|
-
validForm.value = validation.touch()
|
|
145
|
+
const onInitValidation = (onlyBlur: boolean, types: string[]): void => {
|
|
146
|
+
onlyBlur && types.forEach((type) => (initValidationFields.value[type] = true))
|
|
167
147
|
}
|
|
168
148
|
|
|
169
|
-
const
|
|
170
|
-
if (!
|
|
171
|
-
return
|
|
149
|
+
const addressErrorText = computed<string>(() => {
|
|
150
|
+
if (!initValidationFields.value.address) return ''
|
|
151
|
+
return !model.value.fqdn ? localization.value.common.fieldRequired : ''
|
|
172
152
|
})
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
const
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
}
|
|
181
|
-
const onInputServer = (): void => {
|
|
182
|
-
validForm.value = validation.touch()
|
|
183
|
-
isInitServerValidation.value = true
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
const serverErrorText = computed<string>(() => {
|
|
187
|
-
// if (!isInitServerValidation.value || dataServers.value.length) return ''
|
|
188
|
-
if (!isInitServerValidation.value) return ''
|
|
189
|
-
return validForm.value?.errors?.server?.[0] || ''
|
|
153
|
+
const usernameErrorText = computed<string>(() => {
|
|
154
|
+
if (!initValidationFields.value.username) return ''
|
|
155
|
+
return !model.value.user ? localization.value.common.fieldRequired : ''
|
|
156
|
+
})
|
|
157
|
+
const passwordErrorText = computed<string>(() => {
|
|
158
|
+
if (!initValidationFields.value.password) return ''
|
|
159
|
+
return !model.value.password ? localization.value.common.fieldRequired : ''
|
|
190
160
|
})
|
|
191
161
|
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
162
|
+
const disabledSignInButton = computed<boolean>(() => {
|
|
163
|
+
const { fqdn, user, password } = model.value
|
|
164
|
+
return !(fqdn && user && password)
|
|
165
|
+
})
|
|
195
166
|
|
|
196
|
-
const
|
|
167
|
+
const alertStatus = ref<UI_T_AlertStatus>('alert-danger')
|
|
168
|
+
const alertErrors = ref<string[]>([])
|
|
197
169
|
|
|
198
|
-
const
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
errors.value = []
|
|
170
|
+
const showValidationErrors = (
|
|
171
|
+
data: string[],
|
|
172
|
+
status: UI_T_AlertStatus
|
|
173
|
+
): void => {
|
|
174
|
+
alertStatus.value = status
|
|
175
|
+
alertErrors.value = data
|
|
205
176
|
}
|
|
206
177
|
|
|
207
|
-
|
|
208
|
-
() => props.nfsConfigurationSubmit,
|
|
209
|
-
() => {
|
|
210
|
-
submit()
|
|
211
|
-
}
|
|
212
|
-
)
|
|
213
|
-
const submit = async (): Promise<void> => {
|
|
214
|
-
const { name, server, folder } = form.value
|
|
215
|
-
|
|
216
|
-
validForm.value = validation.touch()
|
|
217
|
-
isInitNameValidation.value =
|
|
218
|
-
isInitFolderValidation.value =
|
|
219
|
-
isInitServerValidation.value =
|
|
220
|
-
true
|
|
221
|
-
|
|
222
|
-
if (nameErrorText.value || folderErrorText.value || serverErrorText.value) {
|
|
223
|
-
return
|
|
224
|
-
}
|
|
225
|
-
|
|
226
|
-
emits('loading', true)
|
|
227
|
-
|
|
228
|
-
const { valid, msg } = await checkValidityName(name.value)
|
|
229
|
-
|
|
230
|
-
emits('loading', false)
|
|
231
|
-
|
|
232
|
-
if (!valid) {
|
|
233
|
-
showValidationErrors(msg)
|
|
234
|
-
return
|
|
235
|
-
}
|
|
236
|
-
|
|
237
|
-
resetValidation()
|
|
178
|
+
const accessMode = ref<boolean>(false)
|
|
238
179
|
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
180
|
+
const onConnectServer = async (): Promise<void> => {
|
|
181
|
+
try {
|
|
182
|
+
props.wizard.setLoader(true)
|
|
183
|
+
const payload: UI_I_ConnectEsxiServerForm = {
|
|
184
|
+
fqdn: model.value.fqdn,
|
|
185
|
+
user: model.value.user,
|
|
186
|
+
password: model.value.password,
|
|
187
|
+
}
|
|
188
|
+
console.log(payload)
|
|
189
|
+
// await $store.dispatch('vm/A_CONNECT_ESXI_SERVER', payload)
|
|
190
|
+
|
|
191
|
+
const alertText = localization.value.common.successfullyConnected.replace(
|
|
192
|
+
'{address}',
|
|
193
|
+
model.value.fqdn
|
|
194
|
+
)
|
|
195
|
+
|
|
196
|
+
showValidationErrors([alertText], 'alert-success')
|
|
197
|
+
modelConnectServer.value = true
|
|
198
|
+
} catch (error) {
|
|
199
|
+
modelConnectServer.value = false
|
|
200
|
+
showValidationErrors([error as string], 'alert-danger')
|
|
201
|
+
} finally {
|
|
202
|
+
props.wizard.setLoader(false)
|
|
243
203
|
}
|
|
244
|
-
|
|
245
|
-
emits('next', configurationData)
|
|
246
204
|
}
|
|
247
205
|
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
}
|
|
206
|
+
watch(
|
|
207
|
+
modelConnectServer,
|
|
208
|
+
(newValue: boolean | undefined) => {
|
|
209
|
+
props.wizard.setDisabledNextButton(!newValue)
|
|
210
|
+
},
|
|
211
|
+
{ immediate: true }
|
|
212
|
+
)
|
|
253
213
|
</script>
|
|
254
214
|
|
|
255
215
|
<style lang="scss" scoped>
|
|
@@ -259,6 +219,10 @@ const showValidationErrors = (errorText: string): void => {
|
|
|
259
219
|
height: 100%;
|
|
260
220
|
margin-top: 25px;
|
|
261
221
|
|
|
222
|
+
&__alert {
|
|
223
|
+
margin: 0 0 10px;
|
|
224
|
+
}
|
|
225
|
+
|
|
262
226
|
.clr-form-control {
|
|
263
227
|
margin-top: 0;
|
|
264
228
|
display: flex;
|
|
@@ -282,6 +246,9 @@ const showValidationErrors = (errorText: string): void => {
|
|
|
282
246
|
}
|
|
283
247
|
}
|
|
284
248
|
}
|
|
249
|
+
button.btn-sm {
|
|
250
|
+
max-width: 20%;
|
|
251
|
+
}
|
|
285
252
|
}
|
|
286
253
|
.flex-align-center {
|
|
287
254
|
&.input-action-wrapper {
|
package/components/common/wizards/vm/migrate/select/targetServer/new/lib/models/interfaces.ts
CHANGED
|
@@ -1,13 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
folder: UI_I_Validation
|
|
6
|
-
server: UI_I_Validation
|
|
1
|
+
export interface UI_I_InitialValidationFields {
|
|
2
|
+
address: boolean
|
|
3
|
+
username: boolean
|
|
4
|
+
password: boolean
|
|
7
5
|
}
|
|
8
6
|
|
|
9
|
-
export interface
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
7
|
+
export interface UI_I_ConnectEsxiServerForm {
|
|
8
|
+
fqdn: string
|
|
9
|
+
user: string
|
|
10
|
+
password: string
|
|
13
11
|
}
|
|
@@ -14,18 +14,28 @@
|
|
|
14
14
|
|
|
15
15
|
<common-wizards-vm-migrate-select-target-server-new
|
|
16
16
|
v-if="activeTab === 'new-server'"
|
|
17
|
+
v-model="modelTargetServer"
|
|
18
|
+
v-model:connect-server="modelConnectServer"
|
|
19
|
+
:wizard="props.wizard"
|
|
17
20
|
/>
|
|
18
21
|
</div>
|
|
19
22
|
</template>
|
|
20
23
|
|
|
21
24
|
<script lang="ts" setup>
|
|
25
|
+
import type Wizard from '~/components/atoms/wizard/lib/utils/utils'
|
|
22
26
|
import type { UI_I_Localization } from '~/lib/models/interfaces'
|
|
23
27
|
import type { UI_I_CollapseNavItem } from '~/components/atoms/collapse/lib/models/interfaces'
|
|
28
|
+
import type { UI_I_ConnectEsxiServerForm } from '~/components/common/wizards/vm/migrate/select/targetServer/new/lib/models/interfaces'
|
|
24
29
|
import type { T_SelectTargetServerTab } from '~/components/common/wizards/vm/migrate/select/targetServer/lib/models/types'
|
|
25
30
|
import { vmMigrateSelectTargetServerTabsFunc } from '~/components/common/wizards/vm/migrate/select/targetServer/lib/config/tabsPannel'
|
|
26
31
|
|
|
27
|
-
const
|
|
32
|
+
const props = defineProps<{
|
|
33
|
+
wizard: Wizard
|
|
34
|
+
}>()
|
|
35
|
+
const modelTargetServer = defineModel<UI_I_ConnectEsxiServerForm>()
|
|
36
|
+
const modelConnectServer = defineModel<boolean>('connectServer')
|
|
28
37
|
|
|
38
|
+
const localization = computed<UI_I_Localization>(() => useLocal())
|
|
29
39
|
const activeTab = ref<T_SelectTargetServerTab>('new-server')
|
|
30
40
|
const selectStorageTabs = computed<UI_I_CollapseNavItem[]>(() =>
|
|
31
41
|
vmMigrateSelectTargetServerTabsFunc(localization.value)
|
|
@@ -1,38 +1,27 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
/>
|
|
7
|
-
</div>
|
|
2
|
+
<common-select-radio-group
|
|
3
|
+
v-model="selectedMigrateTypeLocal"
|
|
4
|
+
:options="vmMigrationTypes"
|
|
5
|
+
/>
|
|
8
6
|
</template>
|
|
9
7
|
|
|
10
8
|
<script lang="ts" setup>
|
|
11
9
|
import type { UI_T_Project } from '~/lib/models/types'
|
|
12
10
|
import type { UI_I_VmMigrateTypeOption } from '~/components/common/wizards/vm/migrate/select/type/lib/models/interfaces'
|
|
11
|
+
import type { UI_T_VmMigrateType } from '~/components/common/wizards/vm/migrate/select/type/lib/models/types'
|
|
13
12
|
import { vmMigrateTypesFunc } from '~/components/common/wizards/vm/migrate/select/type/lib/config/typeOptions'
|
|
14
13
|
|
|
15
14
|
const props = defineProps<{
|
|
16
|
-
modelValue: string
|
|
17
15
|
project: UI_T_Project
|
|
18
16
|
}>()
|
|
19
|
-
const
|
|
20
|
-
|
|
21
|
-
}
|
|
17
|
+
const selectedMigrateTypeLocal = defineModel<UI_T_VmMigrateType>({
|
|
18
|
+
required: true,
|
|
19
|
+
})
|
|
22
20
|
const localization = computed<any>(() => useLocal())
|
|
23
21
|
|
|
24
22
|
const vmMigrationTypes = ref<UI_I_VmMigrateTypeOption[]>(
|
|
25
23
|
vmMigrateTypesFunc(localization.value, props.project)
|
|
26
24
|
)
|
|
27
|
-
|
|
28
|
-
const selectedType = computed<string>({
|
|
29
|
-
get() {
|
|
30
|
-
return props.modelValue
|
|
31
|
-
},
|
|
32
|
-
set(newValue) {
|
|
33
|
-
emits('update:model-value', newValue)
|
|
34
|
-
},
|
|
35
|
-
})
|
|
36
25
|
</script>
|
|
37
26
|
|
|
38
27
|
<style lang="scss" scoped></style>
|
package/package.json
CHANGED
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="content-heading">
|
|
3
|
-
<div>
|
|
4
|
-
<h2>{{ props.title }}</h2>
|
|
5
|
-
<p>{{ props.description }}</p>
|
|
6
|
-
</div>
|
|
7
|
-
<common-wizards-vm-common-tooltip
|
|
8
|
-
test-id="vm-origin-tooltip"
|
|
9
|
-
is-show-element
|
|
10
|
-
>
|
|
11
|
-
<template #content>
|
|
12
|
-
<div
|
|
13
|
-
v-for="(item, key) in contentTooltip"
|
|
14
|
-
:key="key"
|
|
15
|
-
class="content-heading__tooltip"
|
|
16
|
-
>
|
|
17
|
-
<h2>{{ item.name }}</h2>
|
|
18
|
-
<div
|
|
19
|
-
v-for="(node, index) in item.node"
|
|
20
|
-
:key="index"
|
|
21
|
-
class="content-heading__tooltip-wrapper"
|
|
22
|
-
>
|
|
23
|
-
<span :class="['icon', node.iconClassName]"></span>
|
|
24
|
-
<span>{{ node.name }}</span>
|
|
25
|
-
</div>
|
|
26
|
-
</div>
|
|
27
|
-
</template>
|
|
28
|
-
</common-wizards-vm-common-tooltip>
|
|
29
|
-
</div>
|
|
30
|
-
</template>
|
|
31
|
-
|
|
32
|
-
<script lang="ts" setup>
|
|
33
|
-
import type { UI_I_HeadlineTooltipContent } from '~/components/common/wizards/vm/migrate/contentHeading/lib/models/interfaces'
|
|
34
|
-
|
|
35
|
-
const props = defineProps<{
|
|
36
|
-
title: string
|
|
37
|
-
description: string
|
|
38
|
-
}>()
|
|
39
|
-
|
|
40
|
-
const contentTooltip = ref<UI_I_HeadlineTooltipContent[]>([
|
|
41
|
-
{
|
|
42
|
-
name: 'Host',
|
|
43
|
-
node: [
|
|
44
|
-
{
|
|
45
|
-
name: ' e0.vmw.aobfg.ru',
|
|
46
|
-
iconClassName: 'vsphere-icon-host',
|
|
47
|
-
},
|
|
48
|
-
],
|
|
49
|
-
},
|
|
50
|
-
{
|
|
51
|
-
name: 'Networks',
|
|
52
|
-
node: [
|
|
53
|
-
{
|
|
54
|
-
name: 'VM-VLAN101',
|
|
55
|
-
iconClassName: 'vsphere-icon-network',
|
|
56
|
-
},
|
|
57
|
-
],
|
|
58
|
-
},
|
|
59
|
-
{
|
|
60
|
-
name: 'Storage',
|
|
61
|
-
node: [
|
|
62
|
-
{
|
|
63
|
-
name: 'datastore1 (1)',
|
|
64
|
-
iconClassName: 'vsphere-icon-datastore',
|
|
65
|
-
},
|
|
66
|
-
],
|
|
67
|
-
},
|
|
68
|
-
])
|
|
69
|
-
</script>
|
|
70
|
-
|
|
71
|
-
<style lang="scss" scoped>
|
|
72
|
-
@import 'assets/scss/common/mixins.scss';
|
|
73
|
-
.content-heading {
|
|
74
|
-
display: flex;
|
|
75
|
-
justify-content: space-between;
|
|
76
|
-
align-items: flex-start;
|
|
77
|
-
padding: 0 15px 13px 0;
|
|
78
|
-
border-bottom: 1px solid #a6a6a6;
|
|
79
|
-
& > div h2 {
|
|
80
|
-
font-weight: 700;
|
|
81
|
-
font-size: 13px;
|
|
82
|
-
line-height: normal;
|
|
83
|
-
color: var(--add-vm-context-sub-title);
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
&__tooltip {
|
|
87
|
-
& > h2 {
|
|
88
|
-
font-weight: 700;
|
|
89
|
-
line-height: normal;
|
|
90
|
-
margin-bottom: 2px;
|
|
91
|
-
}
|
|
92
|
-
&-wrapper {
|
|
93
|
-
@include flex($align: center);
|
|
94
|
-
}
|
|
95
|
-
.icon {
|
|
96
|
-
display: block;
|
|
97
|
-
width: 13px;
|
|
98
|
-
height: 13px;
|
|
99
|
-
margin-right: 10px;
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
}
|
|
103
|
-
:deep(.signpost) {
|
|
104
|
-
min-width: 300px;
|
|
105
|
-
}
|
|
106
|
-
</style>
|
|
@@ -1,69 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<section class="disk-format clr-flex-row">
|
|
3
|
-
<label
|
|
4
|
-
for="storage-locator-disk-format-label"
|
|
5
|
-
class="clr-col-3 clr-control-label"
|
|
6
|
-
>
|
|
7
|
-
{{ localization.common.selectVirtualDiskFormat }}
|
|
8
|
-
</label>
|
|
9
|
-
<div class="select select-lang mt-0 clr-form-control">
|
|
10
|
-
<select
|
|
11
|
-
id="storage-locator-disk-format-label"
|
|
12
|
-
v-model="selectedVirtualDiskFormat"
|
|
13
|
-
data-id="storage-locator-disk-format-select"
|
|
14
|
-
class="storage-locator-disk-format-label"
|
|
15
|
-
>
|
|
16
|
-
<option
|
|
17
|
-
v-for="option in configuredSpeedOptions"
|
|
18
|
-
:key="option.value"
|
|
19
|
-
:value="option.value"
|
|
20
|
-
>
|
|
21
|
-
{{ option.text }}
|
|
22
|
-
</option>
|
|
23
|
-
</select>
|
|
24
|
-
</div>
|
|
25
|
-
</section>
|
|
26
|
-
</template>
|
|
27
|
-
|
|
28
|
-
<script lang="ts" setup>
|
|
29
|
-
import type { UI_I_Localization } from '~/lib/models/interfaces'
|
|
30
|
-
import type { UI_I_OptionItem } from '~/components/atoms/lib/models/interfaces'
|
|
31
|
-
import { vmDiskFormatOptions } from '~/components/common/wizards/vm/migrate/select/storage/diskFormat/lib/config/formatOptions'
|
|
32
|
-
|
|
33
|
-
const props = defineProps<{
|
|
34
|
-
vmDiskFormat: number
|
|
35
|
-
}>()
|
|
36
|
-
const emits = defineEmits<{
|
|
37
|
-
(event: 'update:vm-disk-format', value: number): void
|
|
38
|
-
}>()
|
|
39
|
-
|
|
40
|
-
const localization = computed<UI_I_Localization>(() => useLocal())
|
|
41
|
-
|
|
42
|
-
const configuredSpeedOptions = computed<UI_I_OptionItem[]>(() =>
|
|
43
|
-
vmDiskFormatOptions()
|
|
44
|
-
)
|
|
45
|
-
|
|
46
|
-
const selectedVirtualDiskFormat = computed<number>({
|
|
47
|
-
get() {
|
|
48
|
-
return props.vmDiskFormat
|
|
49
|
-
},
|
|
50
|
-
set(newValue: number) {
|
|
51
|
-
emits('update:vm-disk-format', newValue)
|
|
52
|
-
},
|
|
53
|
-
})
|
|
54
|
-
</script>
|
|
55
|
-
|
|
56
|
-
<style lang="scss" scoped>
|
|
57
|
-
@import 'assets/scss/common/mixins.scss';
|
|
58
|
-
.disk-format {
|
|
59
|
-
@include flex($align: center);
|
|
60
|
-
}
|
|
61
|
-
.select-lang {
|
|
62
|
-
margin-left: 25px;
|
|
63
|
-
height: 24px;
|
|
64
|
-
min-width: 210px;
|
|
65
|
-
& > select {
|
|
66
|
-
height: 100%;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
</style>
|