bfg-common 1.3.594 → 1.3.596
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 +123 -96
- package/assets/localization/local_en.json +123 -96
- package/assets/localization/local_hy.json +123 -96
- package/assets/localization/local_kk.json +123 -96
- package/assets/localization/local_ru.json +126 -96
- package/assets/localization/local_zh.json +123 -96
- package/components/atoms/TheIcon2.vue +1366 -1366
- package/components/atoms/modal/bySteps/BySteps.vue +1 -1
- package/components/atoms/modal/byStepsSecond/ByStepsSecond.vue +1 -1
- package/components/atoms/table/dataGrid/DataGridPagination.vue +1 -1
- package/components/atoms/wizard/Wizard.vue +1 -1
- package/components/common/adapterManager/ui/table/Header.vue +1 -1
- package/components/common/browse/Browse.vue +240 -240
- package/components/common/browse/blocks/Title.vue +91 -91
- package/components/common/browse/blocks/info/Date.vue +21 -21
- package/components/common/context/recursion/Recursion.vue +86 -86
- package/components/common/context/recursion/RecursionNew.vue +198 -198
- package/components/common/context/recursion/RecursionOld.vue +212 -212
- package/components/common/diagramMain/modals/editSettings/tabs/Security.vue +6 -6
- package/components/common/diagramMain/modals/lib/config/adapterModal.ts +1 -1
- package/components/common/diagramMain/modals/lib/config/networkModal.ts +4 -4
- package/components/common/diagramMain/modals/lib/config/switchModal.ts +4 -4
- package/components/common/layout/theHeader/feedback/Feedback.vue +1 -1
- package/components/common/layout/theHeader/helpMenu/About.vue +4 -4
- package/components/common/layout/theHeader/helpMenu/helpMenuNew/lib/config/dropMenu.ts +2 -2
- package/components/common/layout/theHeader/helpMenu/helpMenuOld/lib/config/dropMenu.ts +2 -2
- package/components/common/layout/theHeader/userMenu/modals/preferences/inventory/InventoryNew.vue +1 -1
- package/components/common/layout/theHeader/userMenu/modals/preferences/lib/config/preferencesTabs.ts +1 -1
- package/components/common/monitor/advanced/tools/chartOptionsModal/counters/table/lib/config/tableConfig.ts +1 -1
- package/components/common/pages/Tasks.vue +2 -2
- package/components/common/pages/hardwareHealth/tableView/lib/config/storageSensorTable.ts +1 -1
- package/components/common/pages/hardwareHealth/tableView/lib/config/systemLogTable.ts +1 -1
- package/components/common/shortcuts/Shortcuts.vue +1 -1
- package/components/common/split/horizontal/HorizontalNew.vue +321 -321
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/browseView/BrowseView.vue +1 -1
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/CpuModel.vue +2 -2
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/Hv.vue +1 -1
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/Sa.vue +1 -1
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/tooltip/Tooltip.vue +1 -1
- package/components/common/vm/actions/common/select/storage/lib/config/config.ts +1 -1
- package/components/common/wizards/datastore/add/Add.vue +437 -437
- package/components/common/wizards/datastore/add/readyComplete/ReadyComplete.vue +95 -95
- package/components/common/wizards/vm/migrate/select/storage/table/datastore/lib/config/config.ts +1 -1
- package/components/common/wizards/vm/migrate/select/targetServer/new/lib/config/defaultForm.ts +3 -3
- package/composables/productNameLocal.ts +31 -6
- package/composables/useEnvLanguage.ts +2 -2
- package/lib/models/interfaces.ts +16 -3
- package/lib/models/types.ts +24 -1
- package/lib/utils/sendTask.ts +1 -1
- package/package.json +2 -2
- package/plugins/recursion.ts +293 -293
- package/store/tasks/mappers/recentTasks.ts +45 -45
|
@@ -1,95 +1,95 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="ready-complete">
|
|
3
|
-
<div class="ready-complete__desc">{{ localization.readyCompleteDesc }}</div>
|
|
4
|
-
|
|
5
|
-
<common-details-list :items="properties" class="ready-complete__list list">
|
|
6
|
-
<template #default="{ item }">
|
|
7
|
-
<common-details-item
|
|
8
|
-
:has-children="true"
|
|
9
|
-
:test-id="item.testId"
|
|
10
|
-
open-by-default
|
|
11
|
-
>
|
|
12
|
-
<template #stackBlockKey>
|
|
13
|
-
<span class="list__labels">
|
|
14
|
-
{{ localization.chosenDatastoreName }}
|
|
15
|
-
</span>
|
|
16
|
-
</template>
|
|
17
|
-
|
|
18
|
-
<template #stackChildren>
|
|
19
|
-
<template
|
|
20
|
-
v-for="(item2, key2) in item.items"
|
|
21
|
-
:key="`${item2}_${key2}`"
|
|
22
|
-
>
|
|
23
|
-
<common-details-item
|
|
24
|
-
:has-children="false"
|
|
25
|
-
:test-id="item2.testId"
|
|
26
|
-
class="list__default-style"
|
|
27
|
-
>
|
|
28
|
-
<template #stackBlockKey>
|
|
29
|
-
<div>
|
|
30
|
-
{{ item2.label }}
|
|
31
|
-
</div>
|
|
32
|
-
</template>
|
|
33
|
-
<template #stackBlockContent>
|
|
34
|
-
<div v-if="item2.data">
|
|
35
|
-
<div
|
|
36
|
-
v-for="item3 in item2.data"
|
|
37
|
-
:key="item3"
|
|
38
|
-
class="flex-align-center"
|
|
39
|
-
>
|
|
40
|
-
<div class="vsphere-icon-host"></div>
|
|
41
|
-
<span>{{ item3 }}</span>
|
|
42
|
-
</div>
|
|
43
|
-
</div>
|
|
44
|
-
<span v-else>
|
|
45
|
-
{{ item2.value }}
|
|
46
|
-
</span>
|
|
47
|
-
</template>
|
|
48
|
-
</common-details-item>
|
|
49
|
-
</template>
|
|
50
|
-
</template>
|
|
51
|
-
</common-details-item>
|
|
52
|
-
</template>
|
|
53
|
-
</common-details-list>
|
|
54
|
-
</div>
|
|
55
|
-
</template>
|
|
56
|
-
|
|
57
|
-
<script lang="ts" setup>
|
|
58
|
-
import { UI_I_DetailsItem } from '~/components/common/details/lib/models/interfaces'
|
|
59
|
-
import { UI_I_Localization } from '~/lib/models/interfaces'
|
|
60
|
-
|
|
61
|
-
const props = defineProps<{
|
|
62
|
-
dataReadyView: UI_I_DetailsItem[]
|
|
63
|
-
}>()
|
|
64
|
-
// console.log(props)
|
|
65
|
-
|
|
66
|
-
const localization = computed<UI_I_Localization>(() => useLocal())
|
|
67
|
-
|
|
68
|
-
const properties = computed<UI_I_DetailsItem[]>(() => props.dataReadyView)
|
|
69
|
-
</script>
|
|
70
|
-
|
|
71
|
-
<style lang="scss" scoped>
|
|
72
|
-
@import '~/assets/scss/common/mixins.scss';
|
|
73
|
-
.ready-complete {
|
|
74
|
-
&__list {
|
|
75
|
-
@include flex($dir: column);
|
|
76
|
-
padding: 12px 0;
|
|
77
|
-
row-gap: 15px;
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
.list {
|
|
81
|
-
&__labels {
|
|
82
|
-
@include text($fs: 13px, $fw: 700);
|
|
83
|
-
}
|
|
84
|
-
:deep(.list__default-style) {
|
|
85
|
-
.stack-block {
|
|
86
|
-
&__label {
|
|
87
|
-
align-items: flex-start;
|
|
88
|
-
}
|
|
89
|
-
&-content {
|
|
90
|
-
white-space: pre-line;
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div class="ready-complete">
|
|
3
|
+
<div class="ready-complete__desc">{{ localization.readyCompleteDesc }}</div>
|
|
4
|
+
|
|
5
|
+
<common-details-list :items="properties" class="ready-complete__list list">
|
|
6
|
+
<template #default="{ item }">
|
|
7
|
+
<common-details-item
|
|
8
|
+
:has-children="true"
|
|
9
|
+
:test-id="item.testId"
|
|
10
|
+
open-by-default
|
|
11
|
+
>
|
|
12
|
+
<template #stackBlockKey>
|
|
13
|
+
<span class="list__labels">
|
|
14
|
+
{{ localization.chosenDatastoreName }}
|
|
15
|
+
</span>
|
|
16
|
+
</template>
|
|
17
|
+
|
|
18
|
+
<template #stackChildren>
|
|
19
|
+
<template
|
|
20
|
+
v-for="(item2, key2) in item.items"
|
|
21
|
+
:key="`${item2}_${key2}`"
|
|
22
|
+
>
|
|
23
|
+
<common-details-item
|
|
24
|
+
:has-children="false"
|
|
25
|
+
:test-id="item2.testId"
|
|
26
|
+
class="list__default-style"
|
|
27
|
+
>
|
|
28
|
+
<template #stackBlockKey>
|
|
29
|
+
<div>
|
|
30
|
+
{{ item2.label }}
|
|
31
|
+
</div>
|
|
32
|
+
</template>
|
|
33
|
+
<template #stackBlockContent>
|
|
34
|
+
<div v-if="item2.data">
|
|
35
|
+
<div
|
|
36
|
+
v-for="item3 in item2.data"
|
|
37
|
+
:key="item3"
|
|
38
|
+
class="flex-align-center"
|
|
39
|
+
>
|
|
40
|
+
<div class="vsphere-icon-host"></div>
|
|
41
|
+
<span>{{ item3 }}</span>
|
|
42
|
+
</div>
|
|
43
|
+
</div>
|
|
44
|
+
<span v-else>
|
|
45
|
+
{{ item2.value }}
|
|
46
|
+
</span>
|
|
47
|
+
</template>
|
|
48
|
+
</common-details-item>
|
|
49
|
+
</template>
|
|
50
|
+
</template>
|
|
51
|
+
</common-details-item>
|
|
52
|
+
</template>
|
|
53
|
+
</common-details-list>
|
|
54
|
+
</div>
|
|
55
|
+
</template>
|
|
56
|
+
|
|
57
|
+
<script lang="ts" setup>
|
|
58
|
+
import { UI_I_DetailsItem } from '~/components/common/details/lib/models/interfaces'
|
|
59
|
+
import { UI_I_Localization } from '~/lib/models/interfaces'
|
|
60
|
+
|
|
61
|
+
const props = defineProps<{
|
|
62
|
+
dataReadyView: UI_I_DetailsItem[]
|
|
63
|
+
}>()
|
|
64
|
+
// console.log(props)
|
|
65
|
+
|
|
66
|
+
const localization = computed<UI_I_Localization>(() => useLocal())
|
|
67
|
+
|
|
68
|
+
const properties = computed<UI_I_DetailsItem[]>(() => props.dataReadyView)
|
|
69
|
+
</script>
|
|
70
|
+
|
|
71
|
+
<style lang="scss" scoped>
|
|
72
|
+
@import '~/assets/scss/common/mixins.scss';
|
|
73
|
+
.ready-complete {
|
|
74
|
+
&__list {
|
|
75
|
+
@include flex($dir: column);
|
|
76
|
+
padding: 12px 0;
|
|
77
|
+
row-gap: 15px;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
.list {
|
|
81
|
+
&__labels {
|
|
82
|
+
@include text($fs: 13px, $fw: 700);
|
|
83
|
+
}
|
|
84
|
+
:deep(.list__default-style) {
|
|
85
|
+
.stack-block {
|
|
86
|
+
&__label {
|
|
87
|
+
align-items: flex-start;
|
|
88
|
+
}
|
|
89
|
+
&-content {
|
|
90
|
+
white-space: pre-line;
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
</style>
|
package/components/common/wizards/vm/migrate/select/storage/table/datastore/lib/config/config.ts
CHANGED
|
@@ -43,7 +43,7 @@ const getItems = (
|
|
|
43
43
|
[localization.used, true, '110px', storageTableKeys[5]],
|
|
44
44
|
[localization.type, true, '110px', storageTableKeys[6]],
|
|
45
45
|
[localization.thinProvisioning, true, '132px', storageTableKeys[7]],
|
|
46
|
-
[localization.access, true, '110px', storageTableKeys[8]],
|
|
46
|
+
[localization.common.access, true, '110px', storageTableKeys[8]],
|
|
47
47
|
[localization.hardwareAcceleration, true, '134px', storageTableKeys[9]],
|
|
48
48
|
[localization.driverType, true, '110px', storageTableKeys[10]],
|
|
49
49
|
[localization.device, true, '110px', storageTableKeys[11]],
|
package/components/common/wizards/vm/migrate/select/targetServer/new/lib/config/defaultForm.ts
CHANGED
|
@@ -7,7 +7,7 @@ export const defaultFormFunc = (localization: UI_I_Localization): any => {
|
|
|
7
7
|
validations: [
|
|
8
8
|
{
|
|
9
9
|
value: 'required',
|
|
10
|
-
errorText: localization.fieldRequired,
|
|
10
|
+
errorText: localization.common.fieldRequired,
|
|
11
11
|
},
|
|
12
12
|
],
|
|
13
13
|
},
|
|
@@ -16,7 +16,7 @@ export const defaultFormFunc = (localization: UI_I_Localization): any => {
|
|
|
16
16
|
validations: [
|
|
17
17
|
{
|
|
18
18
|
value: 'required',
|
|
19
|
-
errorText: localization.fieldRequired,
|
|
19
|
+
errorText: localization.common.fieldRequired,
|
|
20
20
|
},
|
|
21
21
|
],
|
|
22
22
|
},
|
|
@@ -25,7 +25,7 @@ export const defaultFormFunc = (localization: UI_I_Localization): any => {
|
|
|
25
25
|
validations: [
|
|
26
26
|
{
|
|
27
27
|
value: 'required',
|
|
28
|
-
errorText: localization.fieldRequired,
|
|
28
|
+
errorText: localization.common.fieldRequired,
|
|
29
29
|
},
|
|
30
30
|
],
|
|
31
31
|
},
|
|
@@ -1,21 +1,46 @@
|
|
|
1
1
|
import type { UI_I_Localization } from '~/lib/models/interfaces'
|
|
2
|
+
import type { UI_T_LanguageKey } from '~/lib/models/types'
|
|
2
3
|
|
|
3
4
|
export function productNameLocal(
|
|
4
5
|
localization: UI_I_Localization
|
|
5
6
|
): UI_I_Localization {
|
|
6
7
|
const config = useRuntimeConfig()
|
|
7
8
|
|
|
8
|
-
const keys = Object.keys(localization)
|
|
9
9
|
const productName =
|
|
10
10
|
config.public.LOCALIZATION_CODE === 'ru'
|
|
11
11
|
? config.public.PRODUCT_NAME_RU
|
|
12
12
|
: config.public.PRODUCT_NAME_EN
|
|
13
13
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
14
|
+
return replaceProductNameRecursion(localization, productName)
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
const replaceProductNameRecursion = (
|
|
18
|
+
localization: UI_I_Localization,
|
|
19
|
+
productName: any
|
|
20
|
+
): UI_I_Localization => {
|
|
21
|
+
for (const key of Object.keys(localization)) {
|
|
22
|
+
const item = localization[key as UI_T_LanguageKey]
|
|
23
|
+
// TODO move to config
|
|
24
|
+
const localizationKeys = [
|
|
25
|
+
'common',
|
|
26
|
+
'auth',
|
|
27
|
+
'home',
|
|
28
|
+
'tasks',
|
|
29
|
+
'layout',
|
|
30
|
+
'mainNavigation',
|
|
31
|
+
'administration',
|
|
32
|
+
'inventoryConfigure',
|
|
33
|
+
'datastoreWizard',
|
|
34
|
+
'inventorySummary',
|
|
35
|
+
'contextMenu',
|
|
36
|
+
'networks',
|
|
37
|
+
'inventory',
|
|
38
|
+
]
|
|
39
|
+
if (localizationKeys.includes(key)) {
|
|
40
|
+
for (const key2 of Object.keys(item)) {
|
|
41
|
+
item[key2] = item[key2].replaceAll('{productName}', productName)
|
|
42
|
+
}
|
|
43
|
+
}
|
|
19
44
|
}
|
|
20
45
|
|
|
21
46
|
return localization
|
|
@@ -3,9 +3,9 @@ export function useEnvLanguage(): string {
|
|
|
3
3
|
|
|
4
4
|
let localizationCode = 'en_US'
|
|
5
5
|
const langFromLocalStorage =
|
|
6
|
+
$store.getters['main/getInterfaceLang'] || // Из $store для Сферы, но думаю нужно сделать одинаково из localStorage
|
|
6
7
|
useLocalStorage('lang') ||
|
|
7
|
-
useLocalStorage('languageType')
|
|
8
|
-
$store.getters['main/getInterfaceLang'] // Из $store для Сферы, но думаю нужно сделать одинаково из localStorage
|
|
8
|
+
useLocalStorage('languageType')
|
|
9
9
|
|
|
10
10
|
if (langFromLocalStorage) {
|
|
11
11
|
if (
|
package/lib/models/interfaces.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { UI_T_NotificationStatus } from '~/components/atoms/alert/lib/models/types'
|
|
1
|
+
import type { UI_T_NotificationStatus } from '~/components/atoms/alert/lib/models/types'
|
|
2
2
|
import { UI_E_State } from '~/lib/models/enums'
|
|
3
3
|
|
|
4
4
|
export interface UI_I_ItemView {
|
|
@@ -13,8 +13,21 @@ export interface UI_I_ArbitraryObject<T> {
|
|
|
13
13
|
[key: string]: T
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
-
export interface UI_I_Localization
|
|
17
|
-
|
|
16
|
+
export interface UI_I_Localization {
|
|
17
|
+
common: UI_I_ArbitraryObject<string>
|
|
18
|
+
auth: UI_I_ArbitraryObject<string>
|
|
19
|
+
home: UI_I_ArbitraryObject<string>
|
|
20
|
+
tasks: UI_I_ArbitraryObject<string>
|
|
21
|
+
layout: UI_I_ArbitraryObject<string>
|
|
22
|
+
mainNavigation: UI_I_ArbitraryObject<string>
|
|
23
|
+
administration: UI_I_ArbitraryObject<string>
|
|
24
|
+
inventoryConfigure: UI_I_ArbitraryObject<string>
|
|
25
|
+
datastoreWizard: UI_I_ArbitraryObject<string>
|
|
26
|
+
inventorySummary: UI_I_ArbitraryObject<string>
|
|
27
|
+
contextMenu: UI_I_ArbitraryObject<string>
|
|
28
|
+
networks: UI_I_ArbitraryObject<string>
|
|
29
|
+
inventory: UI_I_ArbitraryObject<string>
|
|
30
|
+
}
|
|
18
31
|
export interface UI_I_SendTaskParams {
|
|
19
32
|
method: string
|
|
20
33
|
target: string
|
package/lib/models/types.ts
CHANGED
|
@@ -1,7 +1,15 @@
|
|
|
1
1
|
export type UI_T_Project = 'sphere' | 'procurator'
|
|
2
2
|
|
|
3
3
|
export type UI_T_Binary = 'KB' | 'MB' | 'GB' | 'TB' | 'PB' | 'EB' | 'ZB' | 'YB'
|
|
4
|
-
export type UI_T_BinaryLower =
|
|
4
|
+
export type UI_T_BinaryLower =
|
|
5
|
+
| 'kb'
|
|
6
|
+
| 'mb'
|
|
7
|
+
| 'gb'
|
|
8
|
+
| 'tb'
|
|
9
|
+
| 'pb'
|
|
10
|
+
| 'eb'
|
|
11
|
+
| 'zb'
|
|
12
|
+
| 'yb'
|
|
5
13
|
|
|
6
14
|
export type UI_T_LangValue =
|
|
7
15
|
| 'en_US'
|
|
@@ -11,3 +19,18 @@ export type UI_T_LangValue =
|
|
|
11
19
|
| 'kk_KZ'
|
|
12
20
|
| 'be_BY'
|
|
13
21
|
| 'BROWSER'
|
|
22
|
+
|
|
23
|
+
export type UI_T_LanguageKey =
|
|
24
|
+
| 'common'
|
|
25
|
+
| 'auth'
|
|
26
|
+
| 'home'
|
|
27
|
+
| 'tasks'
|
|
28
|
+
| 'layout'
|
|
29
|
+
| 'mainNavigation'
|
|
30
|
+
| 'administration'
|
|
31
|
+
| 'inventoryConfigure'
|
|
32
|
+
| 'datastoreWizard'
|
|
33
|
+
| 'inventorySummary'
|
|
34
|
+
| 'contextMenu'
|
|
35
|
+
| 'networks'
|
|
36
|
+
| 'inventory'
|
package/lib/utils/sendTask.ts
CHANGED
|
@@ -30,7 +30,7 @@ const showNotification = (message: UI_I_NotifyBodyMessage): void => {
|
|
|
30
30
|
}
|
|
31
31
|
const msgError: UI_I_NotifyBodyMessage = {
|
|
32
32
|
status: 'error',
|
|
33
|
-
title: localization.value.error,
|
|
33
|
+
title: localization.value.common.error,
|
|
34
34
|
desc: '',
|
|
35
35
|
}
|
|
36
36
|
const handleErrors = (error: Ref<API_UI_I_Error>): void => {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "bfg-common",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "1.3.
|
|
4
|
+
"version": "1.3.596",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "nuxt build",
|
|
7
7
|
"dev": "nuxt dev --port=3002",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"@vueuse/components": "^10.1.2",
|
|
36
36
|
"date-fns": "^2.29.3",
|
|
37
37
|
"bfg-nuxt-3-graph": "^1.0.15",
|
|
38
|
-
"bfg-uikit": "1.0.
|
|
38
|
+
"bfg-uikit": "1.0.91",
|
|
39
39
|
"html2canvas": "^1.4.1",
|
|
40
40
|
"prettier-eslint": "^15.0.1"
|
|
41
41
|
}
|