bfg-common 1.3.144 → 1.3.146
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/scss/common/icons/icons-2.scss +222 -222
- package/components/atoms/switch/Switch.vue +107 -107
- package/components/atoms/table/dataGrid/DataGrid.vue +1576 -1576
- package/components/common/diagramMain/DiagramMain.vue +4 -0
- package/components/common/diagramMain/Header.vue +68 -53
- package/components/common/modals/Confirmation.vue +3 -1
- package/components/common/pages/Tasks.vue +120 -120
- package/components/common/recursionTree/RecursionTree.vue +203 -203
- package/components/common/vm/actions/add/Add.vue +575 -575
- package/components/common/vm/actions/clone/Clone.vue +518 -518
- package/components/common/vm/actions/common/customizeHardware/CustomizeHardware.vue +269 -269
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/VirtualHardware.vue +682 -682
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/CpuModel.vue +220 -220
- package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/NewPciDevice.vue +164 -164
- package/components/common/vm/actions/common/select/storage/lib/config/config.ts +166 -166
- package/components/common/vm/actions/editSettings/EditSettings.vue +313 -313
- package/components/common/wizards/network/add/Add.vue +3 -0
- package/components/common/wizards/network/add/steps/SelectedTargetDevice.vue +18 -19
- package/composables/useAppVersion.ts +21 -21
- package/composables/useEnvLanguage.ts +20 -20
- package/composables/useLocal.ts +38 -38
- package/lib/utils/sendTask.ts +72 -72
- package/minify.js +146 -146
- package/package.json +1 -1
- package/public/spice-console/application/codec.js +257 -257
- package/public/spice-console/lib/rasterEngine.js +907 -907
- package/public/spice-console/network/spicechannel.js +369 -369
- 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
|
@@ -201,6 +201,7 @@
|
|
|
201
201
|
:standard-switches-initial="props.standardSwitchesInitial"
|
|
202
202
|
:free-adapters="props.freeAdapters"
|
|
203
203
|
:is-dark-mode="props.isDarkMode"
|
|
204
|
+
:selected-switch-id="selectedSwitchId"
|
|
204
205
|
@check-network-label="onCheckNetworkLabel"
|
|
205
206
|
@get-existing-standard-switches="onGetExistingStandardSwitches"
|
|
206
207
|
@get-free-adapters="onGetFreeAdapters"
|
|
@@ -480,6 +481,8 @@ const onHideMigrateVmkernelAdapterModal = (): void => {
|
|
|
480
481
|
isShowMigrateVmkernelAdapterModal.value = false
|
|
481
482
|
}
|
|
482
483
|
|
|
484
|
+
const selectedSwitchId = ref<string>('')
|
|
485
|
+
|
|
483
486
|
const onShowModal = (
|
|
484
487
|
value: string,
|
|
485
488
|
properties: UI_I_ModalsInitialData
|
|
@@ -526,6 +529,7 @@ const onShowModal = (
|
|
|
526
529
|
break
|
|
527
530
|
case 'add-networking':
|
|
528
531
|
isShowAddNetworkingModal.value = true
|
|
532
|
+
selectedSwitchId.value = properties.switch_name
|
|
529
533
|
break
|
|
530
534
|
case 'switch-view-settings':
|
|
531
535
|
isShowSwitchViewSettingsModal.value = true
|
|
@@ -1,86 +1,96 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
2
|
+
<template v-if="!props.inPortlet">
|
|
3
|
+
<div class="diagram-header">
|
|
4
|
+
<div class="diagram-header-left">
|
|
5
|
+
<atoms-the-icon
|
|
6
|
+
name="angle"
|
|
7
|
+
:class="[
|
|
8
8
|
'diagram-header__arrow-icon',
|
|
9
9
|
{
|
|
10
10
|
open: props.isShowDiagram,
|
|
11
11
|
},
|
|
12
12
|
]"
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
@click="onToggleDiagram"
|
|
14
|
+
/>
|
|
15
|
+
<a>
|
|
16
16
|
<span>
|
|
17
17
|
{{ localization.standardSwitch }}:
|
|
18
18
|
{{ props.diagramName }}
|
|
19
19
|
</span>
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
</div>
|
|
53
|
-
</div>
|
|
20
|
+
</a>
|
|
21
|
+
</div>
|
|
22
|
+
<div v-if="props.isShowDiagram" class="diagram-header__btn-container">
|
|
23
|
+
<span class="vertical-separator"></span>
|
|
24
|
+
<button
|
|
25
|
+
id="add-networking-button"
|
|
26
|
+
type="button"
|
|
27
|
+
@click="onShowModal('add-networking', props.diagramName)"
|
|
28
|
+
>
|
|
29
|
+
{{ localization.addNetworking }}
|
|
30
|
+
</button>
|
|
31
|
+
<button
|
|
32
|
+
id="switch-edit-button"
|
|
33
|
+
type="button"
|
|
34
|
+
@click="onShowModal('switch-edit')"
|
|
35
|
+
>
|
|
36
|
+
{{ localization.edit }}
|
|
37
|
+
</button>
|
|
38
|
+
<button
|
|
39
|
+
id="switch-manage-physical-adapters-button"
|
|
40
|
+
type="button"
|
|
41
|
+
@click="onShowModal('switch-manage-physical-adapters')"
|
|
42
|
+
>
|
|
43
|
+
{{ localization.managePhysicalAdapters }}
|
|
44
|
+
</button>
|
|
45
|
+
<div class="diagram-main-actions-dots">
|
|
46
|
+
<atoms-collapse-nav
|
|
47
|
+
popup-class="diagram-main-actions__popup"
|
|
48
|
+
:close-after-click="true"
|
|
49
|
+
:items="switchMainNavigation"
|
|
50
|
+
@change="onShowModal"
|
|
51
|
+
/>
|
|
54
52
|
</div>
|
|
55
|
-
|
|
56
|
-
</
|
|
53
|
+
</div>
|
|
54
|
+
</div>
|
|
55
|
+
<hr class="horizontal-separator" />
|
|
56
|
+
</template>
|
|
57
57
|
</template>
|
|
58
58
|
|
|
59
59
|
<script setup lang="ts">
|
|
60
60
|
import { UI_I_Localization } from '~/lib/models/interfaces'
|
|
61
|
-
import {
|
|
61
|
+
import {
|
|
62
|
+
UI_I_NavigationItem,
|
|
63
|
+
UI_I_ModalsInitialData,
|
|
64
|
+
} from '~/components/common/diagramMain/lib/models/interfaces'
|
|
62
65
|
import { switchMainNavigationFunc } from '~/components/common/diagramMain/modals/lib/config'
|
|
63
66
|
|
|
64
67
|
const props = defineProps<{
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
+
inPortlet: boolean
|
|
69
|
+
isShowDiagram: boolean
|
|
70
|
+
diagramName: string
|
|
68
71
|
}>()
|
|
69
72
|
|
|
70
73
|
const emits = defineEmits<{
|
|
71
|
-
|
|
72
|
-
|
|
74
|
+
(event: 'toggle-diagram'): void
|
|
75
|
+
(
|
|
76
|
+
event: 'show-modal',
|
|
77
|
+
modalName: string,
|
|
78
|
+
properties?: UI_I_ModalsInitialData
|
|
79
|
+
): void
|
|
73
80
|
}>()
|
|
74
81
|
|
|
75
82
|
const localization = computed<UI_I_Localization>(() => useLocal())
|
|
76
83
|
|
|
77
84
|
const switchMainNavigation = computed<UI_I_NavigationItem[]>(() =>
|
|
78
|
-
|
|
85
|
+
switchMainNavigationFunc(localization.value)
|
|
79
86
|
)
|
|
80
87
|
|
|
81
88
|
const onToggleDiagram = () => emits('toggle-diagram')
|
|
82
89
|
|
|
83
|
-
const onShowModal = (modalName: string) =>
|
|
90
|
+
const onShowModal = (modalName: string, diagramName?: string) =>
|
|
91
|
+
diagramName
|
|
92
|
+
? emits('show-modal', modalName, { switch_name: diagramName })
|
|
93
|
+
: emits('show-modal', modalName)
|
|
84
94
|
</script>
|
|
85
95
|
|
|
86
96
|
<style scoped lang="scss">
|
|
@@ -171,6 +181,11 @@ const onShowModal = (modalName: string) => emits('show-modal', modalName)
|
|
|
171
181
|
}
|
|
172
182
|
}
|
|
173
183
|
|
|
184
|
+
.diagram-main-actions-dots {
|
|
185
|
+
position: relative;
|
|
186
|
+
transform: translate(62px, -11px);
|
|
187
|
+
}
|
|
188
|
+
|
|
174
189
|
.horizontal-separator {
|
|
175
190
|
margin: 5px 10px 10px;
|
|
176
191
|
border-left: 0;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<atoms-modal
|
|
3
3
|
show
|
|
4
|
-
width="
|
|
4
|
+
:width="props.width"
|
|
5
5
|
class="confirm-modal"
|
|
6
6
|
:title="props.headline"
|
|
7
7
|
:second-title="props.subTitle"
|
|
@@ -44,6 +44,7 @@ const props = withDefaults(
|
|
|
44
44
|
testId?: string
|
|
45
45
|
type?: 'confirm' | 'remove'
|
|
46
46
|
variantTextButton?: 'ok' | 'confirm' | 'remove'
|
|
47
|
+
width: string
|
|
47
48
|
}>(),
|
|
48
49
|
{
|
|
49
50
|
testId: 'common-confirmation',
|
|
@@ -52,6 +53,7 @@ const props = withDefaults(
|
|
|
52
53
|
type: 'confirm',
|
|
53
54
|
description: '',
|
|
54
55
|
variantTextButton: 'ok',
|
|
56
|
+
width: '580px',
|
|
55
57
|
}
|
|
56
58
|
)
|
|
57
59
|
const emits = defineEmits<{
|
|
@@ -1,120 +1,120 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="tasks">
|
|
3
|
-
<common-headline
|
|
4
|
-
:headline="localization.taskConsole"
|
|
5
|
-
class="tasks__headline"
|
|
6
|
-
/>
|
|
7
|
-
|
|
8
|
-
<div class="btn-group">
|
|
9
|
-
<button
|
|
10
|
-
id="task-previous-button"
|
|
11
|
-
class="btn btn-sm btn-link nav-link"
|
|
12
|
-
:disabled="pagination.page === 1"
|
|
13
|
-
@click="onClickButton('previous')"
|
|
14
|
-
>
|
|
15
|
-
{{ localization.previous }}
|
|
16
|
-
</button>
|
|
17
|
-
|
|
18
|
-
<button
|
|
19
|
-
id="task-next-button"
|
|
20
|
-
class="btn btn-sm btn-link nav-link"
|
|
21
|
-
:disabled="pagination.page === tasksList?.total_pages"
|
|
22
|
-
@click="onClickButton('next')"
|
|
23
|
-
>
|
|
24
|
-
{{ localization.next }}
|
|
25
|
-
</button>
|
|
26
|
-
</div>
|
|
27
|
-
|
|
28
|
-
<templates-tasks-table-view
|
|
29
|
-
:data-table="tasksList?.items || []"
|
|
30
|
-
:total-items="tasksList?.total_items || 0"
|
|
31
|
-
:total-pages="tasksList?.total_pages || 1"
|
|
32
|
-
:pagination="pagination"
|
|
33
|
-
:loading="isLoading"
|
|
34
|
-
@pagination="onUpdatePagination"
|
|
35
|
-
@sort="onSortTable"
|
|
36
|
-
/>
|
|
37
|
-
</div>
|
|
38
|
-
</template>
|
|
39
|
-
|
|
40
|
-
<script lang="ts" setup>
|
|
41
|
-
import type {
|
|
42
|
-
UI_I_Localization,
|
|
43
|
-
} from '~/lib/models/interfaces'
|
|
44
|
-
import type {
|
|
45
|
-
UI_I_Pagination,
|
|
46
|
-
UI_I_DataTableQuery,
|
|
47
|
-
} from '~/lib/models/table/interfaces'
|
|
48
|
-
import type { UI_I_Task } from '~/lib/models/store/tasks/interfaces'
|
|
49
|
-
|
|
50
|
-
definePageMeta({
|
|
51
|
-
middleware: ['auth'],
|
|
52
|
-
})
|
|
53
|
-
|
|
54
|
-
const localization = computed<UI_I_Localization>(() => useLocal())
|
|
55
|
-
const { $store }: any = useNuxtApp()
|
|
56
|
-
|
|
57
|
-
const pagination = ref<UI_I_Pagination>({
|
|
58
|
-
page: 1,
|
|
59
|
-
pageSize: 100,
|
|
60
|
-
})
|
|
61
|
-
const sort = ref<string | null>(null)
|
|
62
|
-
|
|
63
|
-
const tasksList = computed<UI_I_Task>(() => $store.getters['tasks/getTaskList'])
|
|
64
|
-
|
|
65
|
-
const onClickButton = (status: string): void => {
|
|
66
|
-
if (status === 'next') {
|
|
67
|
-
pagination.value.page += 1
|
|
68
|
-
return
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
pagination.value.page -= 1
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
const getTasks = async (): Promise<void> => {
|
|
75
|
-
pauseGlobalRefresh()
|
|
76
|
-
|
|
77
|
-
const payload: UI_I_DataTableQuery = {
|
|
78
|
-
...pagination.value,
|
|
79
|
-
sortBy: sort.value || '',
|
|
80
|
-
}
|
|
81
|
-
await $store.dispatch('tasks/A_GET_TASKS', payload)
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
const onUpdatePagination = (event: UI_I_Pagination): void => {
|
|
85
|
-
pagination.value = event
|
|
86
|
-
getTasks()
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
const onSortTable = (event: string): void => {
|
|
90
|
-
sort.value = event
|
|
91
|
-
getTasks()
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
const isLoading = computed<boolean>(() =>
|
|
95
|
-
$store.getters['tasks/getLoading']('tasks')
|
|
96
|
-
)
|
|
97
|
-
const pauseGlobalRefresh = (): void => {
|
|
98
|
-
const tasksLastRequestType = $store.getters['tasks/getTasksLastRequestType']
|
|
99
|
-
$store.dispatch('main/A_PAUSE_GLOBAL_REFRESH', tasksLastRequestType)
|
|
100
|
-
}
|
|
101
|
-
onUnmounted(() => {
|
|
102
|
-
pauseGlobalRefresh()
|
|
103
|
-
})
|
|
104
|
-
</script>
|
|
105
|
-
|
|
106
|
-
<style lang="scss">
|
|
107
|
-
@import '~/node_modules/bfg-common/assets/scss/common/mixins';
|
|
108
|
-
.tasks {
|
|
109
|
-
@include flex($dir: column);
|
|
110
|
-
height: 100%;
|
|
111
|
-
padding-left: 10px;
|
|
112
|
-
&__headline {
|
|
113
|
-
padding-left: 10px;
|
|
114
|
-
margin-bottom: 0.6rem;
|
|
115
|
-
}
|
|
116
|
-
.btn {
|
|
117
|
-
text-transform: uppercase;
|
|
118
|
-
}
|
|
119
|
-
}
|
|
120
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div class="tasks">
|
|
3
|
+
<common-headline
|
|
4
|
+
:headline="localization.taskConsole"
|
|
5
|
+
class="tasks__headline"
|
|
6
|
+
/>
|
|
7
|
+
|
|
8
|
+
<div class="btn-group">
|
|
9
|
+
<button
|
|
10
|
+
id="task-previous-button"
|
|
11
|
+
class="btn btn-sm btn-link nav-link"
|
|
12
|
+
:disabled="pagination.page === 1"
|
|
13
|
+
@click="onClickButton('previous')"
|
|
14
|
+
>
|
|
15
|
+
{{ localization.previous }}
|
|
16
|
+
</button>
|
|
17
|
+
|
|
18
|
+
<button
|
|
19
|
+
id="task-next-button"
|
|
20
|
+
class="btn btn-sm btn-link nav-link"
|
|
21
|
+
:disabled="pagination.page === tasksList?.total_pages"
|
|
22
|
+
@click="onClickButton('next')"
|
|
23
|
+
>
|
|
24
|
+
{{ localization.next }}
|
|
25
|
+
</button>
|
|
26
|
+
</div>
|
|
27
|
+
|
|
28
|
+
<templates-tasks-table-view
|
|
29
|
+
:data-table="tasksList?.items || []"
|
|
30
|
+
:total-items="tasksList?.total_items || 0"
|
|
31
|
+
:total-pages="tasksList?.total_pages || 1"
|
|
32
|
+
:pagination="pagination"
|
|
33
|
+
:loading="isLoading"
|
|
34
|
+
@pagination="onUpdatePagination"
|
|
35
|
+
@sort="onSortTable"
|
|
36
|
+
/>
|
|
37
|
+
</div>
|
|
38
|
+
</template>
|
|
39
|
+
|
|
40
|
+
<script lang="ts" setup>
|
|
41
|
+
import type {
|
|
42
|
+
UI_I_Localization,
|
|
43
|
+
} from '~/lib/models/interfaces'
|
|
44
|
+
import type {
|
|
45
|
+
UI_I_Pagination,
|
|
46
|
+
UI_I_DataTableQuery,
|
|
47
|
+
} from '~/lib/models/table/interfaces'
|
|
48
|
+
import type { UI_I_Task } from '~/lib/models/store/tasks/interfaces'
|
|
49
|
+
|
|
50
|
+
definePageMeta({
|
|
51
|
+
middleware: ['auth'],
|
|
52
|
+
})
|
|
53
|
+
|
|
54
|
+
const localization = computed<UI_I_Localization>(() => useLocal())
|
|
55
|
+
const { $store }: any = useNuxtApp()
|
|
56
|
+
|
|
57
|
+
const pagination = ref<UI_I_Pagination>({
|
|
58
|
+
page: 1,
|
|
59
|
+
pageSize: 100,
|
|
60
|
+
})
|
|
61
|
+
const sort = ref<string | null>(null)
|
|
62
|
+
|
|
63
|
+
const tasksList = computed<UI_I_Task>(() => $store.getters['tasks/getTaskList'])
|
|
64
|
+
|
|
65
|
+
const onClickButton = (status: string): void => {
|
|
66
|
+
if (status === 'next') {
|
|
67
|
+
pagination.value.page += 1
|
|
68
|
+
return
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
pagination.value.page -= 1
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
const getTasks = async (): Promise<void> => {
|
|
75
|
+
pauseGlobalRefresh()
|
|
76
|
+
|
|
77
|
+
const payload: UI_I_DataTableQuery = {
|
|
78
|
+
...pagination.value,
|
|
79
|
+
sortBy: sort.value || '',
|
|
80
|
+
}
|
|
81
|
+
await $store.dispatch('tasks/A_GET_TASKS', payload)
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
const onUpdatePagination = (event: UI_I_Pagination): void => {
|
|
85
|
+
pagination.value = event
|
|
86
|
+
getTasks()
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
const onSortTable = (event: string): void => {
|
|
90
|
+
sort.value = event
|
|
91
|
+
getTasks()
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
const isLoading = computed<boolean>(() =>
|
|
95
|
+
$store.getters['tasks/getLoading']('tasks')
|
|
96
|
+
)
|
|
97
|
+
const pauseGlobalRefresh = (): void => {
|
|
98
|
+
const tasksLastRequestType = $store.getters['tasks/getTasksLastRequestType']
|
|
99
|
+
$store.dispatch('main/A_PAUSE_GLOBAL_REFRESH', tasksLastRequestType)
|
|
100
|
+
}
|
|
101
|
+
onUnmounted(() => {
|
|
102
|
+
pauseGlobalRefresh()
|
|
103
|
+
})
|
|
104
|
+
</script>
|
|
105
|
+
|
|
106
|
+
<style lang="scss">
|
|
107
|
+
@import '~/node_modules/bfg-common/assets/scss/common/mixins';
|
|
108
|
+
.tasks {
|
|
109
|
+
@include flex($dir: column);
|
|
110
|
+
height: 100%;
|
|
111
|
+
padding-left: 10px;
|
|
112
|
+
&__headline {
|
|
113
|
+
padding-left: 10px;
|
|
114
|
+
margin-bottom: 0.6rem;
|
|
115
|
+
}
|
|
116
|
+
.btn {
|
|
117
|
+
text-transform: uppercase;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
</style>
|