bfg-common 1.4.858 → 1.4.860

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.
Files changed (40) hide show
  1. package/assets/localization/local_be.json +17 -6
  2. package/assets/localization/local_en.json +13 -2
  3. package/assets/localization/local_hy.json +13 -2
  4. package/assets/localization/local_kk.json +13 -2
  5. package/assets/localization/local_ru.json +13 -2
  6. package/assets/localization/local_zh.json +13 -2
  7. package/assets/scss/clarity/local_ar.json +1 -1
  8. package/components/atoms/autocomplete/Autocomplete.vue +1 -0
  9. package/components/common/chartOptionsModal/counters/timespan/form/FormNew.vue +241 -241
  10. package/components/common/context/recursion/RecursionNew.vue +1 -1
  11. package/components/common/graph/GraphOld.vue +20 -1
  12. package/components/common/monitor/advanced/graphView/GraphView.vue +179 -179
  13. package/components/common/monitor/advanced/tools/chartOptionsModal/actions/Actions.vue +0 -8
  14. package/components/common/monitor/advanced/tools/chartOptionsModal/actions/ActionsNew.vue +18 -3
  15. package/components/common/monitor/advanced/tools/chartOptionsModal/actions/ActionsOld.vue +8 -2
  16. package/components/common/monitor/overview/Overview.vue +224 -224
  17. package/components/common/pages/hardwareHealth/historyTestimony/Graph.vue +459 -459
  18. package/components/common/pages/home/headline/HeadlineNew.vue +26 -0
  19. package/components/common/pages/home/widgets/hosts/HostsNew.vue +1 -1
  20. package/components/common/pages/home/widgets/services/ServicesNew.vue +26 -4
  21. package/components/common/pages/home/widgets/services/lib/config/config.ts +29 -7
  22. package/components/common/pages/home/widgets/services/lib/models/enums.ts +17 -10
  23. package/components/common/pages/tasks/Tasks.vue +14 -0
  24. package/components/common/pages/tasks/table/Table.vue +43 -0
  25. package/components/common/pages/tasks/table/lib/config/config.ts +1 -1
  26. package/components/common/wizards/vm/migrate/Migrate.vue +19 -5
  27. package/components/common/wizards/vm/migrate/lib/config/constructDataReady.ts +44 -34
  28. package/components/common/wizards/vm/migrate/lib/config/steps.ts +1 -1
  29. package/components/common/wizards/vm/migrate/lib/models/enums.ts +6 -0
  30. package/components/common/wizards/vm/migrate/select/network/Network.vue +46 -43
  31. package/components/common/wizards/vm/migrate/select/network/table/network/Network.vue +39 -16
  32. package/components/common/wizards/vm/migrate/select/network/table/network/lib/config/advancedTable.ts +9 -6
  33. package/components/common/wizards/vm/migrate/select/network/table/network/lib/config/tableKeys.ts +1 -1
  34. package/components/common/wizards/vm/migrate/select/network/table/network/lib/models/interfaces.ts +1 -1
  35. package/components/common/wizards/vm/migrate/select/network/table/network/lib/models/types.ts +1 -1
  36. package/components/common/wizards/vm/migrate/select/priority/Priority.vue +19 -1
  37. package/components/common/wizards/vm/migrate/select/priority/lib/config/typeOptions.ts +16 -9
  38. package/components/common/wizards/vm/migrate/select/priority/lib/models/types.ts +1 -1
  39. package/lib/models/interfaces.ts +1 -0
  40. package/package.json +2 -2
