@dative-gpi/foundation-shared-services 0.0.198 → 0.0.199
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 "./useAuthTokens";
|
|
|
2
2
|
export * from "./useImages";
|
|
3
3
|
export * from "./useLanguages";
|
|
4
4
|
export * from "./useOrganisations";
|
|
5
|
+
export * from "./useTerminals";
|
|
5
6
|
export * from "./useTimeZones";
|
|
6
7
|
export * from "./useTranslations";
|
|
7
8
|
export * from "./useUsers";
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { type CreateTerminalDTO, TerminalDetails, type TerminalDetailsDTO, type TerminalFilters, TerminalInfos, type TerminalInfosDTO, type UpdateTerminalDTO } from "@dative-gpi/foundation-shared-domain/models";
|
|
2
|
+
import { ComposableFactory, ServiceFactory } from "@dative-gpi/bones-ui/core";
|
|
3
|
+
|
|
4
|
+
import { TERMINALS_URL, TERMINAL_URL } from "../../config/urls";
|
|
5
|
+
|
|
6
|
+
const TerminalServiceFactory = new ServiceFactory<TerminalDetailsDTO, TerminalDetails>("terminal", TerminalDetails).create(factory => factory.build(
|
|
7
|
+
factory.addGetMany<TerminalInfosDTO, TerminalInfos, TerminalFilters>(TERMINALS_URL, TerminalInfos),
|
|
8
|
+
factory.addCreate<CreateTerminalDTO>(TERMINALS_URL),
|
|
9
|
+
factory.addUpdate<UpdateTerminalDTO>(TERMINAL_URL),
|
|
10
|
+
factory.addRemove(TERMINAL_URL),
|
|
11
|
+
factory.addNotify()
|
|
12
|
+
));
|
|
13
|
+
|
|
14
|
+
export const useTerminals = ComposableFactory.getMany(TerminalServiceFactory);
|
|
15
|
+
export const useCreateTerminal = ComposableFactory.create(TerminalServiceFactory);
|
|
16
|
+
export const useUpdateTerminal = ComposableFactory.update(TerminalServiceFactory);
|
|
17
|
+
export const useRemoveTerminal = ComposableFactory.remove(TerminalServiceFactory);
|
package/config/urls/index.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dative-gpi/foundation-shared-services",
|
|
3
3
|
"sideEffects": false,
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.199",
|
|
5
5
|
"description": "",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
"author": "",
|
|
11
11
|
"license": "ISC",
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@dative-gpi/foundation-shared-domain": "0.0.
|
|
13
|
+
"@dative-gpi/foundation-shared-domain": "0.0.199"
|
|
14
14
|
},
|
|
15
15
|
"peerDependencies": {
|
|
16
16
|
"@dative-gpi/bones-ui": "^0.0.75",
|
|
@@ -18,5 +18,5 @@
|
|
|
18
18
|
"vue": "^3.4.29",
|
|
19
19
|
"vue-router": "^4.3.0"
|
|
20
20
|
},
|
|
21
|
-
"gitHead": "
|
|
21
|
+
"gitHead": "42f7d9f60cfe208a7e78b9b62e266cf7dadca9b8"
|
|
22
22
|
}
|