@dative-gpi/foundation-core-components 1.0.44 → 1.0.46

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 (42) hide show
  1. package/components/autocompletes/FSAutocompleteChart.vue +2 -1
  2. package/components/autocompletes/FSAutocompleteDashboard.vue +1 -1
  3. package/components/autocompletes/FSAutocompleteRole.vue +2 -1
  4. package/components/customProperties/FSMetaField.vue +2 -1
  5. package/components/customProperties/FSMetaValue.vue +2 -1
  6. package/components/customProperties/helpers.ts +2 -1
  7. package/components/entities/FSBaseEntitiesList.vue +50 -0
  8. package/components/entities/FSDialogSelectEntities.vue +171 -0
  9. package/components/entities/FSEntityField.vue +143 -0
  10. package/components/entities/FSSimpleEntitiesList.vue +100 -0
  11. package/components/lists/authTokens/FSBaseAuthTokensList.vue +76 -0
  12. package/components/lists/dashboards/FSBaseDashboardsList.vue +222 -0
  13. package/components/lists/dashboards/FSSimpleDashboardsList.vue +63 -0
  14. package/components/lists/deviceOrganisations/FSBaseDeviceOrganisationsList.vue +260 -0
  15. package/components/lists/deviceOrganisations/FSSimpleDeviceOrganisationsList.vue +44 -0
  16. package/components/lists/folders/FSBaseFoldersList.vue +241 -0
  17. package/components/lists/folders/FSSimpleFoldersList.vue +44 -0
  18. package/components/lists/groups/FSBaseGroupsList.vue +119 -0
  19. package/components/lists/groups/FSSimpleGroupsList.vue +44 -0
  20. package/components/lists/locations/FSBaseLocationsList.vue +79 -0
  21. package/components/lists/locations/FSSimpleLocationsList.vue +44 -0
  22. package/components/lists/models/FSSimpleModelsList.vue +44 -0
  23. package/components/lists/userOrganisations/FSBaseUserOrganisationsList.vue +158 -0
  24. package/components/lists/userOrganisations/FSSimpleUserOrganisationsList.vue +45 -0
  25. package/components/selects/FSAggregationSelector.vue +1 -1
  26. package/components/selects/FSAxisTypeSelector.vue +1 -1
  27. package/components/selects/FSDisplayAsSelector.vue +1 -1
  28. package/components/selects/FSFilterTypeSelector.vue +1 -1
  29. package/components/selects/FSHeatmapRuleSelector.vue +1 -1
  30. package/components/selects/FSOperationOnSelector.vue +1 -1
  31. package/components/selects/FSPlanningTypeSelector.vue +1 -1
  32. package/components/selects/FSPlotPerSelector.vue +1 -1
  33. package/components/selects/{FSSelectSelectedEntities.vue → FSSelectEntityType.vue} +12 -12
  34. package/components/selects/FSSerieTypeSelector.vue +1 -1
  35. package/package.json +7 -7
  36. package/utils/charts.ts +2 -1
  37. package/utils/dashboards.ts +30 -2
  38. package/utils/index.ts +2 -1
  39. package/utils/permissions.ts +80 -0
  40. package/utils/roles.ts +1 -1
  41. package/utils/tables.ts +41 -0
  42. package/utils/users.ts +1 -1
