bfg-common 1.4.839 → 1.4.841

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 -4
  2. package/assets/localization/local_en.json +17 -4
  3. package/assets/localization/local_hy.json +17 -4
  4. package/assets/localization/local_kk.json +17 -4
  5. package/assets/localization/local_ru.json +18 -5
  6. package/assets/localization/local_zh.json +17 -4
  7. package/components/atoms/collapse/CollapseNav.vue +4 -4
  8. package/components/atoms/dropdown/dropdown/Dropdown.vue +12 -0
  9. package/components/atoms/table/dataGrid/DataGridColumnSwitch.vue +2 -2
  10. package/components/atoms/table/dataGrid/lib/utils/export.ts +1 -1
  11. package/components/common/graph/GraphNew.vue +176 -176
  12. package/components/common/modals/confirmByInput/ConfirmByInput.vue +57 -177
  13. package/components/common/modals/confirmByInput/ConfirmByInputNew.vue +103 -0
  14. package/components/common/modals/confirmByInput/ConfirmByInputOld.vue +204 -0
  15. package/components/common/monitor/advanced/Advanced.vue +196 -170
  16. package/components/common/monitor/advanced/AdvancedNew.vue +181 -206
  17. package/components/common/monitor/advanced/AdvancedOld.vue +12 -40
  18. package/components/common/monitor/advanced/graphView/GraphView.vue +181 -170
  19. package/components/common/monitor/advanced/graphView/GraphViewNew.vue +35 -35
  20. package/components/common/monitor/advanced/graphView/GraphViewOld.vue +56 -56
  21. package/components/common/monitor/advanced/table/Table.vue +31 -31
  22. package/components/common/monitor/advanced/table/tableNew/TableNew.vue +85 -85
  23. package/components/common/monitor/advanced/table/tableNew/lib/config/options.ts +139 -139
  24. package/components/common/monitor/advanced/table/tableNew/lib/utils/constructBody.ts +27 -27
  25. package/components/common/monitor/advanced/tools/Tools.vue +304 -163
  26. package/components/common/monitor/advanced/tools/ToolsNew.vue +220 -366
  27. package/components/common/monitor/advanced/tools/ToolsOld.vue +29 -165
  28. package/components/common/pages/tasks/Tasks.vue +3 -1
  29. package/components/common/pages/tasks/table/Table.vue +1 -0
  30. package/components/common/pages/tasks/table/errorInfo/ErrorInfo.vue +23 -7
  31. package/components/common/pages/tasks/table/expandDetails/ExpandDetails.vue +1 -0
  32. package/components/common/pages/tasks/table/lib/config/config.ts +2 -2
  33. package/components/common/portlets/customAttributes/Portlet.vue +9 -2
  34. package/components/common/portlets/customAttributes/lib/config/config.ts +7 -0
  35. package/components/common/portlets/tag/Portlet.vue +9 -2
  36. package/components/common/portlets/tag/lib/config/config.ts +7 -0
  37. package/components/common/tools/Actions.vue +5 -2
  38. package/lib/config/uiTable.ts +20 -20
  39. package/lib/models/store/interfaces.ts +1 -0
  40. package/package.json +2 -2
