@dative-gpi/foundation-core-services 0.0.121 → 0.0.122

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.
@@ -2,6 +2,7 @@ export * from "./useActions";
2
2
  export * from "./useAlerts";
3
3
  export * from "./useArticles";
4
4
  export * from "./useAuthTokens";
5
+ export * from "./useChartCategories";
5
6
  export * from "./useChartOrganisationTypes";
6
7
  export * from "./useChartOrganisations";
7
8
  export * from "./useCharts";
@@ -0,0 +1,13 @@
1
+ import { CreateChartCategoryDTO, ChartCategoryDetails, ChartCategoryDetailsDTO, ChartCategoryFilters, ChartCategoryInfos, ChartCategoryInfosDTO, UpdateChartCategoryDTO } from "@dative-gpi/foundation-core-domain/models";
2
+ import { ComposableFactory, ServiceFactory } from "@dative-gpi/bones-ui/core";
3
+
4
+ import { CHART_CATEGORIES_URL, CHART_CATEGORY_URL } from "../../config/urls";
5
+
6
+ const ChartCategoryServiceFactory = new ServiceFactory<ChartCategoryDetailsDTO, ChartCategoryDetails>("chartCategory", ChartCategoryDetails)
7
+ .createComplete<ChartCategoryInfos, ChartCategoryInfosDTO, CreateChartCategoryDTO, UpdateChartCategoryDTO, ChartCategoryFilters>(CHART_CATEGORIES_URL, CHART_CATEGORY_URL, ChartCategoryInfos);
8
+
9
+ export const useChartCategory = ComposableFactory.get(ChartCategoryServiceFactory);
10
+ export const useChartCategories = ComposableFactory.getMany(ChartCategoryServiceFactory);
11
+ export const useCreateChartCategory = ComposableFactory.create(ChartCategoryServiceFactory);
12
+ export const useUpdateChartCategory = ComposableFactory.update(ChartCategoryServiceFactory);
13
+ export const useRemoveChartCategory = ComposableFactory.remove(ChartCategoryServiceFactory);
@@ -0,0 +1,4 @@
1
+ import { CORE_URL } from "./base";
2
+
3
+ export const CHART_CATEGORIES_URL = () => `${CORE_URL()}/chart-categories`;
4
+ export const CHART_CATEGORY_URL = (chartCategoryId: string) => `${CHART_CATEGORIES_URL()}/${encodeURIComponent(chartCategoryId)}`;
@@ -3,6 +3,7 @@ export * from "./alerts";
3
3
  export * from "./articles";
4
4
  export * from "./authTokens";
5
5
  export * from "./charts";
6
+ export * from "./chartCategories";
6
7
  export * from "./chartOrganisations";
7
8
  export * from "./chartOrganisationTypes";
8
9
  export * from "./comments";
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@dative-gpi/foundation-core-services",
3
3
  "sideEffects": false,
4
- "version": "0.0.121",
4
+ "version": "0.0.122",
5
5
  "description": "",
6
6
  "publishConfig": {
7
7
  "access": "public"
@@ -11,10 +11,10 @@
11
11
  "license": "ISC",
12
12
  "dependencies": {
13
13
  "@dative-gpi/bones-ui": "^0.0.74",
14
- "@dative-gpi/foundation-core-domain": "0.0.121",
14
+ "@dative-gpi/foundation-core-domain": "0.0.122",
15
15
  "@microsoft/signalr": "^8.0.0",
16
16
  "vue": "^3.4.23",
17
17
  "vue-router": "^4.2.5"
18
18
  },
19
- "gitHead": "305cafbeb6046ce65f2b4917b319f4d36ebbcf00"
19
+ "gitHead": "03ed8a5ad950d7e478edcfc0af73cc9bb2cf8b26"
20
20
  }