bfg-common 1.5.442 → 1.5.443
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 -3
- package/assets/localization/local_en.json +17 -11
- package/assets/localization/local_hy.json +9 -3
- package/assets/localization/local_kk.json +9 -3
- package/assets/localization/local_ru.json +9 -3
- package/assets/localization/local_zh.json +9 -3
- package/components/atoms/wizard/Wizard.vue +2 -2
- package/components/atoms/wizard/step/Step.vue +1 -1
- package/components/common/backup/storage/actions/add/Add.vue +5 -5
- package/components/common/backup/storage/actions/add/Old.vue +1 -1
- package/components/common/backup/storage/actions/add/lib/config/steps.ts +2 -2
- package/components/common/backup/storage/actions/add/lib/validations.ts +4 -4
- package/components/common/backup/storage/actions/add/steps/name/Name.vue +1 -1
- package/components/common/backup/storage/actions/add/steps/name/New.vue +1 -1
- package/components/common/backup/storage/actions/add/steps/name/Old.vue +1 -1
- package/components/common/backup/storage/actions/add/steps/nameAndConfigure/NameAndConfigure.vue +1 -1
- package/components/common/backup/storage/actions/add/steps/nameAndConfigure/NameAndConfigureNew.vue +1 -1
- package/components/common/backup/storage/actions/add/steps/nameAndConfigure/NameAndConfigureOld.vue +1 -1
- package/components/common/browse/blocks/lib/models/types.ts +1 -1
- package/components/common/browse/lib/models/interfaces.ts +5 -5
- package/components/common/countdownTimer/CountdownTimer.vue +26 -15
- 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/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/MigrateVmkernelAdapter.vue +5 -5
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/lib/config/steps.ts +2 -2
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/steps/ConnectionSettings.vue +2 -2
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/common.ts +14 -14
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/connectionSettings.ts +5 -5
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/selectVmkernelAdapter.ts +2 -2
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/validations.ts +19 -19
- package/components/common/diagramMain/port/Ports.vue +47 -47
- package/components/common/layout/theHeader/modals/{reconnect/Reconnect.vue → Reconnect.vue} +56 -43
- package/components/common/pages/backups/modals/Modals.vue +1 -1
- package/components/common/pages/backups/modals/createBackup/CreateBackup.vue +5 -2
- package/components/common/pages/backups/modals/createBackup/lib/config/steps.ts +2 -2
- package/components/common/pages/backups/modals/restore/Restore.vue +3 -3
- package/components/common/pages/backups/modals/restore/lib/config/steps.ts +2 -2
- package/components/common/vm/actions/add/Add.vue +5 -5
- package/components/common/vm/actions/add/New.vue +2 -2
- package/components/common/vm/actions/add/Old.vue +2 -2
- package/components/common/vm/actions/add/lib/config/steps.ts +2 -2
- package/components/common/vm/actions/clone/Clone.vue +5 -5
- package/components/common/vm/actions/clone/lib/config/steps.ts +2 -2
- package/components/common/vm/actions/clone/toTemplate/ToTemplate.vue +5 -5
- package/components/common/vm/actions/clone/toTemplate/lib/config/steps.ts +2 -2
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/maximumSize/MaximumSize.vue +23 -23
- package/components/common/vmt/actions/add/Add.vue +5 -5
- package/components/common/vmt/actions/add/New.vue +2 -3
- package/components/common/vmt/actions/add/Old.vue +2 -2
- package/components/common/vmt/actions/add/lib/config/steps.ts +2 -2
- package/components/common/wizards/datastore/add/Add.vue +2 -2
- package/components/common/wizards/datastore/add/Old.vue +2 -2
- package/components/common/wizards/datastore/add/lib/config/steps.ts +2 -2
- package/components/common/wizards/datastore/add/lib/utils.ts +1 -1
- package/components/common/wizards/datastore/add/lib/validations.ts +3 -3
- package/components/common/wizards/datastore/add/steps/_local/Local.vue +1 -1
- package/components/common/wizards/datastore/add/steps/_local/createName/CreateName.vue +1 -1
- package/components/common/wizards/datastore/add/steps/nameAndConfigure/NameAndConfigure.vue +2 -1
- package/components/common/wizards/datastore/add/steps/nameAndConfigure/NameAndConfigureNew.vue +1 -1
- package/components/common/wizards/datastore/add/steps/nameAndConfigure/NameAndConfigureOld.vue +1 -1
- package/components/common/wizards/datastore/add/steps/nameAndDevice/NameAndDevice.vue +1 -1
- package/components/common/wizards/datastore/add/steps/nameAndDevice/NameAndDeviceNew.vue +1 -1
- package/components/common/wizards/datastore/add/steps/nameAndDevice/NameAndDeviceOld.vue +1 -1
- package/components/common/wizards/network/add/Add.vue +109 -333
- package/components/common/wizards/network/add/AddNew.vue +514 -0
- package/components/common/wizards/network/add/AddOld.vue +457 -0
- package/components/common/wizards/network/add/lib/config/config.ts +11 -1
- package/components/common/wizards/network/add/lib/config/selectConnectionTypeStep.ts +31 -0
- package/components/common/wizards/network/add/lib/config/selectSwitch.ts +217 -0
- package/components/common/wizards/network/add/lib/config/steps.ts +5 -5
- package/components/common/wizards/network/add/lib/models/interfaces.ts +9 -0
- package/components/common/wizards/network/add/steps/ConnectionSettings.vue +2 -2
- package/components/common/wizards/network/add/steps/IpFourSettings.vue +2 -2
- package/components/common/wizards/network/add/steps/PortProperties.vue +2 -2
- package/components/common/wizards/network/add/steps/selectConnectionType/SelectConnectionType.vue +35 -0
- package/components/common/wizards/network/add/steps/selectConnectionType/SelectConnectionTypeNew.vue +104 -0
- package/components/common/wizards/network/add/steps/selectConnectionType/SelectConnectionTypeOld.vue +80 -0
- package/components/common/wizards/network/add/steps/selectTargetDevice/SelectTargetDevice.vue +183 -0
- package/components/common/wizards/network/add/steps/selectTargetDevice/SelectTargetDeviceNew.vue +393 -0
- package/components/common/wizards/network/add/steps/{SelectedTargetDevice.vue → selectTargetDevice/SelectTargetDeviceOld.vue} +42 -139
- package/components/common/wizards/network/add/steps/selectTargetDevice/modals/Modals.vue +55 -0
- package/components/common/wizards/network/add/steps/selectTargetDevice/modals/SelectNetwork.vue +64 -0
- package/components/common/wizards/network/add/steps/selectTargetDevice/modals/SelectStandardSwitch.vue +64 -0
- package/components/common/wizards/network/add/steps/selectTargetDevice/modals/SelectSwitch.vue +64 -0
- package/components/common/wizards/network/add/steps/selectTargetDevice/modals/new/SelectNetwork.vue +163 -0
- package/components/common/wizards/network/add/steps/selectTargetDevice/modals/new/SelectStandardSwitch.vue +163 -0
- package/components/common/wizards/network/add/steps/selectTargetDevice/modals/new/SelectSwitch.vue +163 -0
- package/components/common/wizards/network/add/{modals → steps/selectTargetDevice/modals/old}/SelectNetwork.vue +53 -56
- package/components/common/wizards/network/add/{modals → steps/selectTargetDevice/modals/old}/SelectStandardSwitch.vue +37 -52
- package/components/common/wizards/network/add/{modals → steps/selectTargetDevice/modals/old}/SelectSwitch.vue +38 -42
- package/components/common/wizards/network/add/validations/connectionSettings.ts +5 -5
- package/components/common/wizards/network/add/validations/createStandardSwitch.ts +4 -4
- package/components/common/wizards/network/add/validations/ipFourSettings.ts +5 -5
- package/components/common/wizards/network/add/validations/networkValidation.ts +4 -4
- package/components/common/wizards/network/add/validations/physicalAdapter.ts +4 -4
- package/components/common/wizards/network/add/validations/portProperties.ts +2 -2
- package/components/common/wizards/network/add/validations/targetDevice.ts +11 -10
- package/components/common/wizards/vm/migrate/Migrate.vue +2 -2
- package/components/common/wizards/vm/migrate/lib/config/steps.ts +2 -2
- package/components/common/wizards/vm/migrate/lib/validations.ts +3 -3
- package/components/common/wizards/vm/migrate/select/targetServer/new/New.vue +1 -1
- package/components/common/wizards/vm/migrate/select/targetServer/targetServer.vue +1 -1
- package/package.json +2 -2
- package/components/atoms/wizard/lib/models/enums.ts +0 -8
- package/components/atoms/wizard/lib/models/interfaces.ts +0 -59
- package/components/atoms/wizard/lib/utils/utils.ts +0 -954
- package/components/common/countdownTimer/CountdownTimerNew.vue +0 -53
- package/components/common/countdownTimer/CountdownTimerOld.vue +0 -33
- package/components/common/layout/theHeader/modals/reconnect/ReconnectNew.vue +0 -74
- package/components/common/layout/theHeader/modals/reconnect/ReconnectOld.vue +0 -67
- package/components/common/wizards/network/add/steps/SelectConnectionType.vue +0 -112
@@ -1,5 +1,14 @@
|
|
1
|
+
import type {
|
2
|
+
UI_I_DataTableOptions,
|
3
|
+
UI_I_DataTableHeader,
|
4
|
+
UI_I_DataTableBody,
|
5
|
+
} from '~/node_modules/bfg-uikit/components/ui/dataTable/lib/models/interfaces'
|
1
6
|
import type { UI_I_Localization } from '~/lib/models/interfaces'
|
2
7
|
import type { UI_I_TableHead } from '~/components/common/wizards/network/add/lib/models/interfaces'
|
8
|
+
import type {
|
9
|
+
UI_I_Switch,
|
10
|
+
UI_I_NetworkForAdding,
|
11
|
+
} from '~/components/common/wizards/network/add/lib/models/interfaces'
|
3
12
|
|
4
13
|
export const selectNetworkTableHeadFunc = (
|
5
14
|
localization: UI_I_Localization
|
@@ -8,12 +17,220 @@ export const selectNetworkTableHeadFunc = (
|
|
8
17
|
{ text: localization.common.nsxPortGroupId },
|
9
18
|
{ text: localization.common.discoveredIssues },
|
10
19
|
]
|
20
|
+
|
21
|
+
export const selectNetworkTableHeadNewFunc = (
|
22
|
+
localization: UI_I_Localization
|
23
|
+
): UI_I_DataTableHeader[] => [
|
24
|
+
{
|
25
|
+
col: 0,
|
26
|
+
colName: 'name',
|
27
|
+
text: localization.common.name,
|
28
|
+
isSortable: true,
|
29
|
+
sort: 'asc',
|
30
|
+
sortColumn: true,
|
31
|
+
width: '180px',
|
32
|
+
show: true,
|
33
|
+
filter: true,
|
34
|
+
},
|
35
|
+
{
|
36
|
+
col: 1,
|
37
|
+
colName: 'nsx-port-group-id',
|
38
|
+
text: localization.common.nsxPortGroupId,
|
39
|
+
isSortable: true,
|
40
|
+
sort: 'asc',
|
41
|
+
sortColumn: false,
|
42
|
+
width: '',
|
43
|
+
show: true,
|
44
|
+
filter: true,
|
45
|
+
},
|
46
|
+
{
|
47
|
+
col: 2,
|
48
|
+
colName: 'distributed-switch',
|
49
|
+
text: localization.common.distributedSwitch,
|
50
|
+
isSortable: true,
|
51
|
+
sort: 'asc',
|
52
|
+
sortColumn: false,
|
53
|
+
width: '',
|
54
|
+
show: true,
|
55
|
+
filter: true,
|
56
|
+
},
|
57
|
+
]
|
58
|
+
|
59
|
+
export const selectNetworkTableBodyNewFunc = (
|
60
|
+
data: UI_I_NetworkForAdding[]
|
61
|
+
): UI_I_DataTableBody[] =>
|
62
|
+
data.map(
|
63
|
+
(item: UI_I_NetworkForAdding, index: number): UI_I_DataTableBody[] => {
|
64
|
+
return {
|
65
|
+
row: index,
|
66
|
+
collapse: false,
|
67
|
+
isHiddenCollapse: false,
|
68
|
+
collapseToggle: false,
|
69
|
+
data: [
|
70
|
+
{
|
71
|
+
col: 0,
|
72
|
+
key: 'icon',
|
73
|
+
text: item.name,
|
74
|
+
icon: 'vsphere-icon-network',
|
75
|
+
},
|
76
|
+
{
|
77
|
+
col: 1,
|
78
|
+
key: '',
|
79
|
+
text: '--',
|
80
|
+
},,
|
81
|
+
{
|
82
|
+
col: 2,
|
83
|
+
key: '',
|
84
|
+
text: '--',
|
85
|
+
},
|
86
|
+
],
|
87
|
+
}
|
88
|
+
}
|
89
|
+
)
|
90
|
+
|
11
91
|
export const selectSwitchTableHeadFunc = (
|
12
92
|
localization: UI_I_Localization
|
13
93
|
): UI_I_TableHead[] => [
|
14
94
|
{ text: localization.common.switch },
|
15
95
|
{ text: localization.common.discoveredIssues },
|
16
96
|
]
|
97
|
+
|
98
|
+
export const selectSwitchTableHeadNewFunc = (
|
99
|
+
localization: UI_I_Localization
|
100
|
+
): UI_I_DataTableHeader[] => [
|
101
|
+
{
|
102
|
+
col: 0,
|
103
|
+
colName: 'name',
|
104
|
+
text: localization.common.name,
|
105
|
+
isSortable: true,
|
106
|
+
sort: 'asc',
|
107
|
+
sortColumn: true,
|
108
|
+
width: '200px',
|
109
|
+
show: true,
|
110
|
+
filter: true,
|
111
|
+
},
|
112
|
+
{
|
113
|
+
col: 1,
|
114
|
+
colName: 'discovered-issues',
|
115
|
+
text: localization.common.discoveredIssues,
|
116
|
+
isSortable: true,
|
117
|
+
sort: 'asc',
|
118
|
+
sortColumn: false,
|
119
|
+
width: '',
|
120
|
+
show: true,
|
121
|
+
filter: true,
|
122
|
+
},
|
123
|
+
]
|
124
|
+
|
125
|
+
export const selectSwitchTableBodyNewFunc = (
|
126
|
+
data: UI_I_Switch[]
|
127
|
+
): UI_I_DataTableBody[] =>
|
128
|
+
data.map((item: UI_I_Switch, index: number): UI_I_DataTableBody[] => {
|
129
|
+
return {
|
130
|
+
row: index,
|
131
|
+
collapse: false,
|
132
|
+
isHiddenCollapse: false,
|
133
|
+
collapseToggle: false,
|
134
|
+
data: [
|
135
|
+
{
|
136
|
+
col: 0,
|
137
|
+
key: 'icon',
|
138
|
+
text: item.name,
|
139
|
+
icon: 'network-lib-ui-icon-vswitch',
|
140
|
+
},
|
141
|
+
{
|
142
|
+
col: 1,
|
143
|
+
key: '',
|
144
|
+
text: '--',
|
145
|
+
},
|
146
|
+
],
|
147
|
+
}
|
148
|
+
})
|
149
|
+
|
17
150
|
export const selectStandardSwitchTableHeadFunc = (
|
18
151
|
localization: UI_I_Localization
|
19
152
|
): UI_I_TableHead[] => [{ text: localization.common.switch }]
|
153
|
+
|
154
|
+
export const selectStandardSwitchTableHeadNewFunc = (
|
155
|
+
localization: UI_I_Localization
|
156
|
+
): UI_I_DataTableHeader[] => [
|
157
|
+
{
|
158
|
+
col: 0,
|
159
|
+
colName: 'name',
|
160
|
+
text: localization.common.name,
|
161
|
+
isSortable: true,
|
162
|
+
sort: 'asc',
|
163
|
+
sortColumn: true,
|
164
|
+
width: '',
|
165
|
+
show: true,
|
166
|
+
filter: true,
|
167
|
+
},
|
168
|
+
]
|
169
|
+
|
170
|
+
export const selectStandardSwitchTableBodyNewFunc = (
|
171
|
+
data: UI_I_Switch[]
|
172
|
+
): UI_I_DataTableBody[] =>
|
173
|
+
data.map((item: UI_I_Switch, index: number): UI_I_DataTableBody[] => {
|
174
|
+
return {
|
175
|
+
row: index,
|
176
|
+
collapse: false,
|
177
|
+
isHiddenCollapse: false,
|
178
|
+
collapseToggle: false,
|
179
|
+
data: [
|
180
|
+
{
|
181
|
+
col: 0,
|
182
|
+
key: 'icon',
|
183
|
+
text: item.name,
|
184
|
+
icon: 'network-lib-ui-icon-vswitch',
|
185
|
+
},
|
186
|
+
],
|
187
|
+
}
|
188
|
+
})
|
189
|
+
|
190
|
+
export const tableOptionsNew: UI_I_DataTableOptions = {
|
191
|
+
perPageOptions: [
|
192
|
+
{ text: '10', value: 10 },
|
193
|
+
{ text: '25', value: 25 },
|
194
|
+
{ text: '50', value: 50 },
|
195
|
+
{ text: '100', value: 100, default: true },
|
196
|
+
],
|
197
|
+
isSelectable: true,
|
198
|
+
selectType: 'radio',
|
199
|
+
showPagination: false,
|
200
|
+
showPageInfo: false,
|
201
|
+
isSortable: true,
|
202
|
+
server: false,
|
203
|
+
isResizable: false,
|
204
|
+
showSearch: false,
|
205
|
+
showColumnManager: false,
|
206
|
+
withActions: false,
|
207
|
+
inBlock: false,
|
208
|
+
inModal: false,
|
209
|
+
showExport: false,
|
210
|
+
withCollapse: false,
|
211
|
+
showPaginationOnTop: false,
|
212
|
+
}
|
213
|
+
|
214
|
+
export const tableNetworkOptionsNew: UI_I_DataTableOptions = {
|
215
|
+
perPageOptions: [
|
216
|
+
{ text: '10', value: 10 },
|
217
|
+
{ text: '25', value: 25 },
|
218
|
+
{ text: '50', value: 50 },
|
219
|
+
{ text: '100', value: 100, default: true },
|
220
|
+
],
|
221
|
+
isSelectable: true,
|
222
|
+
selectType: 'radio',
|
223
|
+
showPagination: false,
|
224
|
+
showPageInfo: false,
|
225
|
+
isSortable: true,
|
226
|
+
server: false,
|
227
|
+
isResizable: false,
|
228
|
+
showSearch: false,
|
229
|
+
showColumnManager: true,
|
230
|
+
withActions: false,
|
231
|
+
inBlock: false,
|
232
|
+
inModal: false,
|
233
|
+
showExport: false,
|
234
|
+
withCollapse: false,
|
235
|
+
showPaginationOnTop: false,
|
236
|
+
}
|
@@ -1,3 +1,8 @@
|
|
1
|
+
import type {
|
2
|
+
UI_I_WizardStep,
|
3
|
+
UI_I_WizardSchemeData,
|
4
|
+
} from '~/node_modules/bfg-uikit/components/ui/wizard/lib/models/interfaces'
|
5
|
+
import { UI_E_WIZARD_STATUS } from '~/node_modules/bfg-uikit/components/ui/wizard/lib/models/enums'
|
1
6
|
import type { UI_I_Localization } from '~/lib/models/interfaces'
|
2
7
|
import type {
|
3
8
|
UI_I_ConnectionSettings,
|
@@ -13,11 +18,6 @@ import type {
|
|
13
18
|
UI_I_Adapter,
|
14
19
|
} from '~/components/common/diagramMain/lib/models/interfaces'
|
15
20
|
import { UI_E_ValidationFields } from '~/components/common/wizards/network/add/lib/models/enums'
|
16
|
-
import type {
|
17
|
-
UI_I_WizardStep,
|
18
|
-
UI_I_WizardSchemeData,
|
19
|
-
} from '~/components/atoms/wizard/lib/models/interfaces'
|
20
|
-
import { UI_E_WIZARD_STATUS } from '~/components/atoms/wizard/lib/models/enums'
|
21
21
|
|
22
22
|
export const stepsFunc = (
|
23
23
|
localization: UI_I_Localization
|
@@ -247,3 +247,12 @@ export interface UI_I_TCPStack {
|
|
247
247
|
routing_table: number
|
248
248
|
routes: string[]
|
249
249
|
}
|
250
|
+
|
251
|
+
export interface UI_I_SelectConnectionTypeItem {
|
252
|
+
label: string
|
253
|
+
description: string
|
254
|
+
value: string
|
255
|
+
testId: string
|
256
|
+
permission?: string
|
257
|
+
id?: string
|
258
|
+
}
|
@@ -88,13 +88,13 @@
|
|
88
88
|
</template>
|
89
89
|
|
90
90
|
<script setup lang="ts">
|
91
|
+
import type { UI_I_ErrorFields } from '~/node_modules/bfg-uikit/components/ui/wizard/lib/models/interfaces'
|
92
|
+
import type Wizard from '~/node_modules/bfg-uikit/components/ui/wizard/lib/utils/utils'
|
91
93
|
import type {
|
92
94
|
UI_I_ArbitraryObject,
|
93
95
|
UI_I_Localization,
|
94
96
|
} from '~/lib/models/interfaces'
|
95
97
|
import type { UI_I_ConnectionSettings } from '~/components/common/wizards/network/add/lib/models/interfaces'
|
96
|
-
import type { UI_I_ErrorFields } from '~/components/atoms/wizard/lib/models/interfaces'
|
97
|
-
import type Wizard from '~/components/atoms/wizard/lib/utils/utils'
|
98
98
|
import { vlanIdSelectData } from '~/components/common/wizards/network/add/lib/config/config'
|
99
99
|
import {
|
100
100
|
validateNetworkConnectionSettingsLocal,
|
@@ -178,6 +178,8 @@
|
|
178
178
|
</template>
|
179
179
|
|
180
180
|
<script setup lang="ts">
|
181
|
+
import type { UI_I_ErrorFields } from '~/node_modules/bfg-uikit/components/ui/wizard/lib/models/interfaces'
|
182
|
+
import type Wizard from '~/node_modules/bfg-uikit/components/ui/wizard/lib/utils/utils'
|
181
183
|
import type {
|
182
184
|
UI_I_ArbitraryObject,
|
183
185
|
UI_I_Localization,
|
@@ -186,8 +188,6 @@ import type {
|
|
186
188
|
UI_I_IpFourSettings,
|
187
189
|
UI_I_TCPStack,
|
188
190
|
} from '~/components/common/wizards/network/add/lib/models/interfaces'
|
189
|
-
import type { UI_I_ErrorFields } from '~/components/atoms/wizard/lib/models/interfaces'
|
190
|
-
import type Wizard from '~/components/atoms/wizard/lib/utils/utils'
|
191
191
|
import {
|
192
192
|
removeIpFourSettingsValidationLocal,
|
193
193
|
validateAddressIpFourSettingsLocal,
|
@@ -221,6 +221,8 @@
|
|
221
221
|
</template>
|
222
222
|
|
223
223
|
<script setup lang="ts">
|
224
|
+
import type { UI_I_ErrorFields } from '~/node_modules/bfg-uikit/components/ui/wizard/lib/models/interfaces'
|
225
|
+
import type Wizard from '~/node_modules/bfg-uikit/components/ui/wizard/lib/utils/utils'
|
224
226
|
import type {
|
225
227
|
UI_I_ArbitraryObject,
|
226
228
|
UI_I_Localization,
|
@@ -231,8 +233,6 @@ import type {
|
|
231
233
|
UI_I_TCPStack,
|
232
234
|
} from '~/components/common/wizards/network/add/lib/models/interfaces'
|
233
235
|
import type { UI_T_TCP } from '~/components/common/wizards/network/add/lib/models/types'
|
234
|
-
import type { UI_I_ErrorFields } from '~/components/atoms/wizard/lib/models/interfaces'
|
235
|
-
import type Wizard from '~/components/atoms/wizard/lib/utils/utils'
|
236
236
|
import {
|
237
237
|
servicesInitial,
|
238
238
|
vlanIdSelectData,
|
package/components/common/wizards/network/add/steps/selectConnectionType/SelectConnectionType.vue
ADDED
@@ -0,0 +1,35 @@
|
|
1
|
+
<template>
|
2
|
+
<common-wizards-network-add-steps-select-connection-type-new
|
3
|
+
v-if="isNewView"
|
4
|
+
v-model="connectionTypeLocal"
|
5
|
+
/>
|
6
|
+
<common-wizards-network-add-steps-select-connection-type-old
|
7
|
+
v-else
|
8
|
+
v-model="connectionTypeLocal"
|
9
|
+
/>
|
10
|
+
</template>
|
11
|
+
|
12
|
+
<script setup lang="ts">
|
13
|
+
const props = defineProps<{
|
14
|
+
modelValue: string
|
15
|
+
}>()
|
16
|
+
|
17
|
+
const emits = defineEmits<{
|
18
|
+
(event: 'update:model-value', connectionType: string): void
|
19
|
+
}>()
|
20
|
+
|
21
|
+
const { $store }: any = useNuxtApp()
|
22
|
+
|
23
|
+
const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
|
24
|
+
|
25
|
+
const connectionTypeLocal = computed<string>({
|
26
|
+
get() {
|
27
|
+
return props.modelValue
|
28
|
+
},
|
29
|
+
set(newValue: string) {
|
30
|
+
emits('update:model-value', newValue)
|
31
|
+
},
|
32
|
+
})
|
33
|
+
</script>
|
34
|
+
|
35
|
+
<style scoped lang="scss"></style>
|
package/components/common/wizards/network/add/steps/selectConnectionType/SelectConnectionTypeNew.vue
ADDED
@@ -0,0 +1,104 @@
|
|
1
|
+
<template>
|
2
|
+
<div class="content">
|
3
|
+
<div
|
4
|
+
v-for="item in selectConnectionTypeItems"
|
5
|
+
:key="item.testId"
|
6
|
+
v-permission="item.permission"
|
7
|
+
:class="['radio-block', { selected: connectionTypeLocal === item.value }]"
|
8
|
+
@click="connectionTypeLocal = item.value"
|
9
|
+
>
|
10
|
+
<ui-radio
|
11
|
+
v-model="connectionTypeLocal"
|
12
|
+
:label="item.label"
|
13
|
+
:value="item.value"
|
14
|
+
:test-id="item.testId"
|
15
|
+
size="md"
|
16
|
+
>
|
17
|
+
<template #description>
|
18
|
+
<p class="description">
|
19
|
+
{{ item.description }}
|
20
|
+
</p>
|
21
|
+
</template>
|
22
|
+
</ui-radio>
|
23
|
+
</div>
|
24
|
+
</div>
|
25
|
+
</template>
|
26
|
+
|
27
|
+
<script setup lang="ts">
|
28
|
+
import type { UI_I_Localization } from '~/lib/models/interfaces'
|
29
|
+
import type { UI_I_SelectConnectionTypeItem } from '~/components/common/wizards/network/add/lib/models/interfaces'
|
30
|
+
import { selectConnectionTypeFunc } from '~/components/common/wizards/network/add/lib/config/config'
|
31
|
+
|
32
|
+
const props = defineProps<{
|
33
|
+
modelValue: string
|
34
|
+
}>()
|
35
|
+
|
36
|
+
const emits = defineEmits<{
|
37
|
+
(event: 'update:model-value', connectionType: string): void
|
38
|
+
}>()
|
39
|
+
|
40
|
+
const localization = computed<UI_I_Localization>(() => useLocal())
|
41
|
+
|
42
|
+
const connectionTypeLocal = computed<string>({
|
43
|
+
get() {
|
44
|
+
return props.modelValue
|
45
|
+
},
|
46
|
+
set(newValue: string) {
|
47
|
+
emits('update:model-value', newValue)
|
48
|
+
},
|
49
|
+
})
|
50
|
+
|
51
|
+
const selectConnectionTypeItems = computed<UI_I_SelectConnectionTypeItem[]>(
|
52
|
+
() => selectConnectionTypeFunc(localization.value)
|
53
|
+
)
|
54
|
+
</script>
|
55
|
+
|
56
|
+
<style scoped lang="scss">
|
57
|
+
.content {
|
58
|
+
padding: 16px 0;
|
59
|
+
|
60
|
+
:root.dark-theme {
|
61
|
+
.radio-block:not(.selected).disabled {
|
62
|
+
background-color: #1b2a371f;
|
63
|
+
opacity: unset;
|
64
|
+
}
|
65
|
+
}
|
66
|
+
.radio-block {
|
67
|
+
background-color: var(--radio-block-bg-color);
|
68
|
+
box-shadow: inset 0 0 0 1px var(--radio-block-border-color);
|
69
|
+
transition: box-shadow 0.1s ease-in-out;
|
70
|
+
padding: 12px;
|
71
|
+
border-radius: 8px;
|
72
|
+
|
73
|
+
&:not(.selected):not(.disabled) {
|
74
|
+
&:hover {
|
75
|
+
box-shadow: inset 0 0 0 1px var(--radio-block-border-hover-color);
|
76
|
+
}
|
77
|
+
}
|
78
|
+
|
79
|
+
&:not(.disabled) {
|
80
|
+
cursor: pointer;
|
81
|
+
}
|
82
|
+
|
83
|
+
&:not(.selected).disabled {
|
84
|
+
background-color: #ffffff;
|
85
|
+
opacity: 0.6;
|
86
|
+
}
|
87
|
+
|
88
|
+
&.selected {
|
89
|
+
background-color: var(--radio-block-selected-bg-color);
|
90
|
+
box-shadow: inset 0 0 0 1.5px var(--radio-block-selected-border-color);
|
91
|
+
}
|
92
|
+
|
93
|
+
&:not(:last-child) {
|
94
|
+
margin-bottom: 12px;
|
95
|
+
}
|
96
|
+
|
97
|
+
.description {
|
98
|
+
font-size: 13px;
|
99
|
+
color: #9da6ad !important;
|
100
|
+
line-height: 18px;
|
101
|
+
}
|
102
|
+
}
|
103
|
+
}
|
104
|
+
</style>
|
package/components/common/wizards/network/add/steps/selectConnectionType/SelectConnectionTypeOld.vue
ADDED
@@ -0,0 +1,80 @@
|
|
1
|
+
<template>
|
2
|
+
<div class="wizard-content-container add-networking-step">
|
3
|
+
<div class="wizard-content">
|
4
|
+
<form>
|
5
|
+
<template v-for="item in selectConnectionTypeItems" :key="item.testId">
|
6
|
+
<div v-permission="item.permission" class="radio">
|
7
|
+
<input
|
8
|
+
:id="item.id"
|
9
|
+
v-model="connectionTypeLocal"
|
10
|
+
type="radio"
|
11
|
+
:value="item.value"
|
12
|
+
name="connection-type"
|
13
|
+
/>
|
14
|
+
<label :for="item.id" :data-id="item.testId">
|
15
|
+
{{ item.label }}
|
16
|
+
</label>
|
17
|
+
</div>
|
18
|
+
<div
|
19
|
+
v-permission="item.permission"
|
20
|
+
class="add-networking-radio-button-description"
|
21
|
+
>
|
22
|
+
{{ item.description }}
|
23
|
+
</div>
|
24
|
+
</template>
|
25
|
+
</form>
|
26
|
+
</div>
|
27
|
+
</div>
|
28
|
+
</template>
|
29
|
+
|
30
|
+
<script setup lang="ts">
|
31
|
+
import type { UI_I_Localization } from '~/lib/models/interfaces'
|
32
|
+
import type { UI_I_SelectConnectionTypeItem } from '~/components/common/wizards/network/add/lib/models/interfaces'
|
33
|
+
import { selectConnectionTypeFunc } from '~/components/common/wizards/network/add/lib/config/config'
|
34
|
+
|
35
|
+
const props = defineProps<{
|
36
|
+
modelValue: string
|
37
|
+
}>()
|
38
|
+
|
39
|
+
const emits = defineEmits<{
|
40
|
+
(event: 'update:model-value', connectionType: string): void
|
41
|
+
}>()
|
42
|
+
|
43
|
+
const localization = computed<UI_I_Localization>(() => useLocal())
|
44
|
+
|
45
|
+
const connectionTypeLocal = computed<string>({
|
46
|
+
get() {
|
47
|
+
return props.modelValue
|
48
|
+
},
|
49
|
+
set(newValue: string) {
|
50
|
+
emits('update:model-value', newValue)
|
51
|
+
},
|
52
|
+
})
|
53
|
+
|
54
|
+
const selectConnectionTypeItems = computed<UI_I_SelectConnectionTypeItem[]>(
|
55
|
+
() => selectConnectionTypeFunc(localization.value)
|
56
|
+
)
|
57
|
+
</script>
|
58
|
+
|
59
|
+
<style scoped lang="scss">
|
60
|
+
.wizard-content {
|
61
|
+
height: auto;
|
62
|
+
width: inherit;
|
63
|
+
margin: 0;
|
64
|
+
|
65
|
+
.radio {
|
66
|
+
min-height: 20px;
|
67
|
+
margin: 10px 0;
|
68
|
+
|
69
|
+
label {
|
70
|
+
font-weight: 700;
|
71
|
+
margin: 6px 12px 6px 0;
|
72
|
+
}
|
73
|
+
}
|
74
|
+
|
75
|
+
.add-networking-radio-button-description {
|
76
|
+
padding-left: 20px;
|
77
|
+
color: #333;
|
78
|
+
}
|
79
|
+
}
|
80
|
+
</style>
|