@@ -1,170 +1,181 @@
1
- <template>
2
- <common-monitor-advanced-graph-view-new
3
- v-if="isNewView"
4
- :loading="props.loading"
5
- :is-loading="isLoading"
6
- :chart-data="chartData"
7
- :chart="chart"
8
- :chart-helper="chartHelper"
9
- :export-type="props.export"
10
- :selected-row="props.selectedRow"
11
- :group-name="props.data?.groupName || ''"
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
- </template>
24
-
25
- <script setup lang="ts">
26
- import type {
27
- I_LineGraph,
28
- I_SeriesLine,
29
- } from 'bfg-nuxt-3-graph/graph/lib/models/interfaces'
30
- import { useDebounceFn, useElementSize } from '@vueuse/core'
31
- import { graphDataFunc } from 'bfg-nuxt-3-graph/graph/lib/utils/renderGraph'
32
- import { format } from 'date-fns'
33
- import type { UI_I_Localization } from '~/lib/models/interfaces'
34
-
35
- const props = defineProps<{
36
- loading: boolean
37
- data: I_SeriesLine | null
38
- export: string
39
- selectedRow: number[]
40
- darkMode: boolean
41
- formattedDatetime: any
42
- getDateFormat: any
43
- language: string
44
- selectedChartType: string
45
- }>()
46
-
47
- const { $store }: any = useNuxtApp()
48
-
49
- const localization = computed<UI_I_Localization>(() => useLocal())
50
-
51
- const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
52
-
53
- const isLoading = ref<boolean>(true)
54
-
55
- const chartData = ref<I_LineGraph | null>(null)
56
-
57
- const isFullScreen = ref<boolean>(false)
58
- const chart = ref<any>(null)
59
- const chartHelper = ref<number>(0)
60
-
61
- const fullScreenCallBack = (newValue: boolean): void => {
62
- isFullScreen.value = newValue
63
- }
64
-
65
- const chartCallback = (newValue: any): void => {
66
- newValue && (chart.value = newValue)
67
- }
68
-
69
- watch(
70
- chart,
71
- (newValue) => {
72
- isLoading.value = !newValue?.hasLoaded
73
- },
74
- { immediate: true, deep: true }
75
- )
76
-
77
- let dateFormat = ''
78
-
79
- const chartsView = ref(null)
80
- const { width } = useElementSize(chartsView)
81
-
82
- const startChart = useDebounceFn(() => {
83
- if (!props.data || !width.value) return
84
-
85
- chartData.value = graphDataFunc(
86
- props.data,
87
- props.darkMode,
88
- localization.value,
89
- fullScreenCallBack,
90
- true,
91
- false,
92
- false,
93
- props.selectedChartType,
94
- '',
95
- Math.floor(width.value),
96
- chartCallback,
97
- props.formattedDatetime,
98
- format,
99
- dateFormat
100
- )
101
-
102
- chartHelper.value++
103
- }, 1000)
104
-
105
- watch(
106
- () => props.data,
107
- (newValue) => {
108
- if (!newValue) {
109
- isLoading.value = true
110
- return
111
- }
112
-
113
- startChart()
114
- },
115
- { immediate: true }
116
- )
117
-
118
- watch(
119
- () => props.darkMode,
120
- () => {
121
- startChart()
122
- }
123
- )
124
-
125
- watch(
126
- () => props.language,
127
- () => {
128
- dateFormat = props.getDateFormat(props.language)
129
- startChart()
130
- }
131
- )
132
-
133
- watch(
134
- () => props.selectedChartType,
135
- () => {
136
- startChart()
137
- },
138
- { immediate: true }
139
- )
140
-
141
- watch(width, (newValue) => {
142
- if (newValue) startChart()
143
-
144
- if (!chart.value?.isResizing) return
145
-
146
- chart.value.setSize(1, chart.chartHeight)
147
-
148
- if (isFullScreen.value) {
149
- chart.value.setSize(window.innerWidth, chart.chartHeight)
150
- return
151
- }
152
-
153
- setTimeout(() => {
154
- chart.value.setSize(newValue, chart.chartHeight)
155
- }, 1000)
156
- })
157
-
158
- const exportType = ref<string>('')
159
- watch(
160
- () => props.export,
161
- (newValue) => {
162
- if (!newValue) return
163
-
164
- exportType.value = newValue
165
- },
166
- { immediate: true }
167
- )
168
- </script>
169
-
170
- <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
+ :group-name="props.data?.groupName || ''"
13
+ />
14
+ <common-monitor-advanced-graph-view-old
15
+ v-else
16
+ :loading="props.loading"
17
+ :is-loading="isLoading"
18
+ :chart-data="chartData"
19
+ :chart="chart"
20
+ :chart-helper="chartHelper"
21
+ :export-type="props.export"
22
+ :selected-row="props.selectedRow"
23
+ />
24
+ </div>
25
+ </template>
26
+
27
+ <script setup lang="ts">
28
+ import type {
29
+ I_LineGraph,
30
+ I_SeriesLine,
31
+ } from 'bfg-nuxt-3-graph/graph/lib/models/interfaces'
32
+ import { useDebounceFn, useElementSize } from '@vueuse/core'
33
+ import { graphDataFunc } from 'bfg-nuxt-3-graph/graph/lib/utils/renderGraph'
34
+ import { format } from 'date-fns'
35
+ import type { UI_I_Localization } from '~/lib/models/interfaces'
36
+
37
+ const props = defineProps<{
38
+ loading: boolean
39
+ data: I_SeriesLine | null
40
+ export: string
41
+ selectedRow: number[]
42
+ darkMode: boolean
43
+ language: string
44
+ selectedChartType: string
45
+ }>()
46
+ const emits = defineEmits<{
47
+ (event: 'open-advanced-page'): void
48
+ }>()
49
+
50
+ const { $store, $formattedDatetime, $getDateFormat }: any = useNuxtApp()
51
+
52
+ const localization = computed<UI_I_Localization>(() => useLocal())
53
+
54
+ const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
55
+
56
+ const isLoading = ref<boolean>(true)
57
+
58
+ const chartData = ref<I_LineGraph | null>(null)
59
+
60
+ const isFullScreen = ref<boolean>(false)
61
+ const chart = ref<any>(null)
62
+ const chartHelper = ref<number>(0)
63
+
64
+ const fullScreenCallBack = (newValue: boolean): void => {
65
+ isFullScreen.value = newValue
66
+ }
67
+
68
+ const chartCallback = (newValue: any): void => {
69
+ newValue && (chart.value = newValue)
70
+ }
71
+
72
+ const newTabCallback = (newValue: boolean): void => {
73
+ newValue && emits('open-advanced-page')
74
+ }
75
+
76
+ watch(
77
+ chart,
78
+ (newValue) => {
79
+ isLoading.value = !newValue?.hasLoaded
80
+ },
81
+ { immediate: true, deep: true }
82
+ )
83
+
84
+ let dateFormat = ''
85
+
86
+ const chartsView = ref(null)
87
+ const { width } = useElementSize(chartsView)
88
+
89
+ const startChart = useDebounceFn(() => {
90
+ if (!props.data || !width.value) return
91
+
92
+ chartData.value = graphDataFunc(
93
+ props.data,
94
+ props.darkMode,
95
+ localization.value,
96
+ fullScreenCallBack,
97
+ !isNewView.value,
98
+ isNewView.value,
99
+ false,
100
+ props.selectedChartType,
101
+ '',
102
+ Math.floor(width.value),
103
+ chartCallback,
104
+ $formattedDatetime,
105
+ format,
106
+ dateFormat,
107
+ undefined,
108
+ isNewView.value,
109
+ true,
110
+ newTabCallback
111
+ )
112
+
113
+ chartHelper.value++
114
+ }, 1000)
115
+
116
+ watch(
117
+ () => props.data,
118
+ (newValue) => {
119
+ if (!newValue) {
120
+ isLoading.value = true
121
+ return
122
+ }
123
+
124
+ startChart()
125
+ },
126
+ { immediate: true }
127
+ )
128
+
129
+ watch(
130
+ () => props.darkMode,
131
+ () => {
132
+ startChart()
133
+ }
134
+ )
135
+
136
+ watch(
137
+ () => props.language,
138
+ () => {
139
+ dateFormat = $getDateFormat(props.language)
140
+ startChart()
141
+ }
142
+ )
143
+
144
+ watch(
145
+ () => props.selectedChartType,
146
+ () => {
147
+ startChart()
148
+ },
149
+ { immediate: true }
150
+ )
151
+
152
+ watch(width, (newValue) => {
153
+ if (newValue) startChart()
154
+
155
+ if (!chart.value?.isResizing) return
156
+
157
+ chart.value.setSize(1, chart.chartHeight)
158
+
159
+ if (isFullScreen.value) {
160
+ chart.value.setSize(window.innerWidth, chart.chartHeight)
161
+ return
162
+ }
163
+
164
+ setTimeout(() => {
165
+ chart.value.setSize(newValue, chart.chartHeight)
166
+ }, 1000)
167
+ })
168
+
169
+ const exportType = ref<string>('')
170
+ watch(
171
+ () => props.export,
172
+ (newValue) => {
173
+ if (!newValue) return
174
+
175
+ exportType.value = newValue
176
+ },
177
+ { immediate: true }
178
+ )
179
+ </script>
180
+
181
+ <style scoped lang="scss"></style>
@@ -1,35 +1,35 @@
1
- <template>
2
- <div ref="chartsView" class="advanced-graph-container">
3
- <ui-skeleton-long-metric v-if="props.isLoading" :title="props.groupName" />
4
- <template v-if="!props.loading && props.chartData">
5
- <common-graph
6
- :chart="props.chart"
7
- :data="props.chartData"
8
- :update="props.chartHelper"
9
- :export-type="props.exportType"
10
- :selected-row="props.selectedRow"
11
- />
12
- </template>
13
- </div>
14
- </template>
15
-
16
- <script setup lang="ts">
17
- import type { I_LineGraph } from 'bfg-nuxt-3-graph/graph/lib/models/interfaces'
18
-
19
- const props = defineProps<{
20
- loading: boolean
21
- isLoading: boolean
22
- chartData: I_LineGraph | null
23
- chart: any
24
- chartHelper: number
25
- exportType: string
26
- selectedRow: number[]
27
- groupName: string
28
- }>()
29
- </script>
30
-
31
- <style scoped lang="scss">
32
- .advanced-graph-container {
33
- min-height: 400px;
34
- }
35
- </style>
1
+ <template>
2
+ <div class="advanced-graph-container">
3
+ <ui-skeleton-long-metric v-if="props.isLoading" :title="props.groupName" />
4
+ <template v-if="!props.loading && props.chartData">
5
+ <common-graph
6
+ :chart="props.chart"
7
+ :data="props.chartData"
8
+ :update="props.chartHelper"
9
+ :export-type="props.exportType"
10
+ :selected-row="props.selectedRow"
11
+ />
12
+ </template>
13
+ </div>
14
+ </template>
15
+
16
+ <script setup lang="ts">
17
+ import type { I_LineGraph } from 'bfg-nuxt-3-graph/graph/lib/models/interfaces'
18
+
19
+ const props = defineProps<{
20
+ loading: boolean
21
+ isLoading: boolean
22
+ chartData: I_LineGraph | null
23
+ chart: any
24
+ chartHelper: number
25
+ exportType: string
26
+ selectedRow: number[]
27
+ groupName: string
28
+ }>()
29
+ </script>
30
+
31
+ <style scoped lang="scss">
32
+ .advanced-graph-container {
33
+ min-height: 400px;
34
+ }
35
+ </style>
@@ -1,56 +1,56 @@
1
- <template>
2
- <div ref="chartsView" 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 { UI_I_Localization } from '~/lib/models/interfaces'
21
- import type { I_LineGraph } from 'bfg-nuxt-3-graph/graph/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: 1;
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 { UI_I_Localization } from '~/lib/models/interfaces'
21
+ import type { I_LineGraph } from 'bfg-nuxt-3-graph/graph/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: 1;
54
+ }
55
+ }
56
+ </style>
@@ -1,31 +1,31 @@
1
- <template>
2
- <common-monitor-advanced-table-table-new
3
- v-if="isNewView"
4
- :loading="props.loading"
5
- :items="props.data"
6
- @select="emits('select', $event)"
7
- />
8
- <common-monitor-advanced-table-table-old
9
- v-else
10
- :data="props.data"
11
- @select="emits('select', $event)"
12
- />
13
- </template>
14
-
15
- <script setup lang="ts">
16
- import type { UI_I_PerformanceItem } from '~/components/common/monitor/advanced/table/lib/models/interfaces'
17
-
18
- const props = defineProps<{
19
- loading: boolean
20
- data: UI_I_PerformanceItem[]
21
- }>()
22
- const emits = defineEmits<{
23
- (event: 'select', str: number[]): void
24
- }>()
25
-
26
- const { $store }: any = useNuxtApp()
27
-
28
- const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
29
- </script>
30
-
31
- <style scoped lang="scss"></style>
1
+ <template>
2
+ <common-monitor-advanced-table-table-new
3
+ v-if="isNewView"
4
+ :loading="props.loading"
5
+ :items="props.data"
6
+ @select="emits('select', $event)"
7
+ />
8
+ <common-monitor-advanced-table-table-old
9
+ v-else
10
+ :data="props.data"
11
+ @select="emits('select', $event)"
12
+ />
13
+ </template>
14
+
15
+ <script setup lang="ts">
16
+ import type { UI_I_PerformanceItem } from '~/components/common/monitor/advanced/table/lib/models/interfaces'
17
+
18
+ const props = defineProps<{
19
+ loading: boolean
20
+ data: UI_I_PerformanceItem[]
21
+ }>()
22
+ const emits = defineEmits<{
23
+ (event: 'select', str: number[]): void
24
+ }>()
25
+
26
+ const { $store }: any = useNuxtApp()
27
+
28
+ const isNewView = computed<boolean>(() => $store.getters['main/getIsNewView'])
29
+ </script>
30
+
31
+ <style scoped lang="scss"></style>