bfg-common 1.5.201 → 1.5.203

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 (24) hide show
  1. package/assets/img/icons/icons-sprite-dark-3.svg +227 -227
  2. package/assets/img/icons/icons-sprite-dark-5.svg +488 -488
  3. package/assets/img/icons/icons-sprite-light-3.svg +227 -227
  4. package/assets/img/icons/icons-sprite-light-5.svg +488 -488
  5. package/assets/localization/local_be.json +12 -3
  6. package/assets/localization/local_en.json +12 -3
  7. package/assets/localization/local_hy.json +12 -3
  8. package/assets/localization/local_kk.json +12 -3
  9. package/assets/localization/local_ru.json +14 -5
  10. package/assets/localization/local_zh.json +12 -3
  11. package/components/common/graph/GraphOld.vue +50 -50
  12. package/components/common/graph/graphNew/GraphNew.vue +194 -194
  13. package/components/common/lib/config/states.ts +1 -1
  14. package/components/common/monitor/advanced/graphView/GraphView.vue +178 -145
  15. package/components/common/monitor/advanced/graphView/GraphViewOld.vue +56 -56
  16. package/components/common/monitor/advanced/tools/chartOptionsModal/counters/CountersOld.vue +4 -0
  17. package/components/common/monitor/advanced/tools/chartOptionsModal/counters/table/lib/config/utils.ts +1040 -1040
  18. package/components/common/pages/scheduledTasks/modals/common/frequency/lib/config/frequencyOptions.ts +1 -1
  19. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/Cpu.vue +17 -2
  20. package/components/common/vm/actions/common/customizeHardware/virtualHardware/memory/Memory.vue +18 -2
  21. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/NewHardDisk.vue +11 -4
  22. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/NewHardDiskNew.vue +4 -0
  23. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/NewHardDiskOld.vue +25 -15
  24. package/package.json +2 -2
