bfg-common 1.6.30 → 1.6.32
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 +245 -6
- package/assets/localization/local_en.json +252 -13
- package/assets/localization/local_hy.json +246 -7
- package/assets/localization/local_kk.json +245 -6
- package/assets/localization/local_ru.json +252 -13
- package/assets/localization/local_zh.json +245 -6
- package/assets/scss/common/theme.scss +2 -2
- package/components/atoms/stack/StackBlock.vue +1 -1
- package/components/common/adapterManager/addAdapterModal/AddAdapterModalNew.vue +1 -1
- package/components/common/adapterManager/addAdapterWarningModal/AddAdapterWarningModalNew.vue +0 -1
- package/components/common/adapterManager/ui/table/adapters/AdaptersNew.vue +1 -0
- package/components/common/certificate/CertificateInfo.vue +7 -1
- package/components/common/configure/physicalAdapters/PhysicalAdapters.vue +6 -0
- package/components/common/configure/physicalAdapters/PhysicalAdaptersNew.vue +219 -192
- package/components/common/configure/physicalAdapters/PhysicalAdaptersOld.vue +6 -4
- package/components/common/configure/physicalAdapters/buttons/Buttons.vue +1 -0
- package/components/common/configure/physicalAdapters/modals/edit/Edit.vue +26 -1
- package/components/common/configure/physicalAdapters/modals/edit/EditNew.vue +30 -1
- package/components/common/configure/physicalAdapters/modals/edit/lib/models/interfaces.ts +5 -0
- package/components/common/configure/physicalAdapters/modals/edit/lib/validations/validations.ts +19 -0
- package/components/common/configure/physicalAdapters/tableView/TableViewNew.vue +12 -1
- package/components/common/configure/physicalAdapters/tableView/lib/config/physicalAdaptersTableConfigNew.ts +21 -21
- package/components/common/configure/physicalAdapters/tableView/lib/config/settings.ts +12 -5
- package/components/common/configure/physicalAdapters/tableView/lib/models/interfaces.ts +4 -1
- package/components/common/diagramMain/DiagramMain.vue +6 -0
- package/components/common/diagramMain/modals/Modals.vue +4 -0
- package/components/common/diagramMain/modals/editSettings/tabs/NetworkProperties.vue +2 -2
- package/components/common/diagramMain/modals/lib/config/vmKernelAdapter.ts +1 -1
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/MigrateVmkernelAdapter.vue +2 -2
- package/components/common/diagramMain/modals/migrateVmkernelAdapter/validations/common.ts +1 -1
- package/components/common/layout/theHeader/ThemeSwitch.vue +1 -1
- package/components/common/layout/theHeader/userMenu/modals/changePassword/New.vue +8 -9
- package/components/common/layout/theHeader/userMenu/modals/preferences/New.vue +4 -0
- package/components/common/layout/theHeader/userMenu/modals/preferences/Old.vue +9 -2
- package/components/common/layout/theHeader/userMenu/modals/preferences/changeLanguage/ChangeLanguage.vue +12 -8
- package/components/common/layout/theHeader/userMenu/modals/preferences/defaultConsole/DefaultConsole.vue +7 -1
- package/components/common/layout/theHeader/userMenu/modals/preferences/defaultConsole/lib/config/consoleOptions.ts +8 -5
- package/components/common/layout/theHeader/userMenu/modals/preferences/timeFormat/TimeFormat.vue +9 -5
- package/components/common/layout/theHeader/userMenu/modals/preferences/view/Old.vue +5 -9
- package/components/common/layout/theHeader/userMenu/modals/preferences/view/View.vue +9 -6
- package/components/common/mainNavigationPanel/MainNavigationPanelNew.vue +3 -1
- package/components/common/monitor/advanced/table/lib/models/interfaces.ts +13 -13
- package/components/common/monitor/advanced/table/lib/models/types.ts +7 -7
- package/components/common/monitor/advanced/table/tableNew/TableNew.vue +93 -93
- package/components/common/monitor/advanced/table/tableNew/lib/config/options.ts +109 -109
- package/components/common/monitor/advanced/table/tableNew/lib/utils/constructBody.ts +25 -25
- package/components/common/monitor/advanced/table/tableOld/TableOld.vue +93 -93
- package/components/common/monitor/advanced/table/tableOld/lib/config/performanceDatatable.ts +125 -125
- package/components/common/monitor/lib/utils/local_be.json +702 -702
- package/components/common/monitor/lib/utils/local_en.json +702 -702
- package/components/common/monitor/lib/utils/local_hy.json +702 -702
- package/components/common/monitor/lib/utils/local_kk.json +702 -702
- package/components/common/monitor/lib/utils/local_ru.json +702 -702
- package/components/common/monitor/lib/utils/local_zh.json +702 -702
- package/components/common/monitor/utilization/lib/utils/index.ts +33 -33
- package/components/common/noDataProvided/NoDataProvidedNew.vue +1 -1
- package/components/common/pages/backups/modals/createBackup/datastores/tableView/new/lib/config/table.ts +4 -4
- package/components/common/pages/backups/modals/createBackup/datastores/tableView/old/lib/config/table.ts +4 -4
- package/components/common/pages/hardwareHealth/HardwareHealthNew.vue +1 -1
- package/components/common/pages/hardwareHealth/historyTestimony/GraphNew.vue +1 -1
- package/components/common/pages/hardwareHealth/historyTestimony/tools/chartOptionsModal/actions/ActionsNew.vue +1 -1
- package/components/common/pages/scheduledTasks/table/lib/models/enums.ts +9 -0
- package/components/common/pages/scheduledTasks/table/new/New.vue +12 -10
- package/components/common/pages/tasks/Tasks.vue +4 -1
- package/components/common/pages/tasks/table/Table.vue +24 -22
- package/components/common/split/vertical/New.vue +42 -8
- package/components/common/split/vertical/Old.vue +31 -2
- package/components/common/split/vertical/Vertical.vue +4 -0
- package/components/common/vm/actions/add/New.vue +21 -6
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/CdDvdDrive.vue +1 -1
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/media/New.vue +5 -0
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/New.vue +1 -0
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/reservation/New.vue +2 -0
- package/components/common/vm/actions/common/select/storage/new/lib/config/table.ts +13 -15
- package/components/common/vm/actions/confirm/Confirm.vue +3 -0
- package/components/common/vm/snapshots/DetailView.vue +6 -6
- package/components/common/wizards/datastore/add/New.vue +6 -0
- package/components/common/wizards/datastore/add/steps/nameAndDevice/NameAndDeviceNew.vue +1 -1
- package/components/common/wizards/datastore/add/steps/nameAndDevice/advancedOptions/New.vue +1 -1
- package/components/common/wizards/network/add/Add.vue +13 -2
- package/components/common/wizards/network/add/AddNew.vue +22 -26
- package/components/common/wizards/network/add/lib/config/initialData.ts +4 -4
- package/components/common/wizards/network/add/lib/utils/utils.ts +1 -1
- package/components/common/wizards/network/add/steps/ipFourSettings/IpFourSettingsNew.vue +2 -8
- package/components/common/wizards/network/add/steps/portProperties/PortPropertiesNew.vue +2 -8
- package/components/common/wizards/network/add/steps/selectTargetDevice/SelectTargetDeviceNew.vue +10 -3
- package/components/common/wizards/network/add/steps/selectTargetDevice/modals/new/SelectNetwork.vue +5 -1
- package/components/common/wizards/network/add/validations/common.ts +1 -1
- package/components/common/wizards/vm/migrate/steps/computeResource/tableView/new/New.vue +31 -13
- package/components/common/wizards/vm/migrate/steps/computeResource/tableView/new/lib/config/clusterTable.ts +340 -0
- package/components/common/wizards/vm/migrate/steps/computeResource/tableView/new/lib/config/hostTable.ts +3 -1
- package/components/common/wizards/vm/migrate/steps/selectStorage/New.vue +5 -4
- package/components/common/wizards/vm/migrate/steps/selectStorage/configure/batch/New.vue +4 -0
- package/components/common/wizards/vm/migrate/steps/selectStorage/configure/batch/table/new/New.vue +3 -1
- package/components/common/wizards/vm/migrate/steps/selectStorage/configure/disk/table/new/lib/config/diskTable.ts +8 -3
- package/components/common/wizards/vm/migrate/steps/selectStorage/configure/disk/table/old/lib/config/diskTable.ts +7 -1
- package/lib/models/store/tasks/enums.ts +3 -0
- package/lib/models/store/tasks/types.ts +7 -6
- package/package.json +2 -2
- package/store/tasks/actions.ts +26 -8
- package/store/tasks/mappers/recentTasks.ts +1 -0
|
@@ -0,0 +1,340 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
UI_I_DataTableBody,
|
|
3
|
+
UI_I_DataTableOptions,
|
|
4
|
+
UI_I_DataTableHeader,
|
|
5
|
+
} from '~/node_modules/bfg-uikit/components/ui/dataTable/models/interfaces'
|
|
6
|
+
import type { UI_I_Localization } from '~/lib/models/interfaces'
|
|
7
|
+
import type { UI_I_ClusterTableItem } from '~/components/common/wizards/vm/migrate/steps/computeResource/tableView/lib/models/interfaces'
|
|
8
|
+
// import {
|
|
9
|
+
// UI_E_DeviceStatus,
|
|
10
|
+
// UI_E_DeviceStatusChipColor,
|
|
11
|
+
// UI_E_DeviceStatusIcon,
|
|
12
|
+
// } from '~/components/common/wizards/vm/migrate/steps/computeResource/tableView/new/lib/models/enums'
|
|
13
|
+
|
|
14
|
+
// // Маппинг для статусов
|
|
15
|
+
// const STATUS_MAPPING = {
|
|
16
|
+
// [UI_E_DeviceStatus.Unknown]: {
|
|
17
|
+
// icon: UI_E_DeviceStatusIcon.HelpIcon,
|
|
18
|
+
// chipColor: UI_E_DeviceStatusChipColor.Primary,
|
|
19
|
+
// },
|
|
20
|
+
// [UI_E_DeviceStatus.Supported]: {
|
|
21
|
+
// icon: UI_E_DeviceStatusIcon.StatusCheck,
|
|
22
|
+
// chipColor: UI_E_DeviceStatusChipColor.Green,
|
|
23
|
+
// },
|
|
24
|
+
// [UI_E_DeviceStatus.NotSupported]: {
|
|
25
|
+
// icon: UI_E_DeviceStatusIcon.Close,
|
|
26
|
+
// chipColor: UI_E_DeviceStatusChipColor.Red,
|
|
27
|
+
// },
|
|
28
|
+
// }
|
|
29
|
+
|
|
30
|
+
export const getHeaderDataFunc = (
|
|
31
|
+
localization: UI_I_Localization
|
|
32
|
+
): UI_I_DataTableHeader[] => [
|
|
33
|
+
{
|
|
34
|
+
col: 'col0',
|
|
35
|
+
colName: 'name',
|
|
36
|
+
text: localization.common.name,
|
|
37
|
+
isSortable: true,
|
|
38
|
+
sort: 'asc',
|
|
39
|
+
width: '180px',
|
|
40
|
+
show: true,
|
|
41
|
+
filter: false,
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
col: 'col1',
|
|
45
|
+
colName: 'available_cpu',
|
|
46
|
+
text: localization.common.availableCpu,
|
|
47
|
+
isSortable: true,
|
|
48
|
+
sort: 'asc',
|
|
49
|
+
width: '96px',
|
|
50
|
+
show: true,
|
|
51
|
+
filter: false,
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
col: 'col2',
|
|
55
|
+
colName: 'available_memory',
|
|
56
|
+
text: localization.common.availableMemory,
|
|
57
|
+
isSortable: true,
|
|
58
|
+
sort: 'asc',
|
|
59
|
+
width: '96px',
|
|
60
|
+
show: true,
|
|
61
|
+
filter: false,
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
col: 'col3',
|
|
65
|
+
colName: 'available_storage',
|
|
66
|
+
text: localization.common.availableStorage,
|
|
67
|
+
isSortable: true,
|
|
68
|
+
sort: 'asc',
|
|
69
|
+
width: '96px',
|
|
70
|
+
show: true,
|
|
71
|
+
filter: false,
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
col: 'col4',
|
|
75
|
+
colName: 'drs',
|
|
76
|
+
text: localization.common.vSphere_DRS,
|
|
77
|
+
isSortable: true,
|
|
78
|
+
sort: 'asc',
|
|
79
|
+
width: '96px',
|
|
80
|
+
show: true,
|
|
81
|
+
filter: false,
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
col: 'col5',
|
|
85
|
+
colName: 'ha',
|
|
86
|
+
text: localization.common.vSphere_HA,
|
|
87
|
+
isSortable: true,
|
|
88
|
+
sort: 'asc',
|
|
89
|
+
width: '96px',
|
|
90
|
+
show: true,
|
|
91
|
+
filter: false,
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
col: 'col6',
|
|
95
|
+
colName: 'total_cpu',
|
|
96
|
+
text: localization.common.totalCpu,
|
|
97
|
+
isSortable: true,
|
|
98
|
+
sort: 'asc',
|
|
99
|
+
width: '96px',
|
|
100
|
+
show: true,
|
|
101
|
+
filter: false,
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
col: 'col7',
|
|
105
|
+
colName: 'total_memory',
|
|
106
|
+
text: localization.common.totalMemory,
|
|
107
|
+
isSortable: true,
|
|
108
|
+
sort: 'asc',
|
|
109
|
+
width: '96px',
|
|
110
|
+
show: true,
|
|
111
|
+
filter: false,
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
col: 'col8',
|
|
115
|
+
colName: 'total_storage',
|
|
116
|
+
text: localization.common.totalStorage,
|
|
117
|
+
isSortable: true,
|
|
118
|
+
sort: 'asc',
|
|
119
|
+
width: '96px',
|
|
120
|
+
show: true,
|
|
121
|
+
filter: false,
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
col: 'col9',
|
|
125
|
+
colName: 'vms',
|
|
126
|
+
text: localization.common.vms,
|
|
127
|
+
isSortable: true,
|
|
128
|
+
sort: 'asc',
|
|
129
|
+
width: '96px',
|
|
130
|
+
show: true,
|
|
131
|
+
filter: false,
|
|
132
|
+
},
|
|
133
|
+
{
|
|
134
|
+
col: 'col10',
|
|
135
|
+
colName: 'hosts',
|
|
136
|
+
text: localization.common.hosts,
|
|
137
|
+
isSortable: true,
|
|
138
|
+
sort: 'asc',
|
|
139
|
+
width: '96px',
|
|
140
|
+
show: true,
|
|
141
|
+
filter: false,
|
|
142
|
+
},
|
|
143
|
+
{
|
|
144
|
+
col: 'col11',
|
|
145
|
+
colName: 'cpus',
|
|
146
|
+
text: localization.common.cpus,
|
|
147
|
+
isSortable: true,
|
|
148
|
+
sort: 'asc',
|
|
149
|
+
width: '96px',
|
|
150
|
+
show: true,
|
|
151
|
+
filter: false,
|
|
152
|
+
},
|
|
153
|
+
{
|
|
154
|
+
col: 'col12',
|
|
155
|
+
colName: 'datastores',
|
|
156
|
+
text: localization.common.datastores,
|
|
157
|
+
isSortable: true,
|
|
158
|
+
sort: 'asc',
|
|
159
|
+
width: '96px',
|
|
160
|
+
show: true,
|
|
161
|
+
filter: false,
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
col: 'col13',
|
|
165
|
+
colName: 'vsan',
|
|
166
|
+
text: localization.common.vSAN,
|
|
167
|
+
isSortable: true,
|
|
168
|
+
sort: 'asc',
|
|
169
|
+
width: '96px',
|
|
170
|
+
show: true,
|
|
171
|
+
filter: false,
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
col: 'col14',
|
|
175
|
+
colName: 'vc',
|
|
176
|
+
text: localization.common.vc,
|
|
177
|
+
isSortable: true,
|
|
178
|
+
sort: 'asc',
|
|
179
|
+
width: '96px',
|
|
180
|
+
show: true,
|
|
181
|
+
filter: false,
|
|
182
|
+
},
|
|
183
|
+
{
|
|
184
|
+
col: 'col15',
|
|
185
|
+
colName: 'evc_cpu_mode',
|
|
186
|
+
text: localization.common.evcCpuMode,
|
|
187
|
+
isSortable: true,
|
|
188
|
+
sort: 'asc',
|
|
189
|
+
width: '96px',
|
|
190
|
+
show: true,
|
|
191
|
+
filter: false,
|
|
192
|
+
},
|
|
193
|
+
{
|
|
194
|
+
col: 'col16',
|
|
195
|
+
colName: 'evc_graphics_mode',
|
|
196
|
+
text: localization.common.evcGraphicsMode,
|
|
197
|
+
isSortable: true,
|
|
198
|
+
sort: 'asc',
|
|
199
|
+
width: '96px',
|
|
200
|
+
show: true,
|
|
201
|
+
filter: false,
|
|
202
|
+
},
|
|
203
|
+
]
|
|
204
|
+
export const options: UI_I_DataTableOptions = {
|
|
205
|
+
perPageOptions: [{ text: '10', value: 100, default: true }],
|
|
206
|
+
isSelectable: true,
|
|
207
|
+
selectType: 'radio',
|
|
208
|
+
showPagination: false,
|
|
209
|
+
showPageInfo: false,
|
|
210
|
+
isSortable: true,
|
|
211
|
+
server: true,
|
|
212
|
+
isResizable: true,
|
|
213
|
+
showSelectedRows: false,
|
|
214
|
+
showColumnManager: true,
|
|
215
|
+
inModal: true,
|
|
216
|
+
inBlock: false,
|
|
217
|
+
// isFocusable: false,
|
|
218
|
+
// showPaginationOnTop: false,
|
|
219
|
+
// showSearch: false,
|
|
220
|
+
// withActions: false,
|
|
221
|
+
// showExport: false,
|
|
222
|
+
// withCollapse: false,
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
export const getBodyDataFunc = (
|
|
226
|
+
bodyData: UI_I_ClusterTableItem[],
|
|
227
|
+
_localization: UI_I_Localization
|
|
228
|
+
): UI_I_DataTableBody[] => {
|
|
229
|
+
const { $binary }: any = useNuxtApp()
|
|
230
|
+
|
|
231
|
+
return bodyData.map((cluster, index: number) => {
|
|
232
|
+
// const statusKey = host.state
|
|
233
|
+
// ? UI_E_DeviceStatus.Unknown
|
|
234
|
+
// : UI_E_DeviceStatus.Supported
|
|
235
|
+
// const statusData = {
|
|
236
|
+
// ...STATUS_MAPPING[statusKey],
|
|
237
|
+
// testId: `${host.name}-${index}-status`,
|
|
238
|
+
// }
|
|
239
|
+
|
|
240
|
+
return {
|
|
241
|
+
row: index,
|
|
242
|
+
collapse: false,
|
|
243
|
+
isHiddenCollapse: false,
|
|
244
|
+
collapseToggle: false,
|
|
245
|
+
|
|
246
|
+
data: [
|
|
247
|
+
{
|
|
248
|
+
key: 'icon',
|
|
249
|
+
col: 'col0',
|
|
250
|
+
text: cluster.name,
|
|
251
|
+
data: {
|
|
252
|
+
iconClassName: 'vsphere-icon-cluster',
|
|
253
|
+
},
|
|
254
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
255
|
+
},
|
|
256
|
+
|
|
257
|
+
{
|
|
258
|
+
col: 'col1',
|
|
259
|
+
text: $binary.roundHz(cluster.available_cpu),
|
|
260
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
261
|
+
},
|
|
262
|
+
{
|
|
263
|
+
col: 'col2',
|
|
264
|
+
text: $binary.round(cluster.available_memory),
|
|
265
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
266
|
+
},
|
|
267
|
+
{
|
|
268
|
+
col: 'col3',
|
|
269
|
+
text: $binary.round(cluster.available_storage),
|
|
270
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
271
|
+
},
|
|
272
|
+
{
|
|
273
|
+
col: 'col4',
|
|
274
|
+
text: cluster.drs,
|
|
275
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
276
|
+
},
|
|
277
|
+
{
|
|
278
|
+
col: 'col5',
|
|
279
|
+
text: cluster.ha,
|
|
280
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
281
|
+
},
|
|
282
|
+
{
|
|
283
|
+
col: 'col6',
|
|
284
|
+
text: $binary.roundHz(cluster.total_cpu),
|
|
285
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
286
|
+
},
|
|
287
|
+
{
|
|
288
|
+
col: 'col7',
|
|
289
|
+
text: $binary.round(cluster.total_memory),
|
|
290
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
291
|
+
},
|
|
292
|
+
{
|
|
293
|
+
col: 'col8',
|
|
294
|
+
text: $binary.round(cluster.total_storage),
|
|
295
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
296
|
+
},
|
|
297
|
+
{
|
|
298
|
+
col: 'col9',
|
|
299
|
+
text: cluster.vms,
|
|
300
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
301
|
+
},
|
|
302
|
+
{
|
|
303
|
+
col: 'col10',
|
|
304
|
+
text: cluster.hosts,
|
|
305
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
306
|
+
},
|
|
307
|
+
{
|
|
308
|
+
col: 'col11',
|
|
309
|
+
text: cluster.cpus,
|
|
310
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
311
|
+
},
|
|
312
|
+
{
|
|
313
|
+
col: 'col12',
|
|
314
|
+
text: cluster.datastores,
|
|
315
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
316
|
+
},
|
|
317
|
+
{
|
|
318
|
+
col: 'col13',
|
|
319
|
+
text: cluster.vsan,
|
|
320
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
321
|
+
},
|
|
322
|
+
{
|
|
323
|
+
col: 'col14',
|
|
324
|
+
text: cluster.vc,
|
|
325
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
326
|
+
},
|
|
327
|
+
{
|
|
328
|
+
col: 'col15',
|
|
329
|
+
text: cluster.evc_cpu_mode,
|
|
330
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
331
|
+
},
|
|
332
|
+
{
|
|
333
|
+
col: 'col16',
|
|
334
|
+
text: cluster.evc_graphics_mode,
|
|
335
|
+
testId: `migrate-cluster-table-item-${index}`,
|
|
336
|
+
},
|
|
337
|
+
],
|
|
338
|
+
}
|
|
339
|
+
})
|
|
340
|
+
}
|
|
@@ -222,7 +222,9 @@ export const getBodyDataFunc = (
|
|
|
222
222
|
key: 'icon',
|
|
223
223
|
col: 'col0',
|
|
224
224
|
text: host.name,
|
|
225
|
-
data:
|
|
225
|
+
data: {
|
|
226
|
+
iconClassName: `vsphere-icon-${hostIconByState[host.state]}`,
|
|
227
|
+
},
|
|
226
228
|
testId: `migrate-host-table-item-${index}`,
|
|
227
229
|
},
|
|
228
230
|
|
|
@@ -27,13 +27,14 @@
|
|
|
27
27
|
:is-hide-select-disk-format="props.isHideSelectDiskFormat"
|
|
28
28
|
>
|
|
29
29
|
<template v-if="isShowSelectedPerDisks" #buttonConfirm>
|
|
30
|
-
<button
|
|
31
|
-
|
|
32
|
-
|
|
30
|
+
<ui-button
|
|
31
|
+
test-id="apply-selected-per-disks-button"
|
|
32
|
+
type="primary"
|
|
33
|
+
size="sm"
|
|
33
34
|
@click="onApplyChanges"
|
|
34
35
|
>
|
|
35
36
|
{{ localization.common.confirm }}
|
|
36
|
-
</button>
|
|
37
|
+
</ui-button>
|
|
37
38
|
</template>
|
|
38
39
|
</common-wizards-vm-migrate-steps-select-storage-configure-batch>
|
|
39
40
|
|
package/components/common/wizards/vm/migrate/steps/selectStorage/configure/batch/table/new/New.vue
CHANGED
|
@@ -118,9 +118,11 @@ watch(
|
|
|
118
118
|
const onSorting = (value: string): void => {
|
|
119
119
|
emits('sort', value)
|
|
120
120
|
}
|
|
121
|
+
|
|
122
|
+
/* TODO: если передать в emit selectedStorageKeyLocal.value, то не работает */
|
|
121
123
|
const onSelectRow = (value: UI_I_DataTableBody[]): void => {
|
|
122
124
|
selectedStorageKeyLocal.value = value?.[0].row as number
|
|
123
|
-
emits('select-storage',
|
|
125
|
+
emits('select-storage', value?.[0].row as number)
|
|
124
126
|
}
|
|
125
127
|
</script>
|
|
126
128
|
|
|
@@ -158,7 +158,6 @@ export const getBodyDataFunc = (
|
|
|
158
158
|
bodyData: UI_I_StorageConfigurePerDiskItem[],
|
|
159
159
|
localization: UI_I_Localization
|
|
160
160
|
): UI_I_DataTableBody[] => {
|
|
161
|
-
|
|
162
161
|
return bodyData.map((disk, index: number) => {
|
|
163
162
|
const diskFormat =
|
|
164
163
|
index === 0 ? 'N/A' : UI_E_SelectStorageDiskFormat[disk.disk_format]
|
|
@@ -184,6 +183,12 @@ export const getBodyDataFunc = (
|
|
|
184
183
|
: 'False'
|
|
185
184
|
: localization.common[diskSharingKey]
|
|
186
185
|
|
|
186
|
+
const diskCache = disk.extra.cache
|
|
187
|
+
const diskCacheValue =
|
|
188
|
+
!diskCache || ['none', 'n/a'].includes(diskCache.toLowerCase())
|
|
189
|
+
? '--'
|
|
190
|
+
: disk.extra.cache
|
|
191
|
+
|
|
187
192
|
return {
|
|
188
193
|
row: index,
|
|
189
194
|
collapse: false,
|
|
@@ -221,10 +226,10 @@ export const getBodyDataFunc = (
|
|
|
221
226
|
data: diskSharingData,
|
|
222
227
|
},
|
|
223
228
|
|
|
224
|
-
{ col: 'col6', text: disk.extra.target },
|
|
229
|
+
{ col: 'col6', text: disk.extra.target || '--' },
|
|
225
230
|
{
|
|
226
231
|
col: 'col7',
|
|
227
|
-
text:
|
|
232
|
+
text: diskCacheValue,
|
|
228
233
|
},
|
|
229
234
|
{ col: 'col8', text: disk.extra.io_control },
|
|
230
235
|
{
|
|
@@ -79,6 +79,12 @@ export const bodyItems = (
|
|
|
79
79
|
? disk[vmMigrateDiskTableItemKeys[2]]
|
|
80
80
|
: `${disk.extra.disk_source} (${disk.extra.disk_size} ${localization.common.mb} )`
|
|
81
81
|
|
|
82
|
+
const diskCache = disk.extra[vmMigrateDiskTableItemKeys[7]]
|
|
83
|
+
const diskCacheValue =
|
|
84
|
+
!diskCache || ['none', 'n/a'].includes(diskCache.toLowerCase())
|
|
85
|
+
? '--'
|
|
86
|
+
: disk.extra[vmMigrateDiskTableItemKeys[7]]
|
|
87
|
+
|
|
82
88
|
bodyItems.push([
|
|
83
89
|
{
|
|
84
90
|
key: 'col0',
|
|
@@ -124,7 +130,7 @@ export const bodyItems = (
|
|
|
124
130
|
},
|
|
125
131
|
{
|
|
126
132
|
key: 'col7',
|
|
127
|
-
text:
|
|
133
|
+
text: diskCacheValue,
|
|
128
134
|
id: key,
|
|
129
135
|
testId: `disk-table-${key}`,
|
|
130
136
|
},
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
export type UI_T_TasksStateLoading = 'tasks' | 'recentTasks'
|
|
2
2
|
export type UI_T_TaskStatus =
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
3
|
+
| 0 // queued
|
|
4
|
+
| 1 // running
|
|
5
|
+
| 2 // completed
|
|
6
|
+
| 3 // failed
|
|
7
|
+
| 4 // canceled
|
|
8
|
+
| 5 // retrying
|
|
9
|
+
| 6 // warning
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bfg-common",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "1.6.
|
|
4
|
+
"version": "1.6.32",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "nuxt build",
|
|
7
7
|
"dev": "nuxt dev --port=3002",
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"@vueuse/core": "10.1.2",
|
|
19
19
|
"@vueuse/nuxt": "10.1.2",
|
|
20
20
|
"bfg-nuxt-3-graph": "1.0.27",
|
|
21
|
-
"bfg-uikit": "1.1.
|
|
21
|
+
"bfg-uikit": "1.1.26",
|
|
22
22
|
"eslint-config-prettier": "^8.5.0",
|
|
23
23
|
"eslint-plugin-myrules": "file:./eslint",
|
|
24
24
|
"nuxt": "3.11.2",
|
package/store/tasks/actions.ts
CHANGED
|
@@ -18,6 +18,7 @@ import type {
|
|
|
18
18
|
} from '~/lib/models/store/tasks/interfaces'
|
|
19
19
|
import type { UI_I_TasksState } from '~/store/tasks/lib/models/interfaces'
|
|
20
20
|
import type { UI_I_RefreshStack } from '~/store/main/lib/interfaces'
|
|
21
|
+
import type { UI_T_Project } from '~/lib/models/types'
|
|
21
22
|
import { tasksConstructor } from '~/store/tasks/mappers/tasks'
|
|
22
23
|
import { recentTasks } from '~/store/tasks/mappers/recentTasks'
|
|
23
24
|
|
|
@@ -28,9 +29,13 @@ export default {
|
|
|
28
29
|
state: UI_I_TasksState
|
|
29
30
|
dispatch: <T>(arg0: string, arg1: T, arg2: UI_I_CommitOptions) => void
|
|
30
31
|
},
|
|
31
|
-
payload:
|
|
32
|
+
payload: {
|
|
33
|
+
data: UI_I_DataTableQuery
|
|
34
|
+
project: UI_T_Project
|
|
35
|
+
}
|
|
32
36
|
): Promise<API_UI_I_Error | void> {
|
|
33
|
-
const {
|
|
37
|
+
const { data, project } = payload
|
|
38
|
+
const { page, pageSize, sortBy, filter } = data
|
|
34
39
|
|
|
35
40
|
const query: UI_I_TableQuery = {
|
|
36
41
|
page_size: pageSize,
|
|
@@ -38,7 +43,21 @@ export default {
|
|
|
38
43
|
}
|
|
39
44
|
|
|
40
45
|
if (sortBy) query.sortBy = sortBy
|
|
41
|
-
if (filter)
|
|
46
|
+
if (filter) {
|
|
47
|
+
if (project === 'procurator') {
|
|
48
|
+
query.filter = filter
|
|
49
|
+
} else {
|
|
50
|
+
const filters = filter.split(',')
|
|
51
|
+
filters.forEach((item) => {
|
|
52
|
+
const [field, value] = item.split('.')
|
|
53
|
+
|
|
54
|
+
if (field && value) {
|
|
55
|
+
// @ts-ignore
|
|
56
|
+
query[field] = value
|
|
57
|
+
}
|
|
58
|
+
})
|
|
59
|
+
}
|
|
60
|
+
}
|
|
42
61
|
|
|
43
62
|
const queryJson: string = JSON.stringify({ type: 'tasks', ...query })
|
|
44
63
|
const lastQuery: string = context.state.taskQuery || ''
|
|
@@ -63,7 +82,9 @@ export default {
|
|
|
63
82
|
value: true,
|
|
64
83
|
})
|
|
65
84
|
},
|
|
66
|
-
onResponse({
|
|
85
|
+
onResponse({
|
|
86
|
+
response,
|
|
87
|
+
}: API_UI_I_Response<API_UI_I_Task<string> | null>) {
|
|
67
88
|
const tasks = tasksConstructor(response._data)
|
|
68
89
|
|
|
69
90
|
context.commit('M_SET_TASKS_LIST', tasks)
|
|
@@ -140,10 +161,7 @@ export default {
|
|
|
140
161
|
payload: string
|
|
141
162
|
): Promise<void> {
|
|
142
163
|
// Скрываем кнопку cancel
|
|
143
|
-
context.commit(
|
|
144
|
-
'M_HIDE_CANCEL_RECENT_TASK_BY_ID',
|
|
145
|
-
payload
|
|
146
|
-
)
|
|
164
|
+
context.commit('M_HIDE_CANCEL_RECENT_TASK_BY_ID', payload)
|
|
147
165
|
const { error } = await useMyFetch<
|
|
148
166
|
API_UI_I_RecentTask<string>,
|
|
149
167
|
API_UI_I_Error
|