bfg-common 1.3.391 → 1.3.392
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/img/icons/icons-sprite-dark-1.svg +1 -360
- package/assets/img/icons/icons-sprite-dark-2.svg +1 -296
- package/assets/img/icons/icons-sprite-dark-3.svg +1 -221
- package/assets/img/icons/icons-sprite-dark-4.svg +1 -247
- package/assets/img/icons/icons-sprite-light-1.svg +1 -360
- package/assets/img/icons/icons-sprite-light-2.svg +1 -296
- package/assets/img/icons/icons-sprite-light-3.svg +1 -221
- package/assets/img/icons/icons-sprite-light-4.svg +1 -247
- package/assets/localization/local_be.json +5 -1
- package/assets/localization/local_en.json +5 -1
- package/assets/localization/local_hy.json +5 -1
- package/assets/localization/local_kk.json +5 -1
- package/assets/localization/local_ru.json +5 -1
- package/assets/localization/local_zh.json +5 -1
- package/assets/scss/common/icons/icons.scss +0 -1
- package/components/atoms/loader/Loader.vue +30 -30
- package/components/atoms/loader/PreLoader.vue +38 -38
- package/components/atoms/switch/Switch.vue +111 -111
- package/components/atoms/table/compact/Compact.vue +526 -526
- package/components/common/adapterManager/ui/table/Header.vue +93 -93
- package/components/common/adapterManager/ui/table/Table.vue +162 -162
- package/components/common/context/Context.vue +99 -99
- package/components/common/lib/config/states.ts +126 -126
- package/components/common/pages/hardwareHealth/tableView/TableView.vue +1 -42
- package/components/common/pages/hardwareHealth/tableView/lib/config/alertWarningTable.ts +8 -15
- package/components/common/pages/hardwareHealth/tableView/lib/config/sensorTable.ts +1 -1
- package/components/common/resource/progressBlock/ProgressBlock.vue +142 -142
- package/components/common/split/horizontal/Horizontal.vue +49 -307
- package/components/common/split/horizontal/HorizontalOld.vue +307 -0
- package/components/common/vm/actions/add/Add.vue +602 -602
- package/components/common/vm/actions/clone/Clone.vue +518 -518
- package/components/common/vm/actions/common/customizeHardware/CustomizeHardware.vue +273 -273
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/VirtualHardware.vue +697 -697
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/CdDvdDrive.vue +256 -256
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/NewHardDisk.vue +458 -458
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/newNetwork/NewNetwork.vue +304 -304
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/NewPciDevice.vue +167 -167
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/newUsbController/NewUsbController.vue +82 -82
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/other/Other.vue +32 -32
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/videoCard/VideoCard.vue +182 -182
- package/components/common/vm/actions/common/customizeHardware/vmoptions/bootOptions/BootOptions.vue +114 -114
- package/components/common/vm/actions/common/customizeHardware/vmoptions/generalOptions/GeneralOptions.vue +188 -188
- package/components/common/vm/actions/common/customizeHardware/vmoptions/tools/Tools.vue +72 -72
- package/components/common/vm/actions/common/select/computeResource/ComputeResource.vue +164 -164
- package/components/common/vm/actions/common/select/name/Name.vue +235 -235
- package/components/common/vm/actions/common/select/storage/Storage.vue +198 -198
- package/components/common/vm/actions/editSettings/EditSettings.vue +316 -316
- package/components/common/weekSelect/lib/config/options.ts +10 -10
- package/components/common/wizards/datastore/add/Add.vue +436 -436
- package/components/common/wizards/datastore/add/lib/config/stepItems.ts +191 -191
- package/components/common/wizards/datastore/add/lib/models/interfaces.ts +38 -38
- package/components/common/wizards/datastore/add/lib/utils.ts +70 -70
- package/components/common/wizards/datastore/add/local/createName/CreateName.vue +160 -160
- package/components/common/wizards/datastore/add/nfs/Nfs.vue +112 -112
- package/components/common/wizards/datastore/add/nfs/accessibility/Accessibility.vue +104 -104
- package/components/common/wizards/datastore/add/nfs/accessibility/tablesView/lib/config/compatibleTable.ts +62 -62
- package/components/common/wizards/datastore/add/nfs/accessibility/tablesView/lib/config/hostsTableItems.ts +53 -53
- package/components/common/wizards/datastore/add/readyComplete/ReadyComplete.vue +86 -86
- package/components/common/wizards/datastore/add/readyComplete/lib/config/propertiesDetails.ts +184 -184
- package/components/common/wizards/datastore/add/sharedStorm/deviceSelection/DeviceSelection.vue +459 -459
- package/components/common/wizards/datastore/add/types/Types.vue +80 -80
- package/components/common/wizards/datastore/add/types/lib/config/typeOptions.ts +49 -49
- package/composables/useAppVersion.ts +21 -21
- package/composables/useEnvLanguage.ts +20 -20
- package/lib/utils/sendTask.ts +72 -72
- package/minify.js +146 -146
- package/package.json +1 -1
- package/plugins/spice-console/spice.console.ts +147 -147
- package/public/spice-console/application/codec.js +263 -263
- package/public/spice-console/lib/rasterEngine.js +907 -907
- package/public/spice-console/network/spicechannel.js +375 -375
- package/store/main/lib/interfaces.ts +9 -9
- package/store/tasks/actions.ts +133 -133
- package/store/tasks/getters.ts +25 -25
- package/store/tasks/lib/models/interfaces.ts +18 -18
- package/store/tasks/mutations.ts +58 -58
- package/store/tasks/state.ts +16 -16
- package/assets/img/icons/icons-sprite-dark-1-old.svg +0 -1
- package/assets/img/icons/icons-sprite-dark-2-old.svg +0 -1
- package/assets/img/icons/icons-sprite-dark-3-old.svg +0 -1
- package/assets/img/icons/icons-sprite-dark-4-old.svg +0 -1
- package/assets/img/icons/icons-sprite-dark-7.svg +0 -8
- package/assets/img/icons/icons-sprite-light-1-old.svg +0 -1
- package/assets/img/icons/icons-sprite-light-2-old.svg +0 -1
- package/assets/img/icons/icons-sprite-light-3-old.svg +0 -1
- package/assets/img/icons/icons-sprite-light-4-old.svg +0 -1
- package/assets/img/icons/icons-sprite-light-7.svg +0 -8
- package/assets/scss/common/icons/icons-7.scss +0 -29
- package/components/common/pages/hardwareHealth/tableView/modal/sensorWarning.vue +0 -63
|
@@ -1,99 +1,99 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div
|
|
3
|
-
:id="elementId"
|
|
4
|
-
class="context-popup"
|
|
5
|
-
:style="{
|
|
6
|
-
top: currentContextMenuY,
|
|
7
|
-
left: currentContextMenuX,
|
|
8
|
-
}"
|
|
9
|
-
>
|
|
10
|
-
<common-context-recursion
|
|
11
|
-
:action-loading="props.actionLoading"
|
|
12
|
-
:items="props.contextMenu.items"
|
|
13
|
-
@select-item="selectItem"
|
|
14
|
-
/>
|
|
15
|
-
</div>
|
|
16
|
-
</template>
|
|
17
|
-
|
|
18
|
-
<script setup lang="ts">
|
|
19
|
-
import {
|
|
20
|
-
UI_I_ContextMenuItem,
|
|
21
|
-
UI_I_ContextMenu,
|
|
22
|
-
} from '~/components/common/context/lib/models/interfaces'
|
|
23
|
-
|
|
24
|
-
const props = defineProps<{
|
|
25
|
-
contextMenu: UI_I_ContextMenu
|
|
26
|
-
actionLoading: string | null
|
|
27
|
-
}>()
|
|
28
|
-
const emits = defineEmits<{
|
|
29
|
-
(event: 'select-item', value: UI_I_ContextMenuItem): void
|
|
30
|
-
(event: 'hide'): void
|
|
31
|
-
}>()
|
|
32
|
-
const selectItem = (item: UI_I_ContextMenuItem): void => {
|
|
33
|
-
emits('select-item', item)
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
const elementId = ref<string>(`context-${useUniqueId()}`)
|
|
37
|
-
|
|
38
|
-
const currentContextMenuY = ref<string>('')
|
|
39
|
-
const currentContextMenuX = ref<string>('')
|
|
40
|
-
const setCurrentPositionsPopup = (): void => {
|
|
41
|
-
const contextMenuY = props.contextMenu.y
|
|
42
|
-
const contextMenuX = props.contextMenu.x
|
|
43
|
-
|
|
44
|
-
const contextWrap: HTMLElement | null =
|
|
45
|
-
document.querySelector(`#${elementId.value} .context-wrap`)
|
|
46
|
-
const contextW = contextWrap?.offsetWidth || 0
|
|
47
|
-
const contextH = contextWrap?.offsetHeight || 0
|
|
48
|
-
|
|
49
|
-
const windowW = window.innerWidth
|
|
50
|
-
const windowH = window.innerHeight
|
|
51
|
-
|
|
52
|
-
if (contextMenuY + contextH >= windowH) {
|
|
53
|
-
currentContextMenuY.value = 'auto'
|
|
54
|
-
} else {
|
|
55
|
-
currentContextMenuY.value = `${contextMenuY}px`
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
if (contextMenuX + contextW >= windowW) {
|
|
59
|
-
const divisionW = windowW - contextW
|
|
60
|
-
currentContextMenuX.value = `${divisionW}px`
|
|
61
|
-
} else {
|
|
62
|
-
currentContextMenuX.value = `${contextMenuX}px`
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
const windowMousedown = (): void => {
|
|
67
|
-
emits('hide')
|
|
68
|
-
}
|
|
69
|
-
watch(
|
|
70
|
-
() => props.contextMenu.y,
|
|
71
|
-
(newValue: number) => {
|
|
72
|
-
if (!newValue) return
|
|
73
|
-
|
|
74
|
-
if (newValue < 0) {
|
|
75
|
-
window.removeEventListener('mousedown', windowMousedown)
|
|
76
|
-
} else {
|
|
77
|
-
window.addEventListener('mousedown', windowMousedown)
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
setTimeout(() => {
|
|
81
|
-
setCurrentPositionsPopup()
|
|
82
|
-
}, 0)
|
|
83
|
-
}
|
|
84
|
-
)
|
|
85
|
-
</script>
|
|
86
|
-
|
|
87
|
-
<style scoped lang="scss">
|
|
88
|
-
.context-popup {
|
|
89
|
-
top: -9999px;
|
|
90
|
-
left: -9999px;
|
|
91
|
-
bottom: 0;
|
|
92
|
-
border: none;
|
|
93
|
-
box-sizing: content-box;
|
|
94
|
-
overflow: visible;
|
|
95
|
-
display: block;
|
|
96
|
-
position: fixed;
|
|
97
|
-
z-index: 10002;
|
|
98
|
-
}
|
|
99
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
:id="elementId"
|
|
4
|
+
class="context-popup"
|
|
5
|
+
:style="{
|
|
6
|
+
top: currentContextMenuY,
|
|
7
|
+
left: currentContextMenuX,
|
|
8
|
+
}"
|
|
9
|
+
>
|
|
10
|
+
<common-context-recursion
|
|
11
|
+
:action-loading="props.actionLoading"
|
|
12
|
+
:items="props.contextMenu.items"
|
|
13
|
+
@select-item="selectItem"
|
|
14
|
+
/>
|
|
15
|
+
</div>
|
|
16
|
+
</template>
|
|
17
|
+
|
|
18
|
+
<script setup lang="ts">
|
|
19
|
+
import {
|
|
20
|
+
UI_I_ContextMenuItem,
|
|
21
|
+
UI_I_ContextMenu,
|
|
22
|
+
} from '~/components/common/context/lib/models/interfaces'
|
|
23
|
+
|
|
24
|
+
const props = defineProps<{
|
|
25
|
+
contextMenu: UI_I_ContextMenu
|
|
26
|
+
actionLoading: string | null
|
|
27
|
+
}>()
|
|
28
|
+
const emits = defineEmits<{
|
|
29
|
+
(event: 'select-item', value: UI_I_ContextMenuItem): void
|
|
30
|
+
(event: 'hide'): void
|
|
31
|
+
}>()
|
|
32
|
+
const selectItem = (item: UI_I_ContextMenuItem): void => {
|
|
33
|
+
emits('select-item', item)
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
const elementId = ref<string>(`context-${useUniqueId()}`)
|
|
37
|
+
|
|
38
|
+
const currentContextMenuY = ref<string>('')
|
|
39
|
+
const currentContextMenuX = ref<string>('')
|
|
40
|
+
const setCurrentPositionsPopup = (): void => {
|
|
41
|
+
const contextMenuY = props.contextMenu.y
|
|
42
|
+
const contextMenuX = props.contextMenu.x
|
|
43
|
+
|
|
44
|
+
const contextWrap: HTMLElement | null =
|
|
45
|
+
document.querySelector(`#${elementId.value} .context-wrap`)
|
|
46
|
+
const contextW = contextWrap?.offsetWidth || 0
|
|
47
|
+
const contextH = contextWrap?.offsetHeight || 0
|
|
48
|
+
|
|
49
|
+
const windowW = window.innerWidth
|
|
50
|
+
const windowH = window.innerHeight
|
|
51
|
+
|
|
52
|
+
if (contextMenuY + contextH >= windowH) {
|
|
53
|
+
currentContextMenuY.value = 'auto'
|
|
54
|
+
} else {
|
|
55
|
+
currentContextMenuY.value = `${contextMenuY}px`
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
if (contextMenuX + contextW >= windowW) {
|
|
59
|
+
const divisionW = windowW - contextW
|
|
60
|
+
currentContextMenuX.value = `${divisionW}px`
|
|
61
|
+
} else {
|
|
62
|
+
currentContextMenuX.value = `${contextMenuX}px`
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
const windowMousedown = (): void => {
|
|
67
|
+
emits('hide')
|
|
68
|
+
}
|
|
69
|
+
watch(
|
|
70
|
+
() => props.contextMenu.y,
|
|
71
|
+
(newValue: number) => {
|
|
72
|
+
if (!newValue) return
|
|
73
|
+
|
|
74
|
+
if (newValue < 0) {
|
|
75
|
+
window.removeEventListener('mousedown', windowMousedown)
|
|
76
|
+
} else {
|
|
77
|
+
window.addEventListener('mousedown', windowMousedown)
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
setTimeout(() => {
|
|
81
|
+
setCurrentPositionsPopup()
|
|
82
|
+
}, 0)
|
|
83
|
+
}
|
|
84
|
+
)
|
|
85
|
+
</script>
|
|
86
|
+
|
|
87
|
+
<style scoped lang="scss">
|
|
88
|
+
.context-popup {
|
|
89
|
+
top: -9999px;
|
|
90
|
+
left: -9999px;
|
|
91
|
+
bottom: 0;
|
|
92
|
+
border: none;
|
|
93
|
+
box-sizing: content-box;
|
|
94
|
+
overflow: visible;
|
|
95
|
+
display: block;
|
|
96
|
+
position: fixed;
|
|
97
|
+
z-index: 10002;
|
|
98
|
+
}
|
|
99
|
+
</style>
|
|
@@ -1,126 +1,126 @@
|
|
|
1
|
-
export const clusterLocalizationByState = [
|
|
2
|
-
'unknown',
|
|
3
|
-
'connected',
|
|
4
|
-
'warning',
|
|
5
|
-
'error',
|
|
6
|
-
]
|
|
7
|
-
|
|
8
|
-
export const clusterIconByState = [
|
|
9
|
-
'cluster-error',
|
|
10
|
-
'cluster',
|
|
11
|
-
'cluster-warning',
|
|
12
|
-
'cluster-error',
|
|
13
|
-
// TODO Добавил на скорую руку нужно дополнить, если есть что добавить
|
|
14
|
-
]
|
|
15
|
-
|
|
16
|
-
export const hostLocalizationByState = [
|
|
17
|
-
'unknown',
|
|
18
|
-
'connected',
|
|
19
|
-
'warning',
|
|
20
|
-
'error',
|
|
21
|
-
'maintenance',
|
|
22
|
-
'notResponding',
|
|
23
|
-
'disconnected',
|
|
24
|
-
]
|
|
25
|
-
|
|
26
|
-
export const hostIconByState = [
|
|
27
|
-
'host-error',
|
|
28
|
-
'host',
|
|
29
|
-
'host-warning',
|
|
30
|
-
'host-error',
|
|
31
|
-
'host-maintenance',
|
|
32
|
-
'host-not-responding',
|
|
33
|
-
'host-disconnected',
|
|
34
|
-
]
|
|
35
|
-
|
|
36
|
-
export const vmLocalizationByState = [
|
|
37
|
-
'unknown',
|
|
38
|
-
'powerOff',
|
|
39
|
-
'poweredOn',
|
|
40
|
-
'suspended',
|
|
41
|
-
'error',
|
|
42
|
-
'warning',
|
|
43
|
-
'pending',
|
|
44
|
-
'paused',
|
|
45
|
-
'blocked',
|
|
46
|
-
'shuttingDown',
|
|
47
|
-
'shuttingOff',
|
|
48
|
-
]
|
|
49
|
-
|
|
50
|
-
export const vmIconByState = [
|
|
51
|
-
'vm-error',
|
|
52
|
-
'vm',
|
|
53
|
-
'vm-on',
|
|
54
|
-
'vm-suspended',
|
|
55
|
-
'vm-error',
|
|
56
|
-
'vm-warning',
|
|
57
|
-
'vm-warning',
|
|
58
|
-
'vm-suspended',
|
|
59
|
-
'vm-warning',
|
|
60
|
-
'vm-warning',
|
|
61
|
-
'vm-warning',
|
|
62
|
-
]
|
|
63
|
-
|
|
64
|
-
export const datastoreLocalizationByState = [
|
|
65
|
-
'unknown',
|
|
66
|
-
'connected',
|
|
67
|
-
'warning',
|
|
68
|
-
'error',
|
|
69
|
-
'maintenance',
|
|
70
|
-
'inaccessible',
|
|
71
|
-
'disconnected',
|
|
72
|
-
]
|
|
73
|
-
|
|
74
|
-
export const datastoreIconByState = [
|
|
75
|
-
'datastore-error',
|
|
76
|
-
'datastore',
|
|
77
|
-
'datastore-warning',
|
|
78
|
-
'datastore-error',
|
|
79
|
-
'datastore-maintenance',
|
|
80
|
-
'datastore-inaccessible',
|
|
81
|
-
'datastore-unmount', // 'datastore-disconnected',
|
|
82
|
-
]
|
|
83
|
-
|
|
84
|
-
export const networkLocalizationByState = [
|
|
85
|
-
'unknown',
|
|
86
|
-
'connected',
|
|
87
|
-
'warning',
|
|
88
|
-
'error',
|
|
89
|
-
]
|
|
90
|
-
|
|
91
|
-
export const networkIconByState = [
|
|
92
|
-
'network-error',
|
|
93
|
-
'network',
|
|
94
|
-
'network-warning',
|
|
95
|
-
'network-error',
|
|
96
|
-
]
|
|
97
|
-
|
|
98
|
-
export const switchLocalizationByState = [
|
|
99
|
-
'unknown',
|
|
100
|
-
'connected',
|
|
101
|
-
'warning',
|
|
102
|
-
'error',
|
|
103
|
-
]
|
|
104
|
-
|
|
105
|
-
export const switchIconByState = [
|
|
106
|
-
'switch-error',
|
|
107
|
-
'switch',
|
|
108
|
-
'switch-warning',
|
|
109
|
-
'switch-error',
|
|
110
|
-
]
|
|
111
|
-
|
|
112
|
-
export const resourcePoolLocalizationByState = [
|
|
113
|
-
'unknown',
|
|
114
|
-
'normal',
|
|
115
|
-
'warning',
|
|
116
|
-
'error',
|
|
117
|
-
'alert',
|
|
118
|
-
]
|
|
119
|
-
|
|
120
|
-
export const resourcePoolIconByState = [
|
|
121
|
-
'resourcePoolAlert',
|
|
122
|
-
'resource-pool',
|
|
123
|
-
'resourcePoolWarning',
|
|
124
|
-
'resourcePoolAlert',
|
|
125
|
-
'resourcePoolAlert',
|
|
126
|
-
]
|
|
1
|
+
export const clusterLocalizationByState = [
|
|
2
|
+
'unknown',
|
|
3
|
+
'connected',
|
|
4
|
+
'warning',
|
|
5
|
+
'error',
|
|
6
|
+
]
|
|
7
|
+
|
|
8
|
+
export const clusterIconByState = [
|
|
9
|
+
'cluster-error',
|
|
10
|
+
'cluster',
|
|
11
|
+
'cluster-warning',
|
|
12
|
+
'cluster-error',
|
|
13
|
+
// TODO Добавил на скорую руку нужно дополнить, если есть что добавить
|
|
14
|
+
]
|
|
15
|
+
|
|
16
|
+
export const hostLocalizationByState = [
|
|
17
|
+
'unknown',
|
|
18
|
+
'connected',
|
|
19
|
+
'warning',
|
|
20
|
+
'error',
|
|
21
|
+
'maintenance',
|
|
22
|
+
'notResponding',
|
|
23
|
+
'disconnected',
|
|
24
|
+
]
|
|
25
|
+
|
|
26
|
+
export const hostIconByState = [
|
|
27
|
+
'host-error',
|
|
28
|
+
'host',
|
|
29
|
+
'host-warning',
|
|
30
|
+
'host-error',
|
|
31
|
+
'host-maintenance',
|
|
32
|
+
'host-not-responding',
|
|
33
|
+
'host-disconnected',
|
|
34
|
+
]
|
|
35
|
+
|
|
36
|
+
export const vmLocalizationByState = [
|
|
37
|
+
'unknown',
|
|
38
|
+
'powerOff',
|
|
39
|
+
'poweredOn',
|
|
40
|
+
'suspended',
|
|
41
|
+
'error',
|
|
42
|
+
'warning',
|
|
43
|
+
'pending',
|
|
44
|
+
'paused',
|
|
45
|
+
'blocked',
|
|
46
|
+
'shuttingDown',
|
|
47
|
+
'shuttingOff',
|
|
48
|
+
]
|
|
49
|
+
|
|
50
|
+
export const vmIconByState = [
|
|
51
|
+
'vm-error',
|
|
52
|
+
'vm',
|
|
53
|
+
'vm-on',
|
|
54
|
+
'vm-suspended',
|
|
55
|
+
'vm-error',
|
|
56
|
+
'vm-warning',
|
|
57
|
+
'vm-warning',
|
|
58
|
+
'vm-suspended',
|
|
59
|
+
'vm-warning',
|
|
60
|
+
'vm-warning',
|
|
61
|
+
'vm-warning',
|
|
62
|
+
]
|
|
63
|
+
|
|
64
|
+
export const datastoreLocalizationByState = [
|
|
65
|
+
'unknown',
|
|
66
|
+
'connected',
|
|
67
|
+
'warning',
|
|
68
|
+
'error',
|
|
69
|
+
'maintenance',
|
|
70
|
+
'inaccessible',
|
|
71
|
+
'disconnected',
|
|
72
|
+
]
|
|
73
|
+
|
|
74
|
+
export const datastoreIconByState = [
|
|
75
|
+
'datastore-error',
|
|
76
|
+
'datastore',
|
|
77
|
+
'datastore-warning',
|
|
78
|
+
'datastore-error',
|
|
79
|
+
'datastore-maintenance',
|
|
80
|
+
'datastore-inaccessible',
|
|
81
|
+
'datastore-unmount', // 'datastore-disconnected',
|
|
82
|
+
]
|
|
83
|
+
|
|
84
|
+
export const networkLocalizationByState = [
|
|
85
|
+
'unknown',
|
|
86
|
+
'connected',
|
|
87
|
+
'warning',
|
|
88
|
+
'error',
|
|
89
|
+
]
|
|
90
|
+
|
|
91
|
+
export const networkIconByState = [
|
|
92
|
+
'network-error',
|
|
93
|
+
'network',
|
|
94
|
+
'network-warning',
|
|
95
|
+
'network-error',
|
|
96
|
+
]
|
|
97
|
+
|
|
98
|
+
export const switchLocalizationByState = [
|
|
99
|
+
'unknown',
|
|
100
|
+
'connected',
|
|
101
|
+
'warning',
|
|
102
|
+
'error',
|
|
103
|
+
]
|
|
104
|
+
|
|
105
|
+
export const switchIconByState = [
|
|
106
|
+
'switch-error',
|
|
107
|
+
'switch',
|
|
108
|
+
'switch-warning',
|
|
109
|
+
'switch-error',
|
|
110
|
+
]
|
|
111
|
+
|
|
112
|
+
export const resourcePoolLocalizationByState = [
|
|
113
|
+
'unknown',
|
|
114
|
+
'normal',
|
|
115
|
+
'warning',
|
|
116
|
+
'error',
|
|
117
|
+
'alert',
|
|
118
|
+
]
|
|
119
|
+
|
|
120
|
+
export const resourcePoolIconByState = [
|
|
121
|
+
'resourcePoolAlert',
|
|
122
|
+
'resource-pool',
|
|
123
|
+
'resourcePoolWarning',
|
|
124
|
+
'resourcePoolAlert',
|
|
125
|
+
'resourcePoolAlert',
|
|
126
|
+
]
|
|
@@ -40,26 +40,10 @@
|
|
|
40
40
|
/>
|
|
41
41
|
<span v-else :class="['icon', item.data.iconClassName]"></span>
|
|
42
42
|
{{ item.text }}
|
|
43
|
-
|
|
44
|
-
<a
|
|
45
|
-
v-if="false"
|
|
46
|
-
id="sensor-item-warning"
|
|
47
|
-
:data-id="item.data.testId"
|
|
48
|
-
href="javascript:void(0)"
|
|
49
|
-
class="row-details__text"
|
|
50
|
-
@click="onShowFieldWarning(item.data.error)"
|
|
51
|
-
>{{ localization.details }}...
|
|
52
|
-
</a>
|
|
53
43
|
</template>
|
|
54
44
|
</atoms-table-data-grid>
|
|
55
45
|
</div>
|
|
56
46
|
</div>
|
|
57
|
-
|
|
58
|
-
<common-pages-hardware-health-table-view-modal-sensor-warning
|
|
59
|
-
v-if="isShowSensorWarningDetails"
|
|
60
|
-
:error="sensorWarningError"
|
|
61
|
-
@close-modal="isShowSensorWarningDetails = false"
|
|
62
|
-
/>
|
|
63
47
|
</template>
|
|
64
48
|
|
|
65
49
|
<script lang="ts" setup>
|
|
@@ -108,32 +92,10 @@ const headItems = computed<UI_I_HeadItem[]>(() =>
|
|
|
108
92
|
)
|
|
109
93
|
|
|
110
94
|
const bodyItems = computed<UI_I_BodyItem[][]>(() => {
|
|
111
|
-
|
|
112
|
-
let tableData = props.dataTable
|
|
113
|
-
|
|
114
|
-
switch (props.tableMode) {
|
|
115
|
-
case 'storage-sensor':
|
|
116
|
-
tableData = []
|
|
117
|
-
break
|
|
118
|
-
case 'alert-warning':
|
|
119
|
-
tableData = tableData.filter((sensor: UI_I_HardwareHealthSensors) =>
|
|
120
|
-
[2, 3].includes(sensor.status)
|
|
121
|
-
)
|
|
122
|
-
break
|
|
123
|
-
case 'system-log':
|
|
124
|
-
tableData = []
|
|
125
|
-
break
|
|
126
|
-
}
|
|
95
|
+
const tableData = ['sensor'].includes(props.tableMode) ? props.dataTable : [] // TODO временно так
|
|
127
96
|
|
|
128
97
|
return table[props.tableMode].bodyItems(tableData, localization.value)
|
|
129
98
|
})
|
|
130
|
-
|
|
131
|
-
const isShowSensorWarningDetails = ref<boolean>(false)
|
|
132
|
-
const sensorWarningError = ref<string | null>(null)
|
|
133
|
-
const onShowFieldWarning = (error: string): void => {
|
|
134
|
-
isShowSensorWarningDetails.value = true
|
|
135
|
-
sensorWarningError.value = error
|
|
136
|
-
}
|
|
137
99
|
</script>
|
|
138
100
|
|
|
139
101
|
<style lang="scss" scoped>
|
|
@@ -164,9 +126,6 @@ const onShowFieldWarning = (error: string): void => {
|
|
|
164
126
|
margin-top: 5px;
|
|
165
127
|
}
|
|
166
128
|
}
|
|
167
|
-
&__text {
|
|
168
|
-
margin-left: 8px;
|
|
169
|
-
}
|
|
170
129
|
}
|
|
171
130
|
.icon {
|
|
172
131
|
width: 18px;
|
|
@@ -9,11 +9,8 @@ import {
|
|
|
9
9
|
constructColumnKey,
|
|
10
10
|
} from '~/components/atoms/table/dataGrid/lib/utils/constructDataTable'
|
|
11
11
|
import type { UI_I_HardwareHealthAlertWarnings } from '~/components/common/pages/hardwareHealth/tableView/lib/models/interfaces'
|
|
12
|
+
// import { E_HostStatusIcon } from '~/components/templates/inventory/treeView/lib/models/enums'
|
|
12
13
|
import { hardwareHealthAlertWarningTableKeys } from '~/components/common/pages/hardwareHealth/tableView/lib/config/tableKeys'
|
|
13
|
-
import {
|
|
14
|
-
sensorsLocalizationByStatus,
|
|
15
|
-
sensorsIconByStatus,
|
|
16
|
-
} from '~/components/common/pages/hardwareHealth/lib/config/status'
|
|
17
14
|
|
|
18
15
|
const getItems = (
|
|
19
16
|
localization: UI_I_Localization
|
|
@@ -71,8 +68,7 @@ export const headItems = (localization: UI_I_Localization): UI_I_HeadItem[] => {
|
|
|
71
68
|
}
|
|
72
69
|
|
|
73
70
|
export const bodyItems = (
|
|
74
|
-
data: UI_I_HardwareHealthAlertWarnings[]
|
|
75
|
-
localization: UI_I_Localization
|
|
71
|
+
data: UI_I_HardwareHealthAlertWarnings[]
|
|
76
72
|
): UI_I_BodyItem[][] => {
|
|
77
73
|
const bodyItems: UI_I_BodyItem[][] = []
|
|
78
74
|
data.forEach((sensor: UI_I_HardwareHealthAlertWarnings, key) => {
|
|
@@ -85,16 +81,13 @@ export const bodyItems = (
|
|
|
85
81
|
},
|
|
86
82
|
{
|
|
87
83
|
key: 'icon',
|
|
88
|
-
text:
|
|
89
|
-
sensorsLocalizationByStatus[
|
|
90
|
-
sensor[hardwareHealthAlertWarningTableKeys[1]]
|
|
91
|
-
]
|
|
92
|
-
],
|
|
84
|
+
text: sensor[hardwareHealthAlertWarningTableKeys[1]],
|
|
93
85
|
id: key,
|
|
94
|
-
data: {
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
},
|
|
86
|
+
// data: {
|
|
87
|
+
// iconClassName:
|
|
88
|
+
// E_HostStatusIcon[sensor[hardwareHealthAlertWarningTableKeys[1]]],
|
|
89
|
+
// },
|
|
90
|
+
data: {},
|
|
98
91
|
testId: `table-item-${key}`,
|
|
99
92
|
},
|
|
100
93
|
{
|
|
@@ -21,7 +21,7 @@ const getItems = (
|
|
|
21
21
|
): [string, boolean, string, string][] => {
|
|
22
22
|
return [
|
|
23
23
|
[localization.sensors, true, '330px', hardwareHealthSensorTableKeys[0]],
|
|
24
|
-
[localization.status, true, '
|
|
24
|
+
[localization.status, true, '110px', hardwareHealthSensorTableKeys[1]],
|
|
25
25
|
[localization.reading, true, '115px', hardwareHealthSensorTableKeys[2]],
|
|
26
26
|
[localization.categories, true, '130px', hardwareHealthSensorTableKeys[3]],
|
|
27
27
|
[localization.lastUpdated, true, '195px', hardwareHealthSensorTableKeys[4]],
|