bfg-common 1.2.186 → 1.2.187
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/assets/localization/local_be.json +9 -2
- package/assets/localization/local_en.json +9 -2
- package/assets/localization/local_hy.json +9 -2
- package/assets/localization/local_kk.json +9 -2
- package/assets/localization/local_ru.json +9 -2
- package/assets/localization/local_zh.json +9 -2
- package/assets/scss/common/theme.scss +27 -25
- package/components/atoms/table/simpleTable/SimpleTable.vue +5 -2
- package/components/atoms/wizard/Wizard.vue +4 -4
- package/components/atoms/wizard/models/interfaces.ts +4 -3
- package/components/atoms/wizard/utils/utils.ts +106 -27
- package/components/common/diagramMain/DiagramMain.vue +10 -46
- package/components/common/diagramMain/modals/config/index.ts +0 -6
- package/components/common/diagramMain/modals/config/vmKernelAdapter.ts +2 -2
- package/components/common/diagramMain/modals/editSettings/tabs/NetworkProperties.vue +1 -1
- package/components/common/diagramMain/modals/editSettings/tabs/port/IpvFourSettings.vue +339 -339
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/MigrateVmkernelAdapter.vue +531 -0
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/config/steps.ts +114 -0
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/steps/ConnectionSettings.vue +161 -0
- package/components/common/diagramMain/modals/{steps → migrateVmkernelAdapter/steps}/SelectVmkernelAdapter.vue +24 -86
- package/components/common/diagramMain/modals/{steps → migrateVmkernelAdapter/steps}/VmkernelAdapterReadyComplete.vue +7 -11
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/common.ts +47 -0
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/connectionSettings.ts +146 -0
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/selectVmkernelAdapter.ts +54 -0
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/validations.ts +19 -0
- package/components/common/diagramMain/models/enums.ts +6 -7
- package/components/common/diagramMain/models/interfaces.ts +28 -29
- package/components/common/diagramMain/models/types.ts +0 -1
- package/components/common/monitor/advanced/Advanced.vue +5 -4
- package/components/common/wizards/network/add/Add.vue +874 -0
- package/components/common/{addNetworking → wizards/network/add}/config/index.ts +2 -16
- package/components/common/{addNetworking → wizards/network/add}/config/initialData.ts +4 -19
- package/components/common/{addNetworking → wizards/network/add}/config/portPropertiesStep.ts +1 -1
- package/components/common/{addNetworking → wizards/network/add}/config/selectSwitch.ts +1 -1
- package/components/common/{addNetworking → wizards/network/add}/config/sendData.ts +1 -1
- package/components/common/{addNetworking/config/addNetworkingSteps.ts → wizards/network/add/config/steps.ts} +107 -60
- package/components/common/{addNetworking → wizards/network/add}/modals/SelectNetwork.vue +2 -2
- package/components/common/{addNetworking → wizards/network/add}/modals/SelectStandardSwitch.vue +2 -2
- package/components/common/{addNetworking → wizards/network/add}/modals/SelectSwitch.vue +2 -2
- package/components/common/wizards/network/add/models/enums.ts +17 -0
- package/components/common/{addNetworking → wizards/network/add}/models/interfaces.ts +30 -37
- package/components/common/wizards/network/add/models/types.ts +2 -0
- package/components/common/wizards/network/add/steps/ConnectionSettings.vue +148 -0
- package/components/common/{addNetworking → wizards/network/add}/steps/CreateStandardSwitch.vue +0 -7
- package/components/common/wizards/network/add/steps/IpFourSettings.vue +245 -0
- package/components/common/{addNetworking → wizards/network/add}/steps/PhysicalAdapter.vue +1 -12
- package/components/common/{addNetworking → wizards/network/add}/steps/PortProperties.vue +57 -180
- package/components/common/{addNetworking → wizards/network/add}/steps/ReadyComplete.vue +1 -10
- package/components/common/{addNetworking → wizards/network/add}/steps/SelectConnectionType.vue +3 -15
- package/components/common/{addNetworking → wizards/network/add}/steps/SelectedTargetDevice.vue +103 -209
- package/components/common/wizards/network/add/utils/index.ts +4 -0
- package/components/common/wizards/network/add/validations/common.ts +58 -0
- package/components/common/wizards/network/add/validations/connectionSettings.ts +75 -0
- package/components/common/wizards/network/add/validations/createStandardSwitch.ts +58 -0
- package/components/common/wizards/network/add/validations/ipFourSettings.ts +188 -0
- package/components/common/wizards/network/add/validations/networkValidation.ts +73 -0
- package/components/common/wizards/network/add/validations/portProperties.ts +87 -0
- package/components/common/wizards/network/add/validations/targetDevice.ts +113 -0
- package/components/common/wizards/network/add/validations/validations.ts +43 -0
- package/components/common/wizards/vm/migrate/select/computeResource/ComputeResource.vue +2 -0
- package/package.json +1 -1
- package/components/common/addNetworking/AddNetworking.vue +0 -1123
- package/components/common/addNetworking/Wizard.vue +0 -286
- package/components/common/addNetworking/config/temporaryData.ts +0 -8
- package/components/common/addNetworking/config/validation.ts +0 -23
- package/components/common/addNetworking/models/enums.ts +0 -7
- package/components/common/addNetworking/models/types.ts +0 -13
- package/components/common/addNetworking/steps/ConnectionSettings.vue +0 -269
- package/components/common/addNetworking/steps/Header.vue +0 -53
- package/components/common/addNetworking/steps/IpFourSettings.vue +0 -361
- package/components/common/addNetworking/utils/index.ts +0 -212
- package/components/common/diagramMain/modals/MigrateVmkernelAdapter.vue +0 -603
- package/components/common/diagramMain/modals/config/migrateVmkernelAdapterSteps.ts +0 -81
- package/components/common/diagramMain/modals/config/validation.ts +0 -3
- package/components/common/diagramMain/modals/steps/ConnectionSettings.vue +0 -221
- package/components/common/diagramMain/modals/steps/Header.vue +0 -60
- /package/components/common/{addNetworking → wizards/network/add}/mappers/mappers.ts +0 -0
|
@@ -1,15 +1,12 @@
|
|
|
1
|
-
import * as addNetworkingStepsConfig from './
|
|
1
|
+
import * as addNetworkingStepsConfig from './steps'
|
|
2
2
|
import * as initialData from './initialData'
|
|
3
|
-
import * as temporaryData from './temporaryData'
|
|
4
|
-
import * as validationData from './validation'
|
|
5
3
|
import * as portProperties from './portPropertiesStep'
|
|
6
4
|
import * as selectSwitches from './selectSwitch'
|
|
7
5
|
import * as sendData from './sendData'
|
|
8
6
|
|
|
9
7
|
export const {
|
|
10
8
|
stepsFunc,
|
|
11
|
-
|
|
12
|
-
secondTitleFunc,
|
|
9
|
+
stepsSchemeInitial,
|
|
13
10
|
createSecondSchemeReadyCompleteFunc,
|
|
14
11
|
createZeroSchemeReadyCompleteFunc,
|
|
15
12
|
createFirstSchemeReadyCompleteFunc,
|
|
@@ -22,18 +19,7 @@ export const {
|
|
|
22
19
|
portPropertiesInitial,
|
|
23
20
|
ipFourSettingsInitial,
|
|
24
21
|
connectionSettingsInitial,
|
|
25
|
-
errorMessagesInitialFunc,
|
|
26
|
-
isNetworkInvalidInitial,
|
|
27
|
-
isValidNetwork,
|
|
28
|
-
isInvalidNetwork,
|
|
29
22
|
} = initialData
|
|
30
|
-
export const { temporarySwitches, temporaryNetworks } = temporaryData
|
|
31
|
-
export const {
|
|
32
|
-
connectionSettingsFieldsErrorMessages,
|
|
33
|
-
ipFourSettingsFieldsErrorMessages,
|
|
34
|
-
portPropertiesFieldsErrorMessages,
|
|
35
|
-
targetDeviceFieldsErrorMessages,
|
|
36
|
-
} = validationData
|
|
37
23
|
export const { portPropertiesEnabledServicesFunc } = portProperties
|
|
38
24
|
export const {
|
|
39
25
|
selectStandardSwitchTableHeadFunc,
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
UI_I_ConnectionSettings,
|
|
3
|
-
UI_I_IpFourSettings,
|
|
3
|
+
UI_I_IpFourSettings,
|
|
4
|
+
UI_I_NetworkValidation,
|
|
4
5
|
UI_I_PortProperties,
|
|
5
6
|
UI_I_Services,
|
|
6
7
|
UI_I_TargetDevice,
|
|
7
8
|
UI_I_VlanIdData,
|
|
8
|
-
} from '~/components/common/
|
|
9
|
+
} from '~/components/common/wizards/network/add/models/interfaces'
|
|
9
10
|
|
|
10
11
|
export const servicesInitial: UI_I_Services = {
|
|
11
12
|
vMotion: false,
|
|
@@ -56,23 +57,7 @@ export const connectionSettingsInitial: UI_I_ConnectionSettings = {
|
|
|
56
57
|
vlanId: 'None (0)',
|
|
57
58
|
}
|
|
58
59
|
|
|
59
|
-
export const errorMessagesInitialFunc = (qty: number): string[][] =>
|
|
60
|
-
new Array(qty).fill([])
|
|
61
|
-
|
|
62
60
|
export const vlanIdSelectData: UI_I_VlanIdData[] = [
|
|
63
61
|
{ text: 'None (0)', value: 'None (0)' },
|
|
64
62
|
{ text: 'All (4095)', value: 'All (4095)' },
|
|
65
|
-
]
|
|
66
|
-
|
|
67
|
-
export const isNetworkInvalidInitial: UI_I_NetworkValidation = {
|
|
68
|
-
valid: false,
|
|
69
|
-
checked: false,
|
|
70
|
-
}
|
|
71
|
-
export const isValidNetwork: UI_I_NetworkValidation = {
|
|
72
|
-
valid: true,
|
|
73
|
-
checked: true,
|
|
74
|
-
}
|
|
75
|
-
export const isInvalidNetwork: UI_I_NetworkValidation = {
|
|
76
|
-
valid: false,
|
|
77
|
-
checked: true,
|
|
78
|
-
}
|
|
63
|
+
]
|
package/components/common/{addNetworking → wizards/network/add}/config/portPropertiesStep.ts
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { UI_I_Localization } from '~/models/interfaces'
|
|
2
|
-
import { UI_I_PortPropertiesEnabledService } from '~/components/common/
|
|
2
|
+
import { UI_I_PortPropertiesEnabledService } from '~/components/common/wizards/network/add/models/interfaces'
|
|
3
3
|
|
|
4
4
|
export const portPropertiesEnabledServicesFunc = (
|
|
5
5
|
localization: UI_I_Localization,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { UI_I_Localization } from '~/models/interfaces'
|
|
2
|
-
import { UI_I_TableHead } from '~/components/common/
|
|
2
|
+
import { UI_I_TableHead } from '~/components/common/wizards/network/add/models/interfaces'
|
|
3
3
|
|
|
4
4
|
export const selectNetworkTableHeadFunc = (
|
|
5
5
|
localization: UI_I_Localization
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
UI_I_PortProperties,
|
|
6
6
|
UI_I_TargetDevice,
|
|
7
7
|
UI_I_AddNetworkingSecondOrThirdSchemeDataSend,
|
|
8
|
-
} from '~/components/common/
|
|
8
|
+
} from '~/components/common/wizards/network/add/models/interfaces'
|
|
9
9
|
import { UI_I_AdapterStatus } from '~/components/common/diagramMain/models/interfaces'
|
|
10
10
|
|
|
11
11
|
export const addNetworkingSecondOrThirdSchemeDataFunc = (
|
|
@@ -5,96 +5,143 @@ import {
|
|
|
5
5
|
UI_I_PortProperties,
|
|
6
6
|
UI_I_ReadyCompleteData,
|
|
7
7
|
UI_I_ReadyCompleteFirstColumn,
|
|
8
|
-
UI_I_Step,
|
|
9
8
|
UI_I_TargetDevice,
|
|
10
|
-
} from '~/components/common/
|
|
9
|
+
} from '~/components/common/wizards/network/add/models/interfaces'
|
|
10
|
+
import { UI_E_ValidationFields } from '~/components/common/wizards/network/add/models/enums'
|
|
11
|
+
import { UI_I_WizardStep } from '~/components/atoms/wizard/models/interfaces'
|
|
12
|
+
import { UI_E_WIZARD_STATUS } from '~/components/atoms/wizard/models/enums'
|
|
11
13
|
|
|
12
|
-
export const stepsFunc = (
|
|
14
|
+
export const stepsFunc = (
|
|
15
|
+
localization: UI_I_Localization
|
|
16
|
+
): UI_I_WizardStep[] => [
|
|
13
17
|
{
|
|
14
18
|
id: 0,
|
|
15
|
-
|
|
16
|
-
|
|
19
|
+
title: localization.selectConnectionType,
|
|
20
|
+
subTitle: localization.selectConnectionTypeToCreate,
|
|
21
|
+
status: UI_E_WIZARD_STATUS.SELECTED,
|
|
22
|
+
fields: {},
|
|
23
|
+
isValid: true,
|
|
17
24
|
},
|
|
18
25
|
{
|
|
19
26
|
id: 1,
|
|
20
|
-
|
|
21
|
-
|
|
27
|
+
title: localization.selectTargetDevice,
|
|
28
|
+
subTitle: localization.selectTargetDeviceForNewConnection,
|
|
29
|
+
status: UI_E_WIZARD_STATUS.INACTIVE,
|
|
30
|
+
fields: {
|
|
31
|
+
[UI_E_ValidationFields.TARGET_DEVICE_STANDARD_SWITCH]: {
|
|
32
|
+
alert: '',
|
|
33
|
+
field: '',
|
|
34
|
+
},
|
|
35
|
+
[UI_E_ValidationFields.TARGET_DEVICE_NETWORK]: {
|
|
36
|
+
alert: '',
|
|
37
|
+
field: '',
|
|
38
|
+
},
|
|
39
|
+
[UI_E_ValidationFields.TARGET_DEVICE_SWITCH]: {
|
|
40
|
+
alert: '',
|
|
41
|
+
field: '',
|
|
42
|
+
},
|
|
43
|
+
[UI_E_ValidationFields.TARGET_DEVICE_MTU]: {
|
|
44
|
+
alert: '',
|
|
45
|
+
field: '',
|
|
46
|
+
},
|
|
47
|
+
},
|
|
48
|
+
isValid: true,
|
|
22
49
|
},
|
|
23
50
|
{
|
|
24
51
|
id: 2,
|
|
25
|
-
|
|
26
|
-
|
|
52
|
+
title: localization.createStandardSwitch,
|
|
53
|
+
subTitle: localization.assignFreePhysicalNetworkAdaptersToTheNewSwitch,
|
|
54
|
+
status: UI_E_WIZARD_STATUS.INACTIVE,
|
|
55
|
+
fields: {},
|
|
56
|
+
isValid: true,
|
|
27
57
|
},
|
|
28
58
|
{
|
|
29
59
|
id: 3,
|
|
30
|
-
|
|
31
|
-
|
|
60
|
+
title: localization.portProperties,
|
|
61
|
+
subTitle: localization.specifyVMkernelPortSettings,
|
|
62
|
+
status: UI_E_WIZARD_STATUS.INACTIVE,
|
|
63
|
+
fields: {
|
|
64
|
+
[UI_E_ValidationFields.PORT_PROPERTIES_NETWORK]: {
|
|
65
|
+
field: '',
|
|
66
|
+
alert: '',
|
|
67
|
+
},
|
|
68
|
+
[UI_E_ValidationFields.PORT_PROPERTIES_VLAN]: {
|
|
69
|
+
field: '',
|
|
70
|
+
alert: '',
|
|
71
|
+
},
|
|
72
|
+
[UI_E_ValidationFields.PORT_PROPERTIES_MTU]: {
|
|
73
|
+
field: '',
|
|
74
|
+
alert: '',
|
|
75
|
+
},
|
|
76
|
+
},
|
|
77
|
+
isValid: true,
|
|
32
78
|
},
|
|
33
79
|
{
|
|
34
80
|
id: 4,
|
|
35
|
-
|
|
36
|
-
|
|
81
|
+
title: localization.ipV4Settings,
|
|
82
|
+
subTitle: localization.specifyVMkernelIPv4Settings,
|
|
83
|
+
status: UI_E_WIZARD_STATUS.INACTIVE,
|
|
84
|
+
fields: {
|
|
85
|
+
[UI_E_ValidationFields.IPV_SETTINGS_IPV]: {
|
|
86
|
+
field: '',
|
|
87
|
+
alert: '',
|
|
88
|
+
},
|
|
89
|
+
[UI_E_ValidationFields.IPV_SETTINGS_MASK]: {
|
|
90
|
+
field: '',
|
|
91
|
+
alert: '',
|
|
92
|
+
},
|
|
93
|
+
[UI_E_ValidationFields.IPV_SETTINGS_GATEWAY]: {
|
|
94
|
+
field: '',
|
|
95
|
+
alert: '',
|
|
96
|
+
},
|
|
97
|
+
},
|
|
98
|
+
isValid: true,
|
|
37
99
|
},
|
|
38
100
|
{
|
|
39
101
|
id: 5,
|
|
40
|
-
|
|
41
|
-
|
|
102
|
+
title: localization.connectionSettings,
|
|
103
|
+
subTitle:
|
|
104
|
+
localization.useNetworkLabelsToIdentifyMigrationCompatibleTwoHosts,
|
|
105
|
+
status: UI_E_WIZARD_STATUS.INACTIVE,
|
|
106
|
+
fields: {
|
|
107
|
+
[UI_E_ValidationFields.CONNECTION_SETTINGS_NETWORK]: {
|
|
108
|
+
field: '',
|
|
109
|
+
alert: '',
|
|
110
|
+
},
|
|
111
|
+
[UI_E_ValidationFields.CONNECTION_SETTINGS_VLAN]: {
|
|
112
|
+
field: '',
|
|
113
|
+
alert: '',
|
|
114
|
+
},
|
|
115
|
+
},
|
|
116
|
+
isValid: true,
|
|
42
117
|
},
|
|
43
118
|
{
|
|
44
119
|
id: 6,
|
|
45
|
-
|
|
46
|
-
|
|
120
|
+
title: localization.addPhysicalNetworkAdapter,
|
|
121
|
+
subTitle: localization.assignPhysicalNetworkAdaptersToTheSwitch,
|
|
122
|
+
status: UI_E_WIZARD_STATUS.INACTIVE,
|
|
123
|
+
fields: {},
|
|
124
|
+
isValid: true,
|
|
47
125
|
},
|
|
48
126
|
{
|
|
49
127
|
id: 7,
|
|
50
|
-
|
|
51
|
-
|
|
128
|
+
title: localization.readyComplete,
|
|
129
|
+
subTitle: localization.reviewYourSettingsSelectionsWizard,
|
|
130
|
+
status: UI_E_WIZARD_STATUS.INACTIVE,
|
|
131
|
+
fields: {},
|
|
132
|
+
isValid: true,
|
|
52
133
|
},
|
|
53
134
|
]
|
|
54
135
|
|
|
55
|
-
export const
|
|
56
|
-
[
|
|
57
|
-
[
|
|
58
|
-
[
|
|
59
|
-
[
|
|
60
|
-
[
|
|
61
|
-
[
|
|
136
|
+
export const stepsSchemeInitial: number[][] = [
|
|
137
|
+
[0, 1, 3, 4, 7], // Validation done, except for ipv4 (backend problems)
|
|
138
|
+
[0, 1, 2, 3, 4, 7], // Validation done, except for ipv4 (backend problems)
|
|
139
|
+
[0, 1, 5, 7], // Validation done,
|
|
140
|
+
[0, 1, 2, 5, 7], // Disabled
|
|
141
|
+
[0, 1, 6, 7], // Disabled
|
|
142
|
+
[0, 1, 2, 7], // Disabled
|
|
62
143
|
]
|
|
63
144
|
|
|
64
|
-
export const secondTitleFunc = (
|
|
65
|
-
selectedStep: number,
|
|
66
|
-
localization: UI_I_Localization
|
|
67
|
-
): string => {
|
|
68
|
-
let text = ''
|
|
69
|
-
switch (selectedStep) {
|
|
70
|
-
case 0:
|
|
71
|
-
text = localization.selectConnectionType
|
|
72
|
-
break
|
|
73
|
-
case 1:
|
|
74
|
-
text = localization.selectTargetDevice
|
|
75
|
-
break
|
|
76
|
-
case 2:
|
|
77
|
-
text = localization.createStandardSwitch
|
|
78
|
-
break
|
|
79
|
-
case 3:
|
|
80
|
-
text = localization.portProperties
|
|
81
|
-
break
|
|
82
|
-
case 4:
|
|
83
|
-
text = localization.ipV4Settings
|
|
84
|
-
break
|
|
85
|
-
case 5:
|
|
86
|
-
text = localization.connectionSettings
|
|
87
|
-
break
|
|
88
|
-
case 6:
|
|
89
|
-
text = localization.addPhysicalNetworkAdapter
|
|
90
|
-
break
|
|
91
|
-
case 7:
|
|
92
|
-
text = localization.readyComplete
|
|
93
|
-
break
|
|
94
|
-
}
|
|
95
|
-
return text
|
|
96
|
-
}
|
|
97
|
-
|
|
98
145
|
export const createSecondSchemeReadyCompleteFunc = (
|
|
99
146
|
connectionSettingsValues: UI_I_ConnectionSettings,
|
|
100
147
|
targetDeviceValues: UI_I_TargetDevice,
|
|
@@ -47,8 +47,8 @@ import {
|
|
|
47
47
|
UI_I_BodyItems,
|
|
48
48
|
UI_I_Network,
|
|
49
49
|
UI_I_SelectedNetwork,
|
|
50
|
-
} from '~/components/common/
|
|
51
|
-
import { selectStandardSwitchTableHeadFunc } from '~/components/common/
|
|
50
|
+
} from '~/components/common/wizards/network/add/models/interfaces'
|
|
51
|
+
import { selectStandardSwitchTableHeadFunc } from '~/components/common/wizards/network/add/config'
|
|
52
52
|
|
|
53
53
|
interface I_SelectNetworkModalProps {
|
|
54
54
|
show: boolean
|
package/components/common/{addNetworking → wizards/network/add}/modals/SelectStandardSwitch.vue
RENAMED
|
@@ -36,10 +36,10 @@ import { UI_I_Localization } from '~/models/interfaces'
|
|
|
36
36
|
import {
|
|
37
37
|
UI_I_Switch,
|
|
38
38
|
UI_I_SelectedSwitch, UI_I_BodyItems,
|
|
39
|
-
} from '~/components/common/
|
|
39
|
+
} from '~/components/common/wizards/network/add/models/interfaces'
|
|
40
40
|
import {
|
|
41
41
|
selectStandardSwitchTableHeadFunc
|
|
42
|
-
} from '~/components/common/
|
|
42
|
+
} from '~/components/common/wizards/network/add/config'
|
|
43
43
|
|
|
44
44
|
interface I_SelectSwitchModalProps {
|
|
45
45
|
show: boolean
|
|
@@ -37,8 +37,8 @@ import {
|
|
|
37
37
|
UI_I_Switch,
|
|
38
38
|
UI_I_SelectedSwitch,
|
|
39
39
|
UI_I_BodyItems,
|
|
40
|
-
} from '~/components/common/
|
|
41
|
-
import { selectSwitchTableHeadFunc } from '~/components/common/
|
|
40
|
+
} from '~/components/common/wizards/network/add/models/interfaces'
|
|
41
|
+
import { selectSwitchTableHeadFunc } from '~/components/common/wizards/network/add/config'
|
|
42
42
|
|
|
43
43
|
interface I_SelectSwitchModalProps {
|
|
44
44
|
show: boolean
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export enum UI_E_ValidationFields {
|
|
2
|
+
TARGET_DEVICE_STANDARD_SWITCH = 'switch',
|
|
3
|
+
TARGET_DEVICE_NETWORK = 'network',
|
|
4
|
+
TARGET_DEVICE_SWITCH = 'switch2',
|
|
5
|
+
TARGET_DEVICE_MTU = 'new_switch.mtu',
|
|
6
|
+
|
|
7
|
+
PORT_PROPERTIES_NETWORK = 'network_name',
|
|
8
|
+
PORT_PROPERTIES_VLAN = 'new_network.vlan',
|
|
9
|
+
PORT_PROPERTIES_MTU = 'mtu',
|
|
10
|
+
|
|
11
|
+
IPV_SETTINGS_IPV = 'tcp_config.ipv4',
|
|
12
|
+
IPV_SETTINGS_MASK = 'tcp_config.net_mask',
|
|
13
|
+
IPV_SETTINGS_GATEWAY = 'tcp_config.gateway',
|
|
14
|
+
|
|
15
|
+
CONNECTION_SETTINGS_NETWORK = 'name',
|
|
16
|
+
CONNECTION_SETTINGS_VLAN = 'vlan',
|
|
17
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { UI_T_TCP } from '~/components/common/
|
|
1
|
+
import { UI_I_ArbitraryObject } from '~/models/interfaces'
|
|
2
|
+
import { UI_T_TCP } from '~/components/common/wizards/network/add/models/types'
|
|
3
3
|
|
|
4
4
|
export interface UI_I_Services {
|
|
5
5
|
vMotion?: boolean
|
|
@@ -51,12 +51,6 @@ export interface UI_I_SelectVmkernelAdapter {
|
|
|
51
51
|
vm: string
|
|
52
52
|
}
|
|
53
53
|
|
|
54
|
-
export interface UI_I_Step {
|
|
55
|
-
id: number
|
|
56
|
-
name: string
|
|
57
|
-
status: UI_E_StepStatus
|
|
58
|
-
}
|
|
59
|
-
|
|
60
54
|
export interface UI_I_Network {
|
|
61
55
|
name: string
|
|
62
56
|
id: string
|
|
@@ -90,30 +84,6 @@ export interface UI_I_ReadyCompleteFields {
|
|
|
90
84
|
}[]
|
|
91
85
|
}
|
|
92
86
|
|
|
93
|
-
export interface UI_I_ConnectionSettingsFieldsErrorMessages {
|
|
94
|
-
networkLabel: string
|
|
95
|
-
vlanId: string
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
export interface UI_I_IpFourSettingsFieldsErrorMessages {
|
|
99
|
-
ipFourAddress: string
|
|
100
|
-
subnetMask: string
|
|
101
|
-
defaultGateway: string
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
export interface UI_I_PortPropertiesFieldsErrorMessages {
|
|
105
|
-
networkLabel: string
|
|
106
|
-
vlanId: string
|
|
107
|
-
mtu: string
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
export interface UI_I_TargetDeviceFieldsErrorMessages {
|
|
111
|
-
network: string
|
|
112
|
-
switch: string
|
|
113
|
-
standardSwitch: string
|
|
114
|
-
mtu: string
|
|
115
|
-
}
|
|
116
|
-
|
|
117
87
|
export interface UI_I_PortPropertiesEnabledService {
|
|
118
88
|
label: string
|
|
119
89
|
modelValue: string
|
|
@@ -156,11 +126,6 @@ export interface UI_I_AddNetworkingZeroOrFirstSchemeDataSend {
|
|
|
156
126
|
}
|
|
157
127
|
}
|
|
158
128
|
|
|
159
|
-
export interface UI_I_NetworkLabelCheckExisting {
|
|
160
|
-
valid: boolean
|
|
161
|
-
checked: boolean
|
|
162
|
-
}
|
|
163
|
-
|
|
164
129
|
export interface UI_I_TableHead {
|
|
165
130
|
text: string
|
|
166
131
|
}
|
|
@@ -206,3 +171,31 @@ export interface UI_I_ReadyCompleteFirstColumn {
|
|
|
206
171
|
name: string
|
|
207
172
|
value: string | undefined
|
|
208
173
|
}
|
|
174
|
+
|
|
175
|
+
export interface UI_I_AddNetworkingEmits {
|
|
176
|
+
(event: 'hide'): void
|
|
177
|
+
(
|
|
178
|
+
event: 'add-networking-data-validate',
|
|
179
|
+
networkData:
|
|
180
|
+
| UI_I_AddNetworkingSecondOrThirdSchemeDataSend
|
|
181
|
+
| UI_I_AddNetworkingZeroOrFirstSchemeDataSend,
|
|
182
|
+
type: string,
|
|
183
|
+
setValidation: (err_arg: UI_I_ArbitraryObject<string>) => void
|
|
184
|
+
): void
|
|
185
|
+
(
|
|
186
|
+
event: 'send-add-networking-data',
|
|
187
|
+
schemeData:
|
|
188
|
+
| UI_I_AddNetworkingSecondOrThirdSchemeDataSend
|
|
189
|
+
| UI_I_AddNetworkingZeroOrFirstSchemeDataSend,
|
|
190
|
+
type: string,
|
|
191
|
+
hideSendNetworkDataLoader: () => void,
|
|
192
|
+
onHideAddNetworkingModal: () => void
|
|
193
|
+
): void
|
|
194
|
+
(event: 'get-existing-standard-switches', cb: () => void): void
|
|
195
|
+
(event: 'get-free-adapters', cb: () => void): void
|
|
196
|
+
(
|
|
197
|
+
event: 'check-network-label',
|
|
198
|
+
networkLabel: string,
|
|
199
|
+
cb: (error_message: string) => void
|
|
200
|
+
): void
|
|
201
|
+
}
|
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="wizard-content-container add-networking-step">
|
|
3
|
+
<div class="wizard-content wizard-content-port">
|
|
4
|
+
<atoms-alert
|
|
5
|
+
v-if="props.alertMessages.length"
|
|
6
|
+
status="alert-danger"
|
|
7
|
+
:items="props.alertMessages"
|
|
8
|
+
@remove="onHideAlert"
|
|
9
|
+
/>
|
|
10
|
+
<form>
|
|
11
|
+
<div class="horizontal-flex-container">
|
|
12
|
+
<label class="property-label-group" for="network-label">
|
|
13
|
+
{{ localization.networkLabel }}
|
|
14
|
+
</label>
|
|
15
|
+
<div class="margin-left-property-value-group">
|
|
16
|
+
<div class="property-value-group">
|
|
17
|
+
<fieldset>
|
|
18
|
+
<atoms-tooltip-error
|
|
19
|
+
:has-error="!!props.messagesFields.name.field"
|
|
20
|
+
>
|
|
21
|
+
<template #elem>
|
|
22
|
+
<input
|
|
23
|
+
id="network-label"
|
|
24
|
+
v-model="fields.networkLabel"
|
|
25
|
+
name="network-label"
|
|
26
|
+
type="text"
|
|
27
|
+
:class="[
|
|
28
|
+
'tooltip-field port-properties-network-label',
|
|
29
|
+
{
|
|
30
|
+
'danger-not-valid': props.messagesFields.name.field,
|
|
31
|
+
},
|
|
32
|
+
]"
|
|
33
|
+
@click.stop
|
|
34
|
+
/>
|
|
35
|
+
</template>
|
|
36
|
+
<template #content>
|
|
37
|
+
{{ props.messagesFields.name.field }}
|
|
38
|
+
</template>
|
|
39
|
+
</atoms-tooltip-error>
|
|
40
|
+
</fieldset>
|
|
41
|
+
</div>
|
|
42
|
+
</div>
|
|
43
|
+
</div>
|
|
44
|
+
|
|
45
|
+
<div class="horizontal-flex-container port-properties-padding">
|
|
46
|
+
<label class="property-label-group">
|
|
47
|
+
{{ localization.vlanId }}
|
|
48
|
+
</label>
|
|
49
|
+
<div class="margin-left-property-value-group">
|
|
50
|
+
<div class="property-value-group">
|
|
51
|
+
<fieldset>
|
|
52
|
+
<div class="flex-align-center">
|
|
53
|
+
<atoms-combobox
|
|
54
|
+
v-model.trim="fields.vlanId"
|
|
55
|
+
:items="vlanIdSelectData"
|
|
56
|
+
:class="{
|
|
57
|
+
'danger-not-valid': props.messagesFields.vlan.field,
|
|
58
|
+
}"
|
|
59
|
+
@click.stop
|
|
60
|
+
/>
|
|
61
|
+
<div
|
|
62
|
+
v-show="props.messagesFields.vlan.field"
|
|
63
|
+
class="flex-align-center"
|
|
64
|
+
>
|
|
65
|
+
<div class="tooltip flex align-middle">
|
|
66
|
+
<atoms-the-icon
|
|
67
|
+
width="24px"
|
|
68
|
+
height="24px"
|
|
69
|
+
class="is-error tooltip-trigger"
|
|
70
|
+
name="info"
|
|
71
|
+
/>
|
|
72
|
+
<div class="tooltip-top-left tooltip-content error">
|
|
73
|
+
{{ props.messagesFields.vlan.field }}
|
|
74
|
+
</div>
|
|
75
|
+
</div>
|
|
76
|
+
</div>
|
|
77
|
+
</div>
|
|
78
|
+
</fieldset>
|
|
79
|
+
</div>
|
|
80
|
+
</div>
|
|
81
|
+
</div>
|
|
82
|
+
</form>
|
|
83
|
+
</div>
|
|
84
|
+
</div>
|
|
85
|
+
</template>
|
|
86
|
+
|
|
87
|
+
<script setup lang="ts">
|
|
88
|
+
import { UI_I_ArbitraryObject, UI_I_Localization } from '~/models/interfaces'
|
|
89
|
+
import { UI_I_ConnectionSettings } from '~/components/common/wizards/network/add/models/interfaces'
|
|
90
|
+
import { vlanIdSelectData } from '~/components/common/wizards/network/add/config'
|
|
91
|
+
import { UI_I_ErrorFields } from '~/components/atoms/wizard/models/interfaces'
|
|
92
|
+
import type Wizard from '~/components/atoms/wizard/utils/utils'
|
|
93
|
+
import {
|
|
94
|
+
validateNetworkConnectionSettingsLocal,
|
|
95
|
+
validateVlanIdConnectionSettingsLocal,
|
|
96
|
+
} from '~/components/common/wizards/network/add/validations/validations'
|
|
97
|
+
|
|
98
|
+
const props = defineProps<{
|
|
99
|
+
connectionSettings: UI_I_ConnectionSettings
|
|
100
|
+
alertMessages: string[]
|
|
101
|
+
messagesFields: UI_I_ArbitraryObject<UI_I_ErrorFields>
|
|
102
|
+
wizard: Wizard
|
|
103
|
+
}>()
|
|
104
|
+
|
|
105
|
+
const localization = computed<UI_I_Localization>(() => useLocal())
|
|
106
|
+
|
|
107
|
+
const emits = defineEmits<{
|
|
108
|
+
(
|
|
109
|
+
event: 'change-connection-settings',
|
|
110
|
+
connectionSettings: UI_I_ConnectionSettings
|
|
111
|
+
): void
|
|
112
|
+
(event: 'hide-alert', stepId: 5): void
|
|
113
|
+
}>()
|
|
114
|
+
|
|
115
|
+
const fields = ref<UI_I_ConnectionSettings>(
|
|
116
|
+
useDeepCopy(props.connectionSettings)
|
|
117
|
+
)
|
|
118
|
+
|
|
119
|
+
let oldFields = useDeepCopy(fields.value)
|
|
120
|
+
|
|
121
|
+
watch(
|
|
122
|
+
fields,
|
|
123
|
+
(newFields: UI_I_ConnectionSettings) => {
|
|
124
|
+
oldFields.vlanId !== newFields.vlanId &&
|
|
125
|
+
validateVlanIdConnectionSettingsLocal(
|
|
126
|
+
localization.value,
|
|
127
|
+
newFields,
|
|
128
|
+
props.wizard
|
|
129
|
+
)
|
|
130
|
+
|
|
131
|
+
oldFields.networkLabel !== newFields.networkLabel &&
|
|
132
|
+
validateNetworkConnectionSettingsLocal(
|
|
133
|
+
localization.value,
|
|
134
|
+
newFields,
|
|
135
|
+
props.wizard
|
|
136
|
+
)
|
|
137
|
+
|
|
138
|
+
oldFields = useDeepCopy(fields.value)
|
|
139
|
+
|
|
140
|
+
emits('change-connection-settings', newFields)
|
|
141
|
+
},
|
|
142
|
+
{ deep: true, immediate: true }
|
|
143
|
+
)
|
|
144
|
+
|
|
145
|
+
const onHideAlert = (): void => {
|
|
146
|
+
emits('hide-alert', 5)
|
|
147
|
+
}
|
|
148
|
+
</script>
|
package/components/common/{addNetworking → wizards/network/add}/steps/CreateStandardSwitch.vue
RENAMED
|
@@ -1,9 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="wizard-content-container add-networking-step">
|
|
3
|
-
<common-add-networking-steps-header
|
|
4
|
-
:title="props.title"
|
|
5
|
-
:text="props.text"
|
|
6
|
-
/>
|
|
7
3
|
<div class="wizard-content">
|
|
8
4
|
<common-adapter-manager
|
|
9
5
|
test-id="adapter-manager"
|
|
@@ -45,9 +41,6 @@ import {
|
|
|
45
41
|
|
|
46
42
|
// Props from up
|
|
47
43
|
const props = defineProps<{
|
|
48
|
-
title: string
|
|
49
|
-
text: string
|
|
50
|
-
stepId: number
|
|
51
44
|
addedAdapters: string[]
|
|
52
45
|
freeAdapters: UI_I_Adapter[]
|
|
53
46
|
adapterStatus: UI_I_AdapterStatus
|