@@ -1,241 +1,241 @@
1
- <template>
2
- <div class="timespan-form-container">
3
- <p class="block-title">{{ localization.inventoryMonitor.timespan }}</p>
4
- <ui-select
5
- v-model="localSelectedTimespanLocal"
6
- :items="constructedTimespanOptions"
7
- test-id="timespan-local"
8
- select-width="100%"
9
- size="md"
10
- />
11
-
12
- <div class="radio-container">
13
- <ui-radio
14
- v-model="localPeriodTypeLocal"
15
- :label="localization.common.last"
16
- :disabled="isDisabledCustomForm"
17
- test-id="last-from"
18
- value="last"
19
- size="sm"
20
- />
21
- <div class="row-container">
22
- <ui-input
23
- v-model="localLastLocal"
24
- :disabled="isDisabledCustomFormLast"
25
- test-id="local-last"
26
- />
27
- <ui-select
28
- v-model="localSelectedCustomTimeLocal"
29
- :items="constructedCustomTimeOptions"
30
- :disabled="isDisabledCustomFormLast"
31
- test-id="custom-time"
32
- select-width="100%"
33
- size="md"
34
- />
35
- </div>
36
- </div>
37
- <div class="radio-container">
38
- <ui-radio
39
- v-model="localPeriodTypeLocal"
40
- :label="localization.common.timeRange"
41
- :disabled="isDisabledCustomForm"
42
- test-id="last-from"
43
- value="period"
44
- size="sm"
45
- />
46
-
47
- <ui-input-with-datepicker
48
- id="date-from"
49
- v-model="constructedDateFromLocal"
50
- :format="datepickerFormat"
51
- test-id="date-from"
52
- time-format="12"
53
- :disabled="isDisabledCustomFormRange"
54
- />
55
-
56
- <ui-input-with-datepicker
57
- id="date-to"
58
- v-model="constructedDateToLocal"
59
- :format="datepickerFormat"
60
- test-id="date-to"
61
- time-format="12"
62
- :disabled="isDisabledCustomFormRange"
63
- />
64
- </div>
65
- <p class="date-time-info">
66
- {{ localization.inventoryMonitor.dateTimeIsoFormat }}
67
- </p>
68
- </div>
69
- </template>
70
-
71
- <script setup lang="ts">
72
- import type { UI_I_Dropdown } from '~/node_modules/bfg-uikit/components/ui/dropdown/models/interfaces'
73
- import type { UI_I_Localization } from '~/lib/models/interfaces'
74
- import type { UI_I_OptionItem } from '~/components/atoms/lib/models/interfaces'
75
- import { getUiDatepickerFormatByLanguage } from '~/lib/utils/date'
76
-
77
- const localSelectedTimespanLocal = defineModel<string>(
78
- 'localSelectedTimespan',
79
- { required: true }
80
- )
81
- const localPeriodTypeLocal = defineModel<string>('localPeriodType', {
82
- required: true,
83
- })
84
- const localLastLocal = defineModel<number>('localLast', {
85
- required: true,
86
- })
87
- const localSelectedCustomTimeLocal = defineModel<string>(
88
- 'localSelectedCustomTime',
89
- {
90
- required: true,
91
- }
92
- )
93
- const localCurrentDateFromLocal = defineModel<string>('localCurrentDateFrom', {
94
- required: true,
95
- })
96
- const currentTimeFromLocal = defineModel<string>('currentTimeFrom', {
97
- required: true,
98
- })
99
- const currentTimeToLocal = defineModel<string>('currentTimeTo', {
100
- required: true,
101
- })
102
- const currentDateToLocal = defineModel<string>('currentDateTo', {
103
- required: true,
104
- })
105
-
106
- const props = defineProps<{
107
- timespanOptions: UI_I_OptionItem[]
108
- customTimeOptions: UI_I_OptionItem[]
109
- language: string
110
- }>()
111
-
112
- const {
113
- $isDate,
114
- $getUnixByDate,
115
- $formattedDate,
116
- $formattedTime,
117
- $getDateFormat,
118
- } = useNuxtApp()
119
-
120
- const localization = computed<UI_I_Localization>(() => useLocal())
121
-
122
- const isDisabledCustomForm = computed<boolean>(
123
- () => localSelectedTimespanLocal.value !== 'custom_interval'
124
- )
125
- const isDisabledCustomFormLast = computed<boolean>(
126
- () => isDisabledCustomForm.value || localPeriodTypeLocal.value !== 'last'
127
- )
128
- const isDisabledCustomFormRange = computed<boolean>(
129
- () => isDisabledCustomForm.value || localPeriodTypeLocal.value !== 'period'
130
- )
131
-
132
- const constructedTimespanOptions = computed<UI_I_Dropdown[]>(() =>
133
- props.timespanOptions.map((item) => {
134
- return {
135
- text: item.text,
136
- value: item.value,
137
- }
138
- })
139
- )
140
-
141
- const constructedCustomTimeOptions = computed<UI_I_Dropdown[]>(() =>
142
- props.customTimeOptions.map((item) => {
143
- return {
144
- text: item.text,
145
- value: item.value,
146
- }
147
- })
148
- )
149
-
150
- const datepickerFormat = computed<string>(() =>
151
- getUiDatepickerFormatByLanguage(props.language)
152
- )
153
- const dateFormatForUpdate = ref<string>($getDateFormat(props.language))
154
- const constructedDateFromLocal = computed<number>({
155
- get() {
156
- // TODO fix PM
157
- return $isDate(localCurrentDateFromLocal.value)
158
- ? $getUnixByDate(
159
- localCurrentDateFromLocal.value + ' ' + currentTimeFromLocal.value
160
- )
161
- : 0
162
- },
163
- set(newValue) {
164
- localCurrentDateFromLocal.value = $formattedDate(
165
- new Date(newValue),
166
- dateFormatForUpdate.value
167
- )
168
- currentTimeFromLocal.value = $formattedTime(newValue, '', true)
169
- },
170
- })
171
-
172
- const constructedDateToLocal = computed<number>({
173
- get() {
174
- // TODO fix PM
175
- return $isDate(currentDateToLocal.value)
176
- ? $getUnixByDate(
177
- currentDateToLocal.value + ' ' + currentTimeToLocal.value
178
- )
179
- : 0
180
- },
181
- set(newValue) {
182
- currentDateToLocal.value = $formattedDate(
183
- new Date(newValue),
184
- dateFormatForUpdate.value
185
- )
186
- currentTimeToLocal.value = $formattedTime(newValue, '', true)
187
- },
188
- })
189
- </script>
190
-
191
- <style>
192
- :root {
193
- --chart-options-timespan-blocks-bg: #ffffff;
194
- --chart-options-timespan-blocks-title-color: #4d5d69;
195
- }
196
- :root.dark-theme {
197
- --chart-options-timespan-blocks-bg: #334453;
198
- --chart-options-timespan-blocks-title-color: #e9eaec;
199
- }
200
- </style>
201
- <style scoped lang="scss">
202
- .timespan-form-container {
203
- padding: 12px;
204
- background: var(--chart-options-timespan-blocks-bg);
205
- box-shadow: 0 1px 4px 0 #00000014;
206
- border-radius: 8px;
207
-
208
- .block-title {
209
- color: var(--chart-options-timespan-blocks-title-color);
210
- font-size: 14px;
211
- font-weight: 500;
212
- margin-bottom: 16px;
213
- }
214
- .radio-container {
215
- display: flex;
216
- flex-direction: column;
217
- grid-gap: 12px;
218
- margin-top: 16px;
219
-
220
- .row-container {
221
- display: grid;
222
- grid-template-columns: 1fr 1fr;
223
- grid-gap: 12px;
224
-
225
- :deep(.ui-input-with-datepicker) {
226
- grid-gap: 12px;
227
- }
228
- }
229
- :deep(.ui-input-with-datepicker) {
230
- grid-gap: 12px;
231
- }
232
- }
233
-
234
- .date-time-info {
235
- font-weight: 400;
236
- font-size: 12px;
237
- color: #9da6ad;
238
- margin-top: 16px;
239
- }
240
- }
241
- </style>
1
+ <template>
2
+ <div class="timespan-form-container">
3
+ <p class="block-title">{{ localization.inventoryMonitor.timespan }}</p>
4
+ <ui-select
5
+ v-model="localSelectedTimespanLocal"
6
+ :items="constructedTimespanOptions"
7
+ test-id="timespan-local"
8
+ select-width="100%"
9
+ size="md"
10
+ />
11
+
12
+ <div class="radio-container">
13
+ <ui-radio
14
+ v-model="localPeriodTypeLocal"
15
+ :label="localization.common.last"
16
+ :disabled="isDisabledCustomForm"
17
+ test-id="last-from"
18
+ value="last"
19
+ size="sm"
20
+ />
21
+ <div class="row-container">
22
+ <ui-input
23
+ v-model="localLastLocal"
24
+ :disabled="isDisabledCustomFormLast"
25
+ test-id="local-last"
26
+ />
27
+ <ui-select
28
+ v-model="localSelectedCustomTimeLocal"
29
+ :items="constructedCustomTimeOptions"
30
+ :disabled="isDisabledCustomFormLast"
31
+ test-id="custom-time"
32
+ select-width="100%"
33
+ size="md"
34
+ />
35
+ </div>
36
+ </div>
37
+ <div class="radio-container">
38
+ <ui-radio
39
+ v-model="localPeriodTypeLocal"
40
+ :label="localization.common.timeRange"
41
+ :disabled="isDisabledCustomForm"
42
+ test-id="last-from"
43
+ value="period"
44
+ size="sm"
45
+ />
46
+
47
+ <ui-input-with-datepicker
48
+ id="date-from"
49
+ v-model="constructedDateFromLocal"
50
+ :format="datepickerFormat"
51
+ test-id="date-from"
52
+ time-format="12"
53
+ :disabled="isDisabledCustomFormRange"
54
+ />
55
+
56
+ <ui-input-with-datepicker
57
+ id="date-to"
58
+ v-model="constructedDateToLocal"
59
+ :format="datepickerFormat"
60
+ test-id="date-to"
61
+ time-format="12"
62
+ :disabled="isDisabledCustomFormRange"
63
+ />
64
+ </div>
65
+ <p class="date-time-info">
66
+ {{ localization.inventoryMonitor.dateTimeIsoFormat }}
67
+ </p>
68
+ </div>
69
+ </template>
70
+
71
+ <script setup lang="ts">
72
+ import type { UI_I_Dropdown } from '~/node_modules/bfg-uikit/components/ui/dropdown/models/interfaces'
73
+ import type { UI_I_Localization } from '~/lib/models/interfaces'
74
+ import type { UI_I_OptionItem } from '~/components/atoms/lib/models/interfaces'
75
+ import { getUiDatepickerFormatByLanguage } from '~/lib/utils/date'
76
+
77
+ const localSelectedTimespanLocal = defineModel<string>(
78
+ 'localSelectedTimespan',
79
+ { required: true }
80
+ )
81
+ const localPeriodTypeLocal = defineModel<string>('localPeriodType', {
82
+ required: true,
83
+ })
84
+ const localLastLocal = defineModel<number>('localLast', {
85
+ required: true,
86
+ })
87
+ const localSelectedCustomTimeLocal = defineModel<string>(
88
+ 'localSelectedCustomTime',
89
+ {
90
+ required: true,
91
+ }
92
+ )
93
+ const localCurrentDateFromLocal = defineModel<string>('localCurrentDateFrom', {
94
+ required: true,
95
+ })
96
+ const currentTimeFromLocal = defineModel<string>('currentTimeFrom', {
97
+ required: true,
98
+ })
99
+ const currentTimeToLocal = defineModel<string>('currentTimeTo', {
100
+ required: true,
101
+ })
102
+ const currentDateToLocal = defineModel<string>('currentDateTo', {
103
+ required: true,
104
+ })
105
+
106
+ const props = defineProps<{
107
+ timespanOptions: UI_I_OptionItem[]
108
+ customTimeOptions: UI_I_OptionItem[]
109
+ language: string
110
+ }>()
111
+
112
+ const {
113
+ $isDate,
114
+ $getUnixByDate,
115
+ $formattedDate,
116
+ $formattedTime,
117
+ $getDateFormat,
118
+ } = useNuxtApp()
119
+
120
+ const localization = computed<UI_I_Localization>(() => useLocal())
121
+
122
+ const isDisabledCustomForm = computed<boolean>(
123
+ () => localSelectedTimespanLocal.value !== 'custom_interval'
124
+ )
125
+ const isDisabledCustomFormLast = computed<boolean>(
126
+ () => isDisabledCustomForm.value || localPeriodTypeLocal.value !== 'last'
127
+ )
128
+ const isDisabledCustomFormRange = computed<boolean>(
129
+ () => isDisabledCustomForm.value || localPeriodTypeLocal.value !== 'period'
130
+ )
131
+
132
+ const constructedTimespanOptions = computed<UI_I_Dropdown[]>(() =>
133
+ props.timespanOptions.map((item) => {
134
+ return {
135
+ text: item.text,
136
+ value: item.value,
137
+ }
138
+ })
139
+ )
140
+
141
+ const constructedCustomTimeOptions = computed<UI_I_Dropdown[]>(() =>
142
+ props.customTimeOptions.map((item) => {
143
+ return {
144
+ text: item.text,
145
+ value: item.value,
146
+ }
147
+ })
148
+ )
149
+
150
+ const datepickerFormat = computed<string>(() =>
151
+ getUiDatepickerFormatByLanguage(props.language)
152
+ )
153
+ const dateFormatForUpdate = ref<string>($getDateFormat(props.language))
154
+ const constructedDateFromLocal = computed<number>({
155
+ get() {
156
+ // TODO fix PM
157
+ return $isDate(localCurrentDateFromLocal.value)
158
+ ? $getUnixByDate(
159
+ localCurrentDateFromLocal.value + ' ' + currentTimeFromLocal.value
160
+ )
161
+ : 0
162
+ },
163
+ set(newValue) {
164
+ localCurrentDateFromLocal.value = $formattedDate(
165
+ new Date(newValue),
166
+ dateFormatForUpdate.value
167
+ )
168
+ currentTimeFromLocal.value = $formattedTime(newValue, '', true)
169
+ },
170
+ })
171
+
172
+ const constructedDateToLocal = computed<number>({
173
+ get() {
174
+ // TODO fix PM
175
+ return $isDate(currentDateToLocal.value)
176
+ ? $getUnixByDate(
177
+ currentDateToLocal.value + ' ' + currentTimeToLocal.value
178
+ )
179
+ : 0
180
+ },
181
+ set(newValue) {
182
+ currentDateToLocal.value = $formattedDate(
183
+ new Date(newValue),
184
+ dateFormatForUpdate.value
185
+ )
186
+ currentTimeToLocal.value = $formattedTime(newValue, '', true)
187
+ },
188
+ })
189
+ </script>
190
+
191
+ <style>
192
+ :root {
193
+ --chart-options-timespan-blocks-bg: #ffffff;
194
+ --chart-options-timespan-blocks-title-color: #4d5d69;
195
+ }
196
+ :root.dark-theme {
197
+ --chart-options-timespan-blocks-bg: #334453;
198
+ --chart-options-timespan-blocks-title-color: #e9eaec;
199
+ }
200
+ </style>
201
+ <style scoped lang="scss">
202
+ .timespan-form-container {
203
+ padding: 12px;
204
+ background: var(--chart-options-timespan-blocks-bg);
205
+ box-shadow: 0 1px 4px 0 #00000014;
206
+ border-radius: 8px;
207
+
208
+ .block-title {
209
+ color: var(--chart-options-timespan-blocks-title-color);
210
+ font-size: 14px;
211
+ font-weight: 500;
212
+ margin-bottom: 16px;
213
+ }
214
+ .radio-container {
215
+ display: flex;
216
+ flex-direction: column;
217
+ grid-gap: 12px;
218
+ margin-top: 16px;
219
+
220
+ .row-container {
221
+ display: grid;
222
+ grid-template-columns: 1fr 1fr;
223
+ grid-gap: 12px;
224
+
225
+ :deep(.ui-input-with-datepicker) {
226
+ grid-gap: 12px;
227
+ }
228
+ }
229
+ :deep(.ui-input-with-datepicker) {
230
+ grid-gap: 12px;
231
+ }
232
+ }
233
+
234
+ .date-time-info {
235
+ font-weight: 400;
236
+ font-size: 12px;
237
+ color: #9da6ad;
238
+ margin-top: 16px;
239
+ }
240
+ }
241
+ </style>
@@ -215,7 +215,7 @@ const emits = defineEmits<{
215
215
  user-select: none;
216
216
  cursor: default;
217
217
  .context-icon {
218
- opacity: 0.5;
218
+ opacity: 0.4;
219
219
  }
220
220
  .shortcut {
221
221
  color: var(--context-menu-text-disabled-color);
@@ -1,5 +1,5 @@
1
1
  <template>
2
- <div class="graph-content">
2
+ <div :class="['graph-content', ...hiddenButtons]">
3
3
  <template v-if="props.chartOptions">
4
4
  <client-only>
5
5
  <highchart
@@ -16,6 +16,18 @@
16
16
  const props = defineProps<{
17
17
  chartOptions: any
18
18
  }>()
19
+
20
+ const hiddenButtons = computed<string[]>(() => {
21
+ const result = []
22
+ const chartOptions = props.chartOptions
23
+ if (chartOptions) {
24
+ const { openNewWindow } = chartOptions.exporting.menuItemDefinitions || {}
25
+
26
+ if (openNewWindow.isHide) result.push('hide-new-window')
27
+ }
28
+
29
+ return result
30
+ })
19
31
  </script>
20
32
 
21
33
  <style scoped lang="scss">
@@ -24,6 +36,13 @@ const props = defineProps<{
24
36
  //height: inherit;
25
37
  height: 100%;
26
38
 
39
+ &.hide-new-window {
40
+ :deep(.highcharts-menu) {
41
+ .highcharts-menu-item:first-child {
42
+ display: none;
43
+ }
44
+ }
45
+ }
27
46
  .graph-block {
28
47
  height: 100%;
29
48
  }