@@ -1,145 +1,178 @@
1
- <template>
2
- <div ref="chartsView">
3
- <common-monitor-advanced-graph-view-new
4
- v-if="isNewView"
5
- :loading="props.loading"
6
- :is-loading="isLoading"
7
- :chart-data="chartData"
8
- :chart="chart"
9
- :chart-helper="chartHelper"
10
- :export-type="props.export"
11
- :selected-row="props.selectedRow"
12
- />
13
- <common-monitor-advanced-graph-view-old
14
- v-else
15
- :loading="props.loading"
16
- :is-loading="isLoading"
17
- :chart-data="chartData"
18
- :chart="chart"
19
- :chart-helper="chartHelper"
20
- :export-type="props.export"
21
- :selected-row="props.selectedRow"
22
- />
23
- </div>
24
- </template>
25
-
26
- <script setup lang="ts">
27
- import type {
28
- I_LineGraph,
29
- I_SeriesLine,
30
- } from 'bfg-nuxt-3-graph/graph/lib/models/interfaces'
31
- import { useDebounceFn, useElementSize } from '@vueuse/core'
32
- import { graphDataFunc } from 'bfg-nuxt-3-graph/graph/lib/utils/renderGraph'
33
- import { format } from 'date-fns'
34
- import type { UI_I_Localization } from '~/lib/models/interfaces'
35
-
36
- const props = defineProps<{
37
- loading: boolean
38
- data: I_SeriesLine | null
39
- export: string
40
- selectedRow: number[]
41
- darkMode: boolean
42
- language: string
43
- selectedChartType: string
44
- }>()
45
- const emits = defineEmits<{
46
- (event: 'open-advanced-page'): void
47
- }>()
48
-
49
- const { $store, $formattedDatetime, $getDateFormat }: any = useNuxtApp()
50
-
51
- const localization = computed<UI_I_Localization>(() => useLocal())
52
-
53
- const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
54
-
55
- const isLoading = ref<boolean>(true)
56
-
57
- const chartData = ref<I_LineGraph | null>(null)
58
-
59
- const chart = ref<any>(null)
60
- const chartHelper = ref<number>(0)
61
-
62
- const chartCallback = (newValue: any): void => {
63
- newValue && (chart.value = newValue)
64
- }
65
-
66
- const newTabCallback = (newValue: boolean): void => {
67
- newValue && emits('open-advanced-page')
68
- }
69
-
70
- watch(
71
- chart,
72
- (newValue) => {
73
- isLoading.value = !newValue?.hasLoaded
74
- },
75
- { immediate: true, deep: true }
76
- )
77
-
78
- let dateFormat = ''
79
-
80
- const chartsView = ref(null)
81
- const { width } = useElementSize(chartsView)
82
-
83
- const startChart = useDebounceFn(() => {
84
- if (!props.data || !width.value) return
85
-
86
- chartData.value = graphDataFunc({
87
- fullScreenCallBack: () => ({}),
88
- format,
89
- graphData: props.data,
90
- isDarkMode: props.darkMode,
91
- localization: localization.value,
92
- disabledTitle: isNewView.value,
93
- disabledExportButton: !isNewView.value,
94
- disabledLegends: false,
95
- graphType: props.selectedChartType,
96
- width: Math.floor(width.value),
97
- chartCallBack: chartCallback,
98
- formattedDatetime: $formattedDatetime,
99
- formatDate: dateFormat,
100
- isNewView: isNewView.value,
101
- isShowLinkNewWindow: true,
102
- newTabCallBack: newTabCallback,
103
- })
104
-
105
- chartHelper.value++
106
- }, 1000)
107
-
108
- watch(
109
- () => props.data,
110
- (newValue) => {
111
- if (!newValue) {
112
- isLoading.value = true
113
- return
114
- }
115
-
116
- startChart()
117
- },
118
- { immediate: true }
119
- )
120
-
121
- watch(
122
- () => props.darkMode,
123
- () => {
124
- startChart()
125
- }
126
- )
127
-
128
- watch(
129
- () => props.language,
130
- () => {
131
- dateFormat = $getDateFormat(props.language)
132
- startChart()
133
- }
134
- )
135
-
136
- watch(
137
- () => props.selectedChartType,
138
- () => {
139
- startChart()
140
- },
141
- { immediate: true }
142
- )
143
- </script>
144
-
145
- <style scoped lang="scss"></style>
1
+ <template>
2
+ <div ref="chartsView">
3
+ <common-monitor-advanced-graph-view-new
4
+ v-if="isNewView"
5
+ :loading="props.loading"
6
+ :is-loading="isLoading"
7
+ :chart-data="chartData"
8
+ :chart="chart"
9
+ :chart-helper="chartHelper"
10
+ :export-type="props.export"
11
+ :selected-row="props.selectedRow"
12
+ />
13
+ <common-monitor-advanced-graph-view-old
14
+ v-else
15
+ :loading="props.loading"
16
+ :is-loading="isLoading"
17
+ :chart-data="chartData"
18
+ :chart="chart"
19
+ :chart-helper="chartHelper"
20
+ :export-type="props.export"
21
+ :selected-row="props.selectedRow"
22
+ />
23
+ </div>
24
+ </template>
25
+
26
+ <script setup lang="ts">
27
+ import type {
28
+ I_LineGraph,
29
+ I_SeriesLine,
30
+ } from 'bfg-nuxt-3-graph/graph/lib/models/interfaces'
31
+ import { useDebounceFn, useElementSize } from '@vueuse/core'
32
+ import { graphDataFunc } from 'bfg-nuxt-3-graph/graph/lib/utils/renderGraph'
33
+ import { format } from 'date-fns'
34
+ import type { UI_I_Localization } from '~/lib/models/interfaces'
35
+
36
+ const props = defineProps<{
37
+ loading: boolean
38
+ data: I_SeriesLine | null
39
+ export: string
40
+ selectedRow: number[]
41
+ darkMode: boolean
42
+ language: string
43
+ selectedChartType: string
44
+ }>()
45
+ const emits = defineEmits<{
46
+ (event: 'open-advanced-page'): void
47
+ }>()
48
+
49
+ const { $store, $formattedDatetime, $getDateFormat }: any = useNuxtApp()
50
+
51
+ const localization = computed<UI_I_Localization>(() => useLocal())
52
+
53
+ const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
54
+
55
+ const isLoading = ref<boolean>(true)
56
+
57
+ const chartData = ref<I_LineGraph | null>(null)
58
+
59
+ const isFullScreen = ref<boolean>(false)
60
+ const chart = ref<any>(null)
61
+ const chartHelper = ref<number>(0)
62
+
63
+ const fullScreenCallBack = (newValue: boolean): void => {
64
+ isFullScreen.value = newValue
65
+ }
66
+
67
+ const chartCallback = (newValue: any): void => {
68
+ newValue && (chart.value = newValue)
69
+ }
70
+
71
+ const newTabCallback = (newValue: boolean): void => {
72
+ newValue && emits('open-advanced-page')
73
+ }
74
+
75
+ watch(
76
+ chart,
77
+ (newValue) => {
78
+ isLoading.value = !newValue?.hasLoaded
79
+ },
80
+ { immediate: true, deep: true }
81
+ )
82
+
83
+ let dateFormat = ''
84
+
85
+ const chartsView = ref(null)
86
+ const { width } = useElementSize(chartsView)
87
+
88
+ const startChart = useDebounceFn(() => {
89
+ if (!props.data || !width.value) return
90
+
91
+ chartData.value = graphDataFunc({
92
+ fullScreenCallBack,
93
+ format,
94
+ graphData: props.data,
95
+ isDarkMode: props.darkMode,
96
+ localization: localization.value,
97
+ disabledTitle: isNewView.value,
98
+ disabledExportButton: !isNewView.value,
99
+ disabledLegends: false,
100
+ graphType: props.selectedChartType,
101
+ width: Math.floor(width.value),
102
+ chartCallBack: chartCallback,
103
+ formattedDatetime: $formattedDatetime,
104
+ formatDate: dateFormat,
105
+ isNewView: isNewView.value,
106
+ isShowLinkNewWindow: true,
107
+ newTabCallBack: newTabCallback,
108
+ })
109
+
110
+ chartHelper.value++
111
+ }, 1000)
112
+
113
+ watch(
114
+ () => props.data,
115
+ (newValue) => {
116
+ if (!newValue) {
117
+ isLoading.value = true
118
+ return
119
+ }
120
+
121
+ startChart()
122
+ },
123
+ { immediate: true }
124
+ )
125
+
126
+ watch(
127
+ () => props.darkMode,
128
+ () => {
129
+ startChart()
130
+ }
131
+ )
132
+
133
+ watch(
134
+ () => props.language,
135
+ () => {
136
+ dateFormat = $getDateFormat(props.language)
137
+ startChart()
138
+ }
139
+ )
140
+
141
+ watch(
142
+ () => props.selectedChartType,
143
+ () => {
144
+ startChart()
145
+ },
146
+ { immediate: true }
147
+ )
148
+
149
+ watch(width, (newValue) => {
150
+ if (newValue) startChart()
151
+
152
+ if (!chart.value?.isResizing) return
153
+
154
+ chart.value.setSize(1, chart.chartHeight)
155
+
156
+ if (isFullScreen.value) {
157
+ chart.value.setSize(window.innerWidth, chart.chartHeight)
158
+ return
159
+ }
160
+
161
+ setTimeout(() => {
162
+ chart.value.setSize(newValue, chart.chartHeight)
163
+ }, 1000)
164
+ })
165
+
166
+ const exportType = ref<string>('')
167
+ watch(
168
+ () => props.export,
169
+ (newValue) => {
170
+ if (!newValue) return
171
+
172
+ exportType.value = newValue
173
+ },
174
+ { immediate: true }
175
+ )
176
+ </script>
177
+
178
+ <style scoped lang="scss"></style>
@@ -1,56 +1,56 @@
1
- <template>
2
- <div class="advanced-graph-container">
3
- <div v-if="props.isLoading" class="graphic-loader-block">
4
- <div class="spinner"></div>
5
- <p>{{ localization.inventoryMonitor.retrievingData }}...</p>
6
- </div>
7
- <template v-if="!props.loading && props.chartData">
8
- <common-graph
9
- :chart="props.chart"
10
- :data="props.chartData"
11
- :update="props.chartHelper"
12
- :export-type="props.exportType"
13
- :selected-row="props.selectedRow"
14
- />
15
- </template>
16
- </div>
17
- </template>
18
-
19
- <script setup lang="ts">
20
- import type { I_LineGraph } from '~/node_modules/bfg-nuxt-3-graph/graph/lib/models/interfaces'
21
- import type { UI_I_Localization } from '~/lib/models/interfaces'
22
-
23
- const localization = computed<UI_I_Localization>(() => useLocal())
24
-
25
- const props = defineProps<{
26
- loading: boolean
27
- isLoading: boolean
28
- chartData: I_LineGraph | null
29
- chart: any
30
- chartHelper: number
31
- exportType: string
32
- selectedRow: number[]
33
- }>()
34
- </script>
35
-
36
- <style scoped lang="scss">
37
- .advanced-graph-container {
38
- position: relative;
39
- min-height: 400px;
40
-
41
- .graphic-loader-block {
42
- background-color: var(--loader-bg-color);
43
- height: 100%;
44
- display: flex;
45
- flex-direction: column;
46
- align-items: center;
47
- justify-content: center;
48
- position: absolute;
49
- top: 0;
50
- left: 0;
51
- right: 0;
52
- bottom: 0;
53
- z-index: var(--z-fixed);
54
- }
55
- }
56
- </style>
1
+ <template>
2
+ <div class="advanced-graph-container">
3
+ <div v-if="props.isLoading" class="graphic-loader-block">
4
+ <div class="spinner"></div>
5
+ <p>{{ localization.inventoryMonitor.retrievingData }}...</p>
6
+ </div>
7
+ <template v-if="!props.loading && props.chartData">
8
+ <common-graph
9
+ :chart="props.chart"
10
+ :data="props.chartData"
11
+ :update="props.chartHelper"
12
+ :export-type="props.exportType"
13
+ :selected-row="props.selectedRow"
14
+ />
15
+ </template>
16
+ </div>
17
+ </template>
18
+
19
+ <script setup lang="ts">
20
+ import type { I_LineGraph } from '~/node_modules/bfg-nuxt-3-graph/graph/lib/models/interfaces'
21
+ import type { UI_I_Localization } from '~/lib/models/interfaces'
22
+
23
+ const localization = computed<UI_I_Localization>(() => useLocal())
24
+
25
+ const props = defineProps<{
26
+ loading: boolean
27
+ isLoading: boolean
28
+ chartData: I_LineGraph | null
29
+ chart: any
30
+ chartHelper: number
31
+ exportType: string
32
+ selectedRow: number[]
33
+ }>()
34
+ </script>
35
+
36
+ <style scoped lang="scss">
37
+ .advanced-graph-container {
38
+ position: relative;
39
+ min-height: 400px;
40
+
41
+ .graphic-loader-block {
42
+ background-color: var(--loader-bg-color);
43
+ height: 100%;
44
+ display: flex;
45
+ flex-direction: column;
46
+ align-items: center;
47
+ justify-content: center;
48
+ position: absolute;
49
+ top: 0;
50
+ left: 0;
51
+ right: 0;
52
+ bottom: 0;
53
+ z-index: var(--z-fixed);
54
+ }
55
+ }
56
+ </style>
@@ -100,6 +100,10 @@ const emits = defineEmits<{
100
100
  flex-basis: 80%;
101
101
  padding-left: 15px;
102
102
  max-width: 80%;
103
+
104
+ :deep(.datagrid .datagrid-cell span):first-letter {
105
+ text-transform: capitalize;
106
+ }
103
107
  }
104
108
  @media (max-width: 1024px) {
105
109
  .chart-option-counters-container {