@@ -0,0 +1,158 @@
1
+ <template>
2
+ <FSDataTable
3
+ :items="userOrganisations"
4
+ :itemTo="$props.itemTo"
5
+ :modelValue="$props.modelValue"
6
+ :tableCode="$props.tableCode"
7
+ @update:modelValue="$emit('update:modelValue', $event)"
8
+ v-bind="$attrs"
9
+ >
10
+ <template
11
+ v-for="(_, name) in $slots"
12
+ v-slot:[name]="slotData"
13
+ >
14
+ <slot
15
+ :name="name"
16
+ v-bind="slotData"
17
+ />
18
+ </template>
19
+ <template
20
+ #item.imageId="{ item }"
21
+ >
22
+ <FSImage
23
+ v-if="item.imageId"
24
+ height="32px"
25
+ width="32px"
26
+ :imageId="item.imageId"
27
+ />
28
+ </template>
29
+ <template
30
+ #item.allowEmails="{ item }"
31
+ >
32
+ <FSIconCheck
33
+ :value="item.allowEmails"
34
+ />
35
+ </template>
36
+ <template
37
+ #item.allowSms="{ item }"
38
+ >
39
+ <FSIconCheck
40
+ :value="item.allowSms"
41
+ />
42
+ </template>
43
+ <template
44
+ #item.tags="{ item }"
45
+ >
46
+ <FSTagGroup
47
+ variant="slide"
48
+ :editable="false"
49
+ :tags="item.tags"
50
+ />
51
+ </template>
52
+ <template
53
+ #item.validity="{ item }"
54
+ >
55
+ <FSSpan
56
+ font="text-overline"
57
+ >
58
+ {{ userValidityLabel(item.validity) }}
59
+ </FSSpan>
60
+ </template>
61
+ <template
62
+ #item.userType="{ item }"
63
+ >
64
+ <FSSpan
65
+ font="text-overline"
66
+ >
67
+ {{ userTypeLabel(item.userType) }}
68
+ </FSSpan>
69
+ </template>
70
+ <template
71
+ #item.tile="{ item, toggleSelect }"
72
+ >
73
+ <FSUserOrganisationTileUI
74
+ :roleLabel="item.roleLabel"
75
+ :roleIcon="item.roleIcon"
76
+ :userType="item.userType"
77
+ :imageId="item.imageId"
78
+ :admin="item.admin"
79
+ :name="item.name"
80
+ :to="$props.itemTo && $props.itemTo(item)"
81
+ :modelValue="isSelected(item.id)"
82
+ @update:modelValue="toggleSelect(item)"
83
+ />
84
+ </template>
85
+ </FSDataTable>
86
+ </template>
87
+
88
+ <script lang="ts">
89
+ import type { PropType} from "vue";
90
+ import { defineComponent, watch } from "vue";
91
+ import type { RouteLocation } from "vue-router";
92
+ import _ from "lodash";
93
+
94
+ import type { UserOrganisationFilters, UserOrganisationInfos } from "@dative-gpi/foundation-core-domain/models";
95
+ import { userTypeLabel, userValidityLabel } from "@dative-gpi/foundation-core-components/utils";
96
+ import { useUserOrganisations } from "@dative-gpi/foundation-core-services/composables";
97
+
98
+ import FSDataTable from "../FSDataTable.vue";
99
+ import FSSpan from "@dative-gpi/foundation-shared-components/components/FSSpan.vue";
100
+ import FSImage from "@dative-gpi/foundation-shared-components/components/FSImage.vue";
101
+ import FSTagGroup from "@dative-gpi/foundation-shared-components/components/FSTagGroup.vue";
102
+ import FSIconCheck from "@dative-gpi/foundation-shared-components/components/FSIconCheck.vue";
103
+ import FSUserOrganisationTileUI from "@dative-gpi/foundation-shared-components/components/tiles/FSUserOrganisationTileUI.vue";
104
+
105
+ export default defineComponent({
106
+ name: "FSBaseUserOrganisationsList",
107
+ components: {
108
+ FSDataTable,
109
+ FSImage,
110
+ FSUserOrganisationTileUI,
111
+ FSSpan,
112
+ FSTagGroup,
113
+ FSIconCheck
114
+
115
+ },
116
+ props: {
117
+ userOrganisationsFilters: {
118
+ type: Object as PropType<UserOrganisationFilters | null>,
119
+ required: false,
120
+ default: null
121
+ },
122
+ modelValue: {
123
+ type: Array as PropType<string[]>,
124
+ required: false,
125
+ default: () => []
126
+ },
127
+ itemTo: {
128
+ type: Function as PropType<(item: UserOrganisationInfos) => Partial<RouteLocation>>,
129
+ required: false
130
+ },
131
+ tableCode: {
132
+ type: String,
133
+ required: true
134
+ }
135
+ },
136
+ emits: ["update:modelValue"],
137
+ setup(props) {
138
+ const { getMany: fetchUserOrganisations, entities: userOrganisations } = useUserOrganisations();
139
+
140
+ const isSelected = (id: string): boolean => {
141
+ return props.modelValue.includes(id);
142
+ };
143
+
144
+ watch(() => props.userOrganisationsFilters, (next, previous) => {
145
+ if ((!next && !previous) || !_.isEqual(next, previous)) {
146
+ fetchUserOrganisations(props.userOrganisationsFilters ?? undefined);
147
+ }
148
+ }, { immediate: true });
149
+
150
+ return {
151
+ userOrganisations,
152
+ userValidityLabel,
153
+ userTypeLabel,
154
+ isSelected
155
+ };
156
+ }
157
+ });
158
+ </script>
@@ -0,0 +1,45 @@
1
+ <template>
2
+ <FSSimpleList
3
+ :items="userOrganisations"
4
+ itemLabel="name"
5
+ :loading="fetching"
6
+ v-bind="$attrs"
7
+ />
8
+ </template>
9
+
10
+ <script lang="ts">
11
+ import { defineComponent, type PropType, watch } from "vue";
12
+
13
+ import type { UserOrganisationFilters } from "@dative-gpi/foundation-core-domain/models";
14
+ import { useUserOrganisations } from "@dative-gpi/foundation-core-services/composables";
15
+
16
+ import FSSimpleList from "@dative-gpi/foundation-shared-components/components/lists/FSSimpleList.vue";
17
+
18
+ export default defineComponent({
19
+ name: "FSSimpleUserOrganisationsList",
20
+ components: {
21
+ FSSimpleList,
22
+ },
23
+ props: {
24
+ userOrganisationFilters: {
25
+ type: Object as PropType<UserOrganisationFilters>,
26
+ required: false,
27
+ default: () => ({})
28
+ }
29
+ },
30
+ setup(props){
31
+ const { entities: userOrganisations, getMany, fetching } = useUserOrganisations();
32
+
33
+ const fetch = () => {
34
+ getMany(props.userOrganisationFilters);
35
+ }
36
+
37
+ watch(() => props.userOrganisationFilters, fetch, { immediate: true });
38
+
39
+ return {
40
+ userOrganisations,
41
+ fetching
42
+ }
43
+ }
44
+ });
45
+ </script>
@@ -11,7 +11,7 @@
11
11
  <script lang="ts">
