bfg-common 1.5.154 → 1.5.155
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/browse/blocks/lib/models/types.ts +1 -1
- package/components/common/browse/lib/models/interfaces.ts +5 -5
- package/components/common/diagramMain/adapter/AdapterItems.vue +61 -61
- package/components/common/diagramMain/lib/config/initial.ts +50 -50
- package/components/common/diagramMain/lib/models/types.ts +21 -21
- package/components/common/diagramMain/lib/utils/utils.ts +331 -331
- package/components/common/diagramMain/modals/editSettings/ConfirmTeamingSettingsModal.vue +40 -40
- package/components/common/diagramMain/modals/editSettings/tabs/NetworkProperties.vue +214 -214
- package/components/common/diagramMain/modals/editSettings/tabs/Security.vue +189 -189
- package/components/common/diagramMain/modals/editSettings/tabs/SwitchProperties.vue +163 -163
- package/components/common/diagramMain/modals/editSettings/tabs/TeamingFailover.vue +175 -175
- package/components/common/diagramMain/modals/editSettings/tabs/port/IpvFourSettings.vue +346 -346
- package/components/common/diagramMain/modals/editSettings/tabs/port/PortProperties.vue +205 -205
- package/components/common/diagramMain/modals/lib/config/initial.ts +180 -180
- package/components/common/diagramMain/modals/lib/config/vmKernelAdapter.ts +90 -90
- package/components/common/diagramMain/modals/lib/mappers/mappers.ts +87 -87
- package/components/common/diagramMain/modals/lib/utils/index.ts +24 -24
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/lib/config/steps.ts +114 -114
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/steps/ConnectionSettings.vue +169 -169
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/steps/SelectVmkernelAdapter.vue +159 -159
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/common.ts +14 -14
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/connectionSettings.ts +137 -137
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/selectVmkernelAdapter.ts +52 -52
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/validations.ts +19 -19
- package/components/common/diagramMain/port/Ports.vue +47 -47
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/NewHardDisk.vue +1 -2
- package/components/common/wizards/vm/migrate/Migrate.vue +344 -343
- package/components/common/wizards/vm/migrate/select/computeResource/ComputeResource.vue +190 -188
- package/components/common/wizards/vm/migrate/select/computeResource/lib/config/tabsPannel.ts +39 -29
- package/package.json +1 -1
|
@@ -1,205 +1,205 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="wizard-content__container">
|
|
3
|
-
<div class="wizard-content wizard-content-port">
|
|
4
|
-
<atoms-alert
|
|
5
|
-
v-if="isShowErrorMessage"
|
|
6
|
-
status="alert-danger"
|
|
7
|
-
:items="validationMessagesArray"
|
|
8
|
-
test-id="port-properties-alert"
|
|
9
|
-
@remove="onHideErrorMessageAlert"
|
|
10
|
-
/>
|
|
11
|
-
<form id="port-properties-form">
|
|
12
|
-
<b class="property-label-group">
|
|
13
|
-
{{ localization.common.vmKernelPortSettings }}
|
|
14
|
-
</b>
|
|
15
|
-
<div class="horizontal-flex-container">
|
|
16
|
-
<label class="property-label-group">
|
|
17
|
-
{{ localization.common.tcpIpStack }}
|
|
18
|
-
</label>
|
|
19
|
-
<div class="margin-left-property-value-group">
|
|
20
|
-
<div class="property-value-group">
|
|
21
|
-
{{ localization.common[fieldsValues.tcpIp] }}
|
|
22
|
-
</div>
|
|
23
|
-
</div>
|
|
24
|
-
</div>
|
|
25
|
-
<div class="horizontal-flex-container">
|
|
26
|
-
<label class="property-label-group">
|
|
27
|
-
{{ localization.common.mtu }}
|
|
28
|
-
</label>
|
|
29
|
-
<div class="margin-left-property-value-group">
|
|
30
|
-
<div class="property-value-group tooltip-field-container">
|
|
31
|
-
<atoms-tooltip-error :has-error="!!props.errorMessages.mtu">
|
|
32
|
-
<template #elem>
|
|
33
|
-
<input
|
|
34
|
-
id="mtu"
|
|
35
|
-
v-model="fieldsValues.mtu"
|
|
36
|
-
data-id="mtu-input"
|
|
37
|
-
type="number"
|
|
38
|
-
name="mtu"
|
|
39
|
-
:class="[
|
|
40
|
-
'tooltip-field',
|
|
41
|
-
{
|
|
42
|
-
'danger-not-valid': props.errorMessages.mtu,
|
|
43
|
-
},
|
|
44
|
-
]"
|
|
45
|
-
@click.stop
|
|
46
|
-
/>
|
|
47
|
-
</template>
|
|
48
|
-
<template #content>
|
|
49
|
-
{{ props.errorMessages.mtu }}
|
|
50
|
-
</template>
|
|
51
|
-
</atoms-tooltip-error>
|
|
52
|
-
</div>
|
|
53
|
-
</div>
|
|
54
|
-
</div>
|
|
55
|
-
|
|
56
|
-
<div class="edit-vmkernel-adapter-section">
|
|
57
|
-
<b class="property-label-group">
|
|
58
|
-
{{ localization.common.availableServices }}
|
|
59
|
-
</b>
|
|
60
|
-
<template
|
|
61
|
-
v-for="(enabledService, key) in portPropertiesEnabledServices"
|
|
62
|
-
:key="enabledService.modelValue"
|
|
63
|
-
>
|
|
64
|
-
<div class="horizontal-flex-container">
|
|
65
|
-
<label class="property-label-group">
|
|
66
|
-
{{ enabledService.mainLabel }}
|
|
67
|
-
</label>
|
|
68
|
-
<div class="margin-left-property-value-group">
|
|
69
|
-
<div class="property-value-group tooltip-field-container">
|
|
70
|
-
<label>
|
|
71
|
-
<input
|
|
72
|
-
:id="`property-value-group-${key}`"
|
|
73
|
-
v-model="fieldsValues.services[enabledService.modelValue]"
|
|
74
|
-
:data-id="enabledService.testId"
|
|
75
|
-
type="checkbox"
|
|
76
|
-
/>
|
|
77
|
-
{{ enabledService.label }}
|
|
78
|
-
</label>
|
|
79
|
-
</div>
|
|
80
|
-
</div>
|
|
81
|
-
</div>
|
|
82
|
-
</template>
|
|
83
|
-
</div>
|
|
84
|
-
</form>
|
|
85
|
-
</div>
|
|
86
|
-
</div>
|
|
87
|
-
</template>
|
|
88
|
-
|
|
89
|
-
<script setup lang="ts">
|
|
90
|
-
import type { UI_I_Localization } from '~/lib/models/interfaces'
|
|
91
|
-
import {
|
|
92
|
-
UI_I_PortPropertiesFields,
|
|
93
|
-
UI_I_ModalsInitialData,
|
|
94
|
-
UI_I_EditSettingsErrorMessage,
|
|
95
|
-
} from '~/components/common/diagramMain/lib/models/interfaces'
|
|
96
|
-
import type { UI_T_PortPropertiesFieldName } from '~/components/common/diagramMain/lib/models/types'
|
|
97
|
-
import { portPropertiesEnabledServicesFunc } from '~/components/common/diagramMain/modals/lib/config'
|
|
98
|
-
import { validationMessagesArrayFunc } from '~/components/common/diagramMain/modals/lib/utils'
|
|
99
|
-
|
|
100
|
-
// Props from up
|
|
101
|
-
const props = withDefaults(
|
|
102
|
-
defineProps<{
|
|
103
|
-
isShowErrorMessageAlert: boolean
|
|
104
|
-
initialData?: UI_I_ModalsInitialData
|
|
105
|
-
errorMessages: UI_I_EditSettingsErrorMessage
|
|
106
|
-
hasErrorMessages?: boolean
|
|
107
|
-
}>(),
|
|
108
|
-
{
|
|
109
|
-
initialData: () => ({}),
|
|
110
|
-
}
|
|
111
|
-
)
|
|
112
|
-
|
|
113
|
-
const validationMessagesArray = computed(() =>
|
|
114
|
-
validationMessagesArrayFunc(['mtu'], props.errorMessages)
|
|
115
|
-
)
|
|
116
|
-
|
|
117
|
-
// UI_I_Localization
|
|
118
|
-
const localization = computed<UI_I_Localization>(() => useLocal())
|
|
119
|
-
|
|
120
|
-
// Enabled services data with localization
|
|
121
|
-
const portPropertiesEnabledServices = computed(() =>
|
|
122
|
-
portPropertiesEnabledServicesFunc(localization.value)
|
|
123
|
-
)
|
|
124
|
-
|
|
125
|
-
// For showing component validation errors on the top of modal
|
|
126
|
-
const isShowErrorMessage = computed<boolean>(
|
|
127
|
-
() => props.isShowErrorMessageAlert && props.hasErrorMessages
|
|
128
|
-
)
|
|
129
|
-
|
|
130
|
-
const fieldsValues = ref<UI_I_PortPropertiesFields>(
|
|
131
|
-
useDeepCopy({
|
|
132
|
-
tcpIp: props.initialData.tcpIp,
|
|
133
|
-
mtu: props.initialData.mtu,
|
|
134
|
-
services: props.initialData.services,
|
|
135
|
-
}) as UI_I_PortPropertiesFields
|
|
136
|
-
)
|
|
137
|
-
|
|
138
|
-
// Validation
|
|
139
|
-
const emits = defineEmits<{
|
|
140
|
-
(
|
|
141
|
-
event: 'change-error-messages',
|
|
142
|
-
errorMessage: string,
|
|
143
|
-
fieldName: keyof UI_I_EditSettingsErrorMessage
|
|
144
|
-
): void
|
|
145
|
-
(event: 'hide-error-message-alert'): void
|
|
146
|
-
(
|
|
147
|
-
event: 'change-port-edit-properties-data',
|
|
148
|
-
newPortEditPropertiesData: UI_I_PortPropertiesFields
|
|
149
|
-
): void
|
|
150
|
-
}>()
|
|
151
|
-
|
|
152
|
-
const onHideErrorMessageAlert = (): void => emits('hide-error-message-alert')
|
|
153
|
-
|
|
154
|
-
const onChangeData = (data: UI_I_PortPropertiesFields): void =>
|
|
155
|
-
emits('change-port-edit-properties-data', data)
|
|
156
|
-
|
|
157
|
-
const changeErrorMessage = (
|
|
158
|
-
errorMessage: string,
|
|
159
|
-
fieldName: keyof UI_I_EditSettingsErrorMessage
|
|
160
|
-
) => emits('change-error-messages', errorMessage, fieldName)
|
|
161
|
-
|
|
162
|
-
const messageTexts = (local: UI_I_Localization) => ({
|
|
163
|
-
mtu: local.mtuInvalidError,
|
|
164
|
-
})
|
|
165
|
-
|
|
166
|
-
const setMessageOnChangedField = (
|
|
167
|
-
values: number[],
|
|
168
|
-
index: number,
|
|
169
|
-
name: UI_T_PortPropertiesFieldName,
|
|
170
|
-
text: string
|
|
171
|
-
) => {
|
|
172
|
-
if (values[index] >= 1280 && values[index] <= 65535) {
|
|
173
|
-
changeErrorMessage('', name)
|
|
174
|
-
} else {
|
|
175
|
-
changeErrorMessage(text, name)
|
|
176
|
-
}
|
|
177
|
-
}
|
|
178
|
-
|
|
179
|
-
watch(
|
|
180
|
-
fieldsValues,
|
|
181
|
-
(newValues: UI_I_PortPropertiesFields): void => {
|
|
182
|
-
setMessageOnChangedField(
|
|
183
|
-
[newValues.mtu],
|
|
184
|
-
0,
|
|
185
|
-
'mtu',
|
|
186
|
-
messageTexts(localization.value).mtu
|
|
187
|
-
)
|
|
188
|
-
onChangeData(newValues)
|
|
189
|
-
!props.hasErrorMessages && onHideErrorMessageAlert()
|
|
190
|
-
},
|
|
191
|
-
{
|
|
192
|
-
deep: true,
|
|
193
|
-
}
|
|
194
|
-
)
|
|
195
|
-
|
|
196
|
-
onMounted(() => {
|
|
197
|
-
onChangeData(fieldsValues.value)
|
|
198
|
-
})
|
|
199
|
-
|
|
200
|
-
onUnmounted((): void => {
|
|
201
|
-
onHideErrorMessageAlert()
|
|
202
|
-
})
|
|
203
|
-
</script>
|
|
204
|
-
|
|
205
|
-
<style scoped lang="scss"></style>
|
|
1
|
+
<template>
|
|
2
|
+
<div class="wizard-content__container">
|
|
3
|
+
<div class="wizard-content wizard-content-port">
|
|
4
|
+
<atoms-alert
|
|
5
|
+
v-if="isShowErrorMessage"
|
|
6
|
+
status="alert-danger"
|
|
7
|
+
:items="validationMessagesArray"
|
|
8
|
+
test-id="port-properties-alert"
|
|
9
|
+
@remove="onHideErrorMessageAlert"
|
|
10
|
+
/>
|
|
11
|
+
<form id="port-properties-form">
|
|
12
|
+
<b class="property-label-group">
|
|
13
|
+
{{ localization.common.vmKernelPortSettings }}
|
|
14
|
+
</b>
|
|
15
|
+
<div class="horizontal-flex-container">
|
|
16
|
+
<label class="property-label-group">
|
|
17
|
+
{{ localization.common.tcpIpStack }}
|
|
18
|
+
</label>
|
|
19
|
+
<div class="margin-left-property-value-group">
|
|
20
|
+
<div class="property-value-group">
|
|
21
|
+
{{ localization.common[fieldsValues.tcpIp] }}
|
|
22
|
+
</div>
|
|
23
|
+
</div>
|
|
24
|
+
</div>
|
|
25
|
+
<div class="horizontal-flex-container">
|
|
26
|
+
<label class="property-label-group">
|
|
27
|
+
{{ localization.common.mtu }}
|
|
28
|
+
</label>
|
|
29
|
+
<div class="margin-left-property-value-group">
|
|
30
|
+
<div class="property-value-group tooltip-field-container">
|
|
31
|
+
<atoms-tooltip-error :has-error="!!props.errorMessages.mtu">
|
|
32
|
+
<template #elem>
|
|
33
|
+
<input
|
|
34
|
+
id="mtu"
|
|
35
|
+
v-model="fieldsValues.mtu"
|
|
36
|
+
data-id="mtu-input"
|
|
37
|
+
type="number"
|
|
38
|
+
name="mtu"
|
|
39
|
+
:class="[
|
|
40
|
+
'tooltip-field',
|
|
41
|
+
{
|
|
42
|
+
'danger-not-valid': props.errorMessages.mtu,
|
|
43
|
+
},
|
|
44
|
+
]"
|
|
45
|
+
@click.stop
|
|
46
|
+
/>
|
|
47
|
+
</template>
|
|
48
|
+
<template #content>
|
|
49
|
+
{{ props.errorMessages.mtu }}
|
|
50
|
+
</template>
|
|
51
|
+
</atoms-tooltip-error>
|
|
52
|
+
</div>
|
|
53
|
+
</div>
|
|
54
|
+
</div>
|
|
55
|
+
|
|
56
|
+
<div class="edit-vmkernel-adapter-section">
|
|
57
|
+
<b class="property-label-group">
|
|
58
|
+
{{ localization.common.availableServices }}
|
|
59
|
+
</b>
|
|
60
|
+
<template
|
|
61
|
+
v-for="(enabledService, key) in portPropertiesEnabledServices"
|
|
62
|
+
:key="enabledService.modelValue"
|
|
63
|
+
>
|
|
64
|
+
<div class="horizontal-flex-container">
|
|
65
|
+
<label class="property-label-group">
|
|
66
|
+
{{ enabledService.mainLabel }}
|
|
67
|
+
</label>
|
|
68
|
+
<div class="margin-left-property-value-group">
|
|
69
|
+
<div class="property-value-group tooltip-field-container">
|
|
70
|
+
<label>
|
|
71
|
+
<input
|
|
72
|
+
:id="`property-value-group-${key}`"
|
|
73
|
+
v-model="fieldsValues.services[enabledService.modelValue]"
|
|
74
|
+
:data-id="enabledService.testId"
|
|
75
|
+
type="checkbox"
|
|
76
|
+
/>
|
|
77
|
+
{{ enabledService.label }}
|
|
78
|
+
</label>
|
|
79
|
+
</div>
|
|
80
|
+
</div>
|
|
81
|
+
</div>
|
|
82
|
+
</template>
|
|
83
|
+
</div>
|
|
84
|
+
</form>
|
|
85
|
+
</div>
|
|
86
|
+
</div>
|
|
87
|
+
</template>
|
|
88
|
+
|
|
89
|
+
<script setup lang="ts">
|
|
90
|
+
import type { UI_I_Localization } from '~/lib/models/interfaces'
|
|
91
|
+
import {
|
|
92
|
+
UI_I_PortPropertiesFields,
|
|
93
|
+
UI_I_ModalsInitialData,
|
|
94
|
+
UI_I_EditSettingsErrorMessage,
|
|
95
|
+
} from '~/components/common/diagramMain/lib/models/interfaces'
|
|
96
|
+
import type { UI_T_PortPropertiesFieldName } from '~/components/common/diagramMain/lib/models/types'
|
|
97
|
+
import { portPropertiesEnabledServicesFunc } from '~/components/common/diagramMain/modals/lib/config'
|
|
98
|
+
import { validationMessagesArrayFunc } from '~/components/common/diagramMain/modals/lib/utils'
|
|
99
|
+
|
|
100
|
+
// Props from up
|
|
101
|
+
const props = withDefaults(
|
|
102
|
+
defineProps<{
|
|
103
|
+
isShowErrorMessageAlert: boolean
|
|
104
|
+
initialData?: UI_I_ModalsInitialData
|
|
105
|
+
errorMessages: UI_I_EditSettingsErrorMessage
|
|
106
|
+
hasErrorMessages?: boolean
|
|
107
|
+
}>(),
|
|
108
|
+
{
|
|
109
|
+
initialData: () => ({}),
|
|
110
|
+
}
|
|
111
|
+
)
|
|
112
|
+
|
|
113
|
+
const validationMessagesArray = computed(() =>
|
|
114
|
+
validationMessagesArrayFunc(['mtu'], props.errorMessages)
|
|
115
|
+
)
|
|
116
|
+
|
|
117
|
+
// UI_I_Localization
|
|
118
|
+
const localization = computed<UI_I_Localization>(() => useLocal())
|
|
119
|
+
|
|
120
|
+
// Enabled services data with localization
|
|
121
|
+
const portPropertiesEnabledServices = computed(() =>
|
|
122
|
+
portPropertiesEnabledServicesFunc(localization.value)
|
|
123
|
+
)
|
|
124
|
+
|
|
125
|
+
// For showing component validation errors on the top of modal
|
|
126
|
+
const isShowErrorMessage = computed<boolean>(
|
|
127
|
+
() => props.isShowErrorMessageAlert && props.hasErrorMessages
|
|
128
|
+
)
|
|
129
|
+
|
|
130
|
+
const fieldsValues = ref<UI_I_PortPropertiesFields>(
|
|
131
|
+
useDeepCopy({
|
|
132
|
+
tcpIp: props.initialData.tcpIp,
|
|
133
|
+
mtu: props.initialData.mtu,
|
|
134
|
+
services: props.initialData.services,
|
|
135
|
+
}) as UI_I_PortPropertiesFields
|
|
136
|
+
)
|
|
137
|
+
|
|
138
|
+
// Validation
|
|
139
|
+
const emits = defineEmits<{
|
|
140
|
+
(
|
|
141
|
+
event: 'change-error-messages',
|
|
142
|
+
errorMessage: string,
|
|
143
|
+
fieldName: keyof UI_I_EditSettingsErrorMessage
|
|
144
|
+
): void
|
|
145
|
+
(event: 'hide-error-message-alert'): void
|
|
146
|
+
(
|
|
147
|
+
event: 'change-port-edit-properties-data',
|
|
148
|
+
newPortEditPropertiesData: UI_I_PortPropertiesFields
|
|
149
|
+
): void
|
|
150
|
+
}>()
|
|
151
|
+
|
|
152
|
+
const onHideErrorMessageAlert = (): void => emits('hide-error-message-alert')
|
|
153
|
+
|
|
154
|
+
const onChangeData = (data: UI_I_PortPropertiesFields): void =>
|
|
155
|
+
emits('change-port-edit-properties-data', data)
|
|
156
|
+
|
|
157
|
+
const changeErrorMessage = (
|
|
158
|
+
errorMessage: string,
|
|
159
|
+
fieldName: keyof UI_I_EditSettingsErrorMessage
|
|
160
|
+
) => emits('change-error-messages', errorMessage, fieldName)
|
|
161
|
+
|
|
162
|
+
const messageTexts = (local: UI_I_Localization) => ({
|
|
163
|
+
mtu: local.mtuInvalidError,
|
|
164
|
+
})
|
|
165
|
+
|
|
166
|
+
const setMessageOnChangedField = (
|
|
167
|
+
values: number[],
|
|
168
|
+
index: number,
|
|
169
|
+
name: UI_T_PortPropertiesFieldName,
|
|
170
|
+
text: string
|
|
171
|
+
) => {
|
|
172
|
+
if (values[index] >= 1280 && values[index] <= 65535) {
|
|
173
|
+
changeErrorMessage('', name)
|
|
174
|
+
} else {
|
|
175
|
+
changeErrorMessage(text, name)
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
watch(
|
|
180
|
+
fieldsValues,
|
|
181
|
+
(newValues: UI_I_PortPropertiesFields): void => {
|
|
182
|
+
setMessageOnChangedField(
|
|
183
|
+
[newValues.mtu],
|
|
184
|
+
0,
|
|
185
|
+
'mtu',
|
|
186
|
+
messageTexts(localization.value).mtu
|
|
187
|
+
)
|
|
188
|
+
onChangeData(newValues)
|
|
189
|
+
!props.hasErrorMessages && onHideErrorMessageAlert()
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
deep: true,
|
|
193
|
+
}
|
|
194
|
+
)
|
|
195
|
+
|
|
196
|
+
onMounted(() => {
|
|
197
|
+
onChangeData(fieldsValues.value)
|
|
198
|
+
})
|
|
199
|
+
|
|
200
|
+
onUnmounted((): void => {
|
|
201
|
+
onHideErrorMessageAlert()
|
|
202
|
+
})
|
|
203
|
+
</script>
|
|
204
|
+
|
|
205
|
+
<style scoped lang="scss"></style>
|