12
12
  import { computed, defineComponent, type PropType } from "vue";
13
13
 
14
- import {AggregationType} from "@dative-gpi/foundation-core-domain/models";
14
+ import { AggregationType } from "@dative-gpi/foundation-shared-domain/enums";
15
15
 
16
16
  import {aggregationTypeLabel, getEnumEntries} from "../../utils";
17
17
 
@@ -11,7 +11,7 @@
11
11
  <script lang="ts">
12
12
  import { computed, defineComponent, type PropType } from "vue";
13
13
 
14
- import {AxisType} from "@dative-gpi/foundation-core-domain/models";
14
+ import {AxisType} from "@dative-gpi/foundation-shared-domain/enums";
15
15
 
16
16
  import {axisTypeLabel, getEnumEntries} from "../../utils";
17
17
 
@@ -11,7 +11,7 @@
11
11
  <script lang="ts">
12
12
  import { computed, defineComponent, type PropType } from "vue";
13
13
 
14
- import {DisplayAs} from "@dative-gpi/foundation-core-domain/models";
14
+ import {DisplayAs} from "@dative-gpi/foundation-shared-domain/enums";
15
15
 
16
16
  import FSAutocompleteField from "@dative-gpi/foundation-shared-components/components/fields/FSAutocompleteField.vue";
17
17
 
@@ -12,7 +12,7 @@
12
12
  <script lang="ts">
13
13
  import { computed, defineComponent, type PropType } from "vue";
14
14
 
15
- import {FilterType} from "@dative-gpi/foundation-core-domain/models";
15
+ import {FilterType} from "@dative-gpi/foundation-shared-domain/enums";
16
16
 
17
17
  import FSAutocompleteField from "@dative-gpi/foundation-shared-components/components/fields/FSAutocompleteField.vue";
18
18
 
@@ -11,7 +11,7 @@
11
11
  <script lang="ts">
12
12
  import { computed, defineComponent, type PropType } from "vue";
13
13
 
14
- import {HeatmapRule} from "@dative-gpi/foundation-core-domain/models";
14
+ import {HeatmapRule} from "@dative-gpi/foundation-shared-domain/enums";
15
15
 
16
16
  import FSAutocompleteField from "@dative-gpi/foundation-shared-components/components/fields/FSAutocompleteField.vue";
17
17
 
@@ -11,7 +11,7 @@
11
11
  <script lang="ts">
12
12
  import { computed, defineComponent, type PropType } from "vue";
13
13
 
14
- import {OperationOn} from "@dative-gpi/foundation-core-domain/models";
14
+ import {OperationOn} from "@dative-gpi/foundation-shared-domain/enums";
15
15
 
16
16
  import FSAutocompleteField from "@dative-gpi/foundation-shared-components/components/fields/FSAutocompleteField.vue";
17
17
 
@@ -11,7 +11,7 @@
11
11
  <script lang="ts">
12
12
  import { computed, defineComponent, type PropType } from "vue";
13
13
 
14
- import {PlanningType} from "@dative-gpi/foundation-core-domain/models";
14
+ import {PlanningType} from "@dative-gpi/foundation-shared-domain/enums";
15
15
 
16
16
  import FSAutocompleteField from "@dative-gpi/foundation-shared-components/components/fields/FSAutocompleteField.vue";
17
17
 
@@ -11,7 +11,7 @@
11
11
  <script lang="ts">
12
12
  import { computed, defineComponent, type PropType } from "vue";
13
13
 
14
- import {PlotPer} from "@dative-gpi/foundation-core-domain/models";
14
+ import {PlotPer} from "@dative-gpi/foundation-shared-domain/enums";
15
15
 
16
16
  import FSAutocompleteField from "@dative-gpi/foundation-shared-components/components/fields/FSAutocompleteField.vue";
17
17
 
@@ -1,6 +1,6 @@
1
1
  <template>
2
2
  <FSSelectField
3
- :items="selectedEntities"
3
+ :items="entityTypes"
4
4
  :clearable="false"
5
5
  :modelValue="$props.modelValue"
6
6
  @update:modelValue="$emit('update:modelValue', $event)"
@@ -13,20 +13,20 @@ import type { PropType} from "vue";
13
13
  import { computed, defineComponent } from "vue";
14
14
 
15
15
  import { useTranslations as useTranslationsProvider } from "@dative-gpi/bones-ui/composables";
16
- import { SelectedEntities } from "@dative-gpi/foundation-core-domain/models";
16
+ import { EntityType } from "@dative-gpi/foundation-shared-domain/enums";
17
17
 
18
18
  import FSSelectField from "@dative-gpi/foundation-shared-components/components/fields/FSSelectField.vue";
19
19
 
20
20
  export default defineComponent({
21
- name: "FSSelectSelectedEntities",
21
+ name: "FSSelectEntityType",
22
22
  components: {
23
23
  FSSelectField
24
24
  },
25
25
  props: {
26
26
  modelValue: {
27
- type: Number as PropType<SelectedEntities>,
27
+ type: Number as PropType<EntityType>,
28
28
  required: false,
29
- default: SelectedEntities.Devices
29
+ default: EntityType.Device
30
30
  },
31
31
  useNone: {
32
32
  type: Boolean,
@@ -38,21 +38,21 @@ export default defineComponent({
38
38
  setup(props) {
39
39
  const { $tr } = useTranslationsProvider();
40
40
 
41
- const selectedEntities = computed((): { id: SelectedEntities; label: string }[] => {
41
+ const entityTypes = computed((): { id: EntityType; label: string }[] => {
42
42
  const items = [
43
- { id: SelectedEntities.Models, label: $tr("ui.selected-entities.models", "Models") },
44
- { id: SelectedEntities.Devices, label: $tr("ui.selected-entities.devices", "Devices") },
45
- { id: SelectedEntities.Groups, label: $tr("ui.selected-entities.groups", "Groups") },
46
- { id: SelectedEntities.Locations, label: $tr("ui.selected-entities.locations", "Locations") }
43
+ { id: EntityType.Model, label: $tr("ui.entity-type.models", "Models") },
44
+ { id: EntityType.Device, label: $tr("ui.entity-type.devices", "Devices") },
45
+ { id: EntityType.Group, label: $tr("ui.entity-type.groups", "Groups") },
46
+ { id: EntityType.Location, label: $tr("ui.entity-type.locations", "Locations") }
47
47
  ];
48
48
  if (props.useNone) {
49
- items.unshift({ id: SelectedEntities.None, label: $tr("ui.selected-entities.none", "None") });
49
+ items.unshift({ id: EntityType.None, label: $tr("ui.entity-type.none", "None") });
50
50
  }
51
51
  return items;
52
52
  });
53
53
 
54
54
  return {
55
- selectedEntities
55
+ entityTypes
56
56
  };
57
57
  }
58
58
  });
@@ -11,7 +11,7 @@
11
11
  <script lang="ts">
12
12
  import { computed, defineComponent, type PropType } from "vue";
13
13
 
14
- import {SerieType} from "@dative-gpi/foundation-core-domain/models";
14
+ import {SerieType} from "@dative-gpi/foundation-shared-domain/enums";
15
15
 
16
16
  import FSAutocompleteField from "@dative-gpi/foundation-shared-components/components/fields/FSAutocompleteField.vue";
17
17
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@dative-gpi/foundation-core-components",
3
3
  "sideEffects": false,
4
- "version": "1.0.44",
4
+ "version": "1.0.46",
5
5
  "description": "",
6
6
  "publishConfig": {
7
7
  "access": "public"
@@ -10,11 +10,11 @@
10
10
  "author": "",
11
11
  "license": "ISC",
12
12
  "dependencies": {
13
- "@dative-gpi/foundation-core-domain": "1.0.44",
14
- "@dative-gpi/foundation-core-services": "1.0.44",
15
- "@dative-gpi/foundation-shared-components": "1.0.44",
16
- "@dative-gpi/foundation-shared-domain": "1.0.44",
17
- "@dative-gpi/foundation-shared-services": "1.0.44"
13
+ "@dative-gpi/foundation-core-domain": "1.0.46",
14
+ "@dative-gpi/foundation-core-services": "1.0.46",
15
+ "@dative-gpi/foundation-shared-components": "1.0.46",
16
+ "@dative-gpi/foundation-shared-domain": "1.0.46",
17
+ "@dative-gpi/foundation-shared-services": "1.0.46"
18
18
  },
19
19
  "peerDependencies": {
20
20
  "@dative-gpi/bones-ui": "^0.0.75",
@@ -26,5 +26,5 @@
26
26
  "sass": "1.71.1",
27
27
  "sass-loader": "13.3.2"
28
28
  },
29
- "gitHead": "4fc1ee85626231a579c6b9565da9b7b93f5f4ebd"
29
+ "gitHead": "2798111f89f8a6eefc603e3777cce7b08cd9f56b"
30
30
  }
package/utils/charts.ts CHANGED
@@ -1,9 +1,10 @@
1
- import { AggregationType, AxisType, ChartOrigin, DisplayAs, FilterType, HeatmapRule, OperationOn, PlanningType, PlotPer, SerieType } from "@dative-gpi/foundation-core-domain/models";
1
+ import { AggregationType, AxisType, ChartOrigin, DisplayAs, FilterType, HeatmapRule, OperationOn, PlanningType, PlotPer, SerieType } from "@dative-gpi/foundation-shared-domain/enums";
2
2
  import { useTranslations as useTranslationsProvider } from "@dative-gpi/bones-ui/composables";
3
3
  import { type ColorBase, ColorEnum } from "@dative-gpi/foundation-shared-components/models";
4
4
 
5
5
  const { $tr } = useTranslationsProvider();
6
6
 
7
+
7
8
  export const chartOriginLabel = (type: ChartOrigin): string => {
8
9
  switch (type) {
9
10
  case ChartOrigin.None: return $tr("ui.chart-type.none", "None");
@@ -1,6 +1,7 @@
1
+ import type { DashboardOrganisationInfos, DashboardOrganisationTypeInfos, DashboardShallowInfos, FolderInfos } from "@dative-gpi/foundation-core-domain/models";
1
2
  import { useTranslations as useTranslationsProvider } from "@dative-gpi/bones-ui/composables";
2
3
  import { type ColorBase, ColorEnum } from "@dative-gpi/foundation-shared-components/models";
3
- import { DashboardType } from "@dative-gpi/foundation-shared-domain/models"
4
+ import { DashboardType } from "@dative-gpi/foundation-shared-domain/enums";
4
5
 
5
6
  const { $tr } = useTranslationsProvider();
6
7
 
@@ -20,4 +21,31 @@ export const dashboardTypeColor = (type: DashboardType): ColorBase => {
20
21
  case DashboardType.Shallow: return ColorEnum.Primary;
21
22
  case DashboardType.OrganisationType: return ColorEnum.Warning;
22
23
  }
23
- };
24
+ };
25
+
26
+ export interface DashboardShallowListItem extends DashboardShallowInfos {
27
+ dashboardType: DashboardType.Shallow
28
+ type: FoldersListType.Dashboard
29
+ }
30
+
31
+ export interface DashboardOrganisationListItem extends DashboardOrganisationInfos {
32
+ dashboardType: DashboardType.Organisation
33
+ type: FoldersListType.Dashboard
34
+ }
35
+
36
+ export interface OrganisationTypeDashboardListItem extends DashboardOrganisationTypeInfos {
37
+ dashboardType: DashboardType.OrganisationType
38
+ }
39
+
40
+ export interface FolderListItem extends FolderInfos {
41
+ dashboardType: DashboardType.None
42
+ type: FoldersListType.Folder
43
+ }
44
+
45
+ export enum FoldersListType {
46
+ Dashboard = "dashboard",
47
+ Folder = "folder"
48
+ }
49
+
50
+ export type DashboardsListItem = DashboardShallowListItem | DashboardOrganisationListItem | OrganisationTypeDashboardListItem;
51
+ export type FoldersListItem = DashboardShallowListItem | DashboardOrganisationListItem | FolderListItem;
package/utils/index.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  export * from "./charts";
2
2
  export * from "./dashboards";
3
3
  export * from "./roles";
4
- export * from "./users";
4
+ export * from "./users";
5
+ export * as TABLES from "./tables";
@@ -0,0 +1,80 @@
1
+ export const ALERT_READ = "app.alert.infos";
2
+ export const ALERT_ACKNOWLEDGE = "app.alert.acknowledge";
3
+ export const ALERT_COMMENT = "app.alert.comment";
4
+ export const ALERT_REMOVE = "app.alert.remove";
5
+
6
+ export const CHARTORGANISATION_READ = "app.chartorganisation.read";
7
+ export const CHARTORGANISATION_CREATE = "app.chartorganisation.create";
8
+ export const CHARTORGANISATION_UPDATE = "app.chartorganisation.update";
9
+ export const CHARTORGANISATION_REMOVE = "app.chartorganisation.remove";
10
+
11
+ export const CHARTORGANISATIONTYPE_READ = "app.chartorganisationtype.read";
12
+ export const CHARTORGANISATIONTYPE_CREATE = "app.chartorganisationtype.create";
13
+ export const CHARTORGANISATIONTYPE_UPDATE = "app.chartorganisationtype.update";
14
+ export const CHARTORGANISATIONTYPE_REMOVE = "app.chartorganisationtype.remove";
15
+ export const CHARTORGANISATIONTYPE_SHARE = "app.chartorganisationtype.share";
16
+
17
+ export const DASHBOARDORGANISATION_READ = "app.dashboardorganisation.read";
18
+ export const DASHBOARDORGANISATION_CREATE = "app.dashboardorganisation.create";
19
+ export const DASHBOARDORGANISATION_UPDATE = "app.dashboardorganisation.update";
20
+ export const DASHBOARDORGANISATION_REMOVE = "app.dashboardorganisation.remove";
21
+ export const DASHBOARDORGANISATION_LOCK = "app.dashboardorganisation.lock";
22
+
23
+ export const DASHBOARDORGANISATIONTYPE_READ = "app.dashboardorganisationtype.read";
24
+ export const DASHBOARDORGANISATIONTYPE_CREATE = "app.dashboardorganisationtype.create";
25
+ export const DASHBOARDORGANISATIONTYPE_UPDATE = "app.dashboardorganisationtype.update";
26
+ export const DASHBOARDORGANISATIONTYPE_REMOVE = "app.dashboardorganisationtype.remove";
27
+ export const DASHBOARDORGANISATIONTYPE_SHARE = "app.dashboardorganisationtype.share";
28
+ export const DASHBOARDORGANISATIONTYPE_LOCK = "app.dashboardorganisationtype.lock";
29
+
30
+ export const DATAMODEL_READ = "app.datamodel.read";
31
+
32
+ export const DEVICEORGANISATION_READ = "app.deviceorganisation.read";
33
+ export const DEVICEORGANISATION_CREATE = "app.deviceorganisation.create";
34
+ export const DEVICEORGANISATION_UPDATE = "app.deviceorganisation.update";
35
+ export const DEVICEORGANISATION_REMOVE = "app.deviceorganisation.remove";
36
+
37
+ export const GROUP_READ = "app.group.read";
38
+ export const GROUP_CREATE = "app.group.create";
39
+ export const GROUP_UPDATE = "app.group.update";
40
+ export const GROUP_REMOVE = "app.group.remove";
41
+
42
+ export const LOCATION_READ = "app.location.read";
43
+ export const LOCATION_CREATE = "app.location.create";
44
+ export const LOCATION_UPDATE = "app.location.update";
45
+ export const LOCATION_REMOVE = "app.location.remove";
46
+
47
+ export const ORGANISATION_UPDATE = "app.organisation.update";
48
+ export const ORGANISATION_DASHBOARD = "app.organisation.dashboard";
49
+
50
+ export const ORGANISATIONTYPE_DASHBOARD = "app.organisationtype.dashboard";
51
+
52
+ export const ROLEORGANISATION_READ = "app.roleorganisation.read";
53
+ export const ROLEORGANISATION_CREATE = "app.roleorganisation.create";
54
+ export const ROLEORGANISATION_UPDATE = "app.roleorganisation.update";
55
+ export const ROLEORGANISATION_REMOVE = "app.roleorganisation.remove";
56
+
57
+ export const ROLEORGANISATIONTYPE_READ = "app.roleorganisationtype.read";
58
+
59
+ export const SCENARIO_MANAGE = "app.scenario.manage";
60
+
61
+ export const SCENARIOORGANISATION_READ = "app.scenarioorganisation.read";
62
+ export const SCENARIOORGANISATION_CREATE = "app.scenarioorganisation.create";
63
+ export const SCENARIOORGANISATION_UPDATE = "app.scenarioorganisation.update";
64
+ export const SCENARIOORGANISATION_REMOVE = "app.scenarioorganisation.remove";
65
+
66
+ export const SCENARIOORGANISATIONTYPE_READ = "app.scenarioorganisationtype.read";
67
+ export const SCENARIOORGANISATIONTYPE_CREATE = "app.scenarioorganisationtype.create";
68
+ export const SCENARIOORGANISATIONTYPE_UPDATE = "app.scenarioorganisationtype.update";
69
+ export const SCENARIOORGANISATIONTYPE_REMOVE = "app.scenarioorganisationtype.remove";
70
+ export const SCENARIOORGANISATIONTYPE_SHARE = "app.scenarioorganisationtype.share";
71
+
72
+ export const SERVICEACCOUNTORGANISATION_READ = "app.serviceaccountorganisation.read";
73
+ export const SERVICEACCOUNTORGANISATION_CREATE = "app.serviceaccountorganisation.create";
74
+ export const SERVICEACCOUNTORGANISATION_UPDATE = "app.serviceaccountorganisation.update";
75
+ export const SERVICEACCOUNTORGANISATION_REMOVE = "app.serviceaccountorganisation.remove";
76
+
77
+ export const USERORGANISATION_READ = "app.userorganisation.read";
78
+ export const USERORGANISATION_CREATE = "app.userorganisation.create";
79
+ export const USERORGANISATION_UPDATE = "app.userorganisation.update";
80
+ export const USERORGANISATION_REMOVE = "app.userorganisation.remove";
package/utils/roles.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { useTranslations as useTranslationsProvider } from "@dative-gpi/bones-ui/composables";
2
2
  import { type ColorBase, ColorEnum } from "@dative-gpi/foundation-shared-components/models";
3
- import { RoleType } from "@dative-gpi/foundation-core-domain/models"
3
+ import { RoleType } from "@dative-gpi/foundation-shared-domain/enums";
4
4
 
5
5
  const { $tr } = useTranslationsProvider();
6
6
 
@@ -0,0 +1,41 @@
1
+
2
+ export const DASHBOARDS_EXPLORER_MAIN = "ui.tables.folder-mock.explorer-main";
3
+ export const DASHBOARDS_EXPLORER_SHARED = "ui.tables.dashboard-mock.explorer-shared";
4
+ export const DEVICES_EXPLORER_MAIN = "ui.tables.group-mock.explorer-main";
5
+
6
+ export const DEVICES_LIST_MAIN = "ui.tables.device.main";
7
+ export const DEVICES_MAINTENANCE = "ui.tables.device.maintenance";
8
+ export const LOCATIONS_LIST_MAIN = "ui.tables.location.main";
9
+
10
+ export const CHARTS_LIST_MAIN = "ui.tables.chart.main";
11
+ export const CHARTS_LIST_SHARED = "ui.tables.chart.shared";
12
+
13
+ export const SCENARIOS_LIST_MAIN = "ui.tables.scenario.main";
14
+ export const SCENARIOS_LIST_SHARED = "ui.tables.scenario.shared";
15
+ export const CONNECTIVITY_SCENARIOS_LIST_MAIN = "ui.tables.connectivity-scenario.main";
16
+
17
+ export const ALERTS_LIST_MAIN = "ui.tables.alert.main";
18
+ export const CONNECTIVITY_ALERTS_LIST_MAIN = "ui.tables.connectivity-alert.main";
19
+
20
+ export const DEVICES_SELECT = "ui.tables.device.select";
21
+ export const GROUPS_SELECT = "ui.tables.group.select";
22
+ export const LOCATIONS_SELECT = "ui.tables.location.select";
23
+ export const MODELS_SELECT = "ui.tables.model.select";
24
+ export const DASHBOARDS_SELECT = "ui.tables.dashboard-mock.select";
25
+
26
+ export const WIDGET_DASHBOARDS_EXPLORER = "ui.tables.folder-mock.widget";
27
+
28
+ export const LOCATION_DEVICES = "ui.tables.device.location-devices";
29
+ export const DEVICE_ALERTS = "ui.tables.alert.device-alerts";
30
+ export const DEVICE_CONNECTIVITY_ALERTS = "ui.tables.connectivity-alerts.device-connectivity-alerts";
31
+ export const SCENARIO_ALERTS = "ui.tables.alert.scenario-alerts";
32
+ export const SCENARIO_DEVICE_ORGANISATIONS = "ui.tables.scenario-device.scenario-device-organisations";
33
+ export const ALERT_COMMENTS = "ui.tables.comments.alert-comments";
34
+
35
+ export const ORGANISATION_USERS = "ui.tables.user.organisation-users";
36
+ export const ORGANISATION_ROLES = "ui.tables.role.organisation-roles";
37
+ export const ORGANISATION_SERVICE_ACCOUNTS = "ui.tables.service-account.organisation-service-accounts";
38
+
39
+ export const USER_AUTHENTICATION_TOKENS = "ui.tables.auth-token.user-auth-tokens";
40
+
41
+ export const CUSTOM_PROPERTIES_VALUES = "ui.tables.custom-property-value.history";
package/utils/users.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { useTranslations as useTranslationsProvider } from "@dative-gpi/bones-ui/composables";
2
- import { UserType, UserValidityState } from "@dative-gpi/foundation-core-domain/models"
2
+ import { UserType, UserValidityState } from "@dative-gpi/foundation-shared-domain/enums";
3
3
 
4
4
  const { $tr } = useTranslationsProvider();
5
5