@lucaapp/service-utils 2.0.2 → 2.0.4
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.
- package/dist/lib/kafka/events/operatorDevice.d.ts +2 -1
- package/dist/lib/kafka/events/operatorDeviceSyncRequest.d.ts +3 -0
- package/dist/lib/kafka/events/operatorDeviceSyncRequest.js +2 -0
- package/dist/lib/kafka/events.d.ts +4 -0
- package/dist/lib/kafka/events.js +2 -0
- package/dist/types/operatorDevice.d.ts +8 -0
- package/dist/types/operatorDevice.js +12 -0
- package/package.json +1 -1
|
@@ -1,8 +1,9 @@
|
|
|
1
|
+
import type { OperatorDeviceRole } from '../../../types/operatorDevice';
|
|
1
2
|
export type OperatorDevice = {
|
|
2
3
|
uuid: string;
|
|
3
4
|
name: string;
|
|
4
5
|
os: string;
|
|
5
|
-
role:
|
|
6
|
+
role: OperatorDeviceRole;
|
|
6
7
|
operatorId: string;
|
|
7
8
|
locationId: string | null;
|
|
8
9
|
createdAt: Date;
|
|
@@ -13,11 +13,13 @@ import { ConsumerPushNotification } from './events/consumerPushNotification';
|
|
|
13
13
|
import { OperatorLocationGroup } from '../../types/operatorLocationGroup';
|
|
14
14
|
import { PaymentSyncError } from './events/paymentSyncError';
|
|
15
15
|
import { OperatorDevice } from './events/operatorDevice';
|
|
16
|
+
import { OperatorDeviceSyncRequest } from './events/operatorDeviceSyncRequest';
|
|
16
17
|
declare enum KafkaTopic {
|
|
17
18
|
PAYMENTS = "payments",
|
|
18
19
|
CONSUMERS = "consumers",
|
|
19
20
|
OPERATORS = "operators",
|
|
20
21
|
OPERATOR_DEVICES = "operator_devices",
|
|
22
|
+
OPERATOR_DEVICE_SYNC_REQUEST = "operator_device_sync_request",
|
|
21
23
|
LOCATIONS = "locations",
|
|
22
24
|
LOCATION_GROUPS = "location_groups",
|
|
23
25
|
OPERATOR_LOCATION_GROUPS = "operator_location_groups",
|
|
@@ -36,6 +38,7 @@ type MessageFormats = {
|
|
|
36
38
|
[KafkaTopic.CONSUMERS]: Consumer;
|
|
37
39
|
[KafkaTopic.OPERATORS]: Operator;
|
|
38
40
|
[KafkaTopic.OPERATOR_DEVICES]: OperatorDevice;
|
|
41
|
+
[KafkaTopic.OPERATOR_DEVICE_SYNC_REQUEST]: OperatorDeviceSyncRequest;
|
|
39
42
|
[KafkaTopic.LOCATIONS]: Location;
|
|
40
43
|
[KafkaTopic.LOCATION_GROUPS]: LocationGroup;
|
|
41
44
|
[KafkaTopic.OPERATOR_LOCATION_GROUPS]: OperatorLocationGroup;
|
|
@@ -54,6 +57,7 @@ declare const MessageIssuer: {
|
|
|
54
57
|
consumers: Service;
|
|
55
58
|
operators: Service;
|
|
56
59
|
operator_devices: Service;
|
|
60
|
+
operator_device_sync_request: Service;
|
|
57
61
|
locations: Service;
|
|
58
62
|
location_groups: Service;
|
|
59
63
|
operator_location_groups: Service;
|
package/dist/lib/kafka/events.js
CHANGED
|
@@ -8,6 +8,7 @@ var KafkaTopic;
|
|
|
8
8
|
KafkaTopic["CONSUMERS"] = "consumers";
|
|
9
9
|
KafkaTopic["OPERATORS"] = "operators";
|
|
10
10
|
KafkaTopic["OPERATOR_DEVICES"] = "operator_devices";
|
|
11
|
+
KafkaTopic["OPERATOR_DEVICE_SYNC_REQUEST"] = "operator_device_sync_request";
|
|
11
12
|
KafkaTopic["LOCATIONS"] = "locations";
|
|
12
13
|
KafkaTopic["LOCATION_GROUPS"] = "location_groups";
|
|
13
14
|
KafkaTopic["OPERATOR_LOCATION_GROUPS"] = "operator_location_groups";
|
|
@@ -26,6 +27,7 @@ const MessageIssuer = {
|
|
|
26
27
|
[KafkaTopic.CONSUMERS]: serviceIdentity_1.Service.BACKEND,
|
|
27
28
|
[KafkaTopic.OPERATORS]: serviceIdentity_1.Service.BACKEND,
|
|
28
29
|
[KafkaTopic.OPERATOR_DEVICES]: serviceIdentity_1.Service.BACKEND,
|
|
30
|
+
[KafkaTopic.OPERATOR_DEVICE_SYNC_REQUEST]: serviceIdentity_1.Service.BACKEND_PAY,
|
|
29
31
|
[KafkaTopic.LOCATIONS]: serviceIdentity_1.Service.BACKEND,
|
|
30
32
|
[KafkaTopic.LOCATION_GROUPS]: serviceIdentity_1.Service.BACKEND,
|
|
31
33
|
[KafkaTopic.OPERATOR_LOCATION_GROUPS]: serviceIdentity_1.Service.BACKEND,
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.OperatorDeviceRole = void 0;
|
|
4
|
+
var OperatorDeviceRole;
|
|
5
|
+
(function (OperatorDeviceRole) {
|
|
6
|
+
OperatorDeviceRole["SCANNER"] = "scanner";
|
|
7
|
+
OperatorDeviceRole["EMPLOYEE"] = "employee";
|
|
8
|
+
OperatorDeviceRole["MANAGER"] = "manager";
|
|
9
|
+
OperatorDeviceRole["LINK"] = "link";
|
|
10
|
+
OperatorDeviceRole["TERMINAL"] = "terminal";
|
|
11
|
+
OperatorDeviceRole["EXTERNAL"] = "external";
|
|
12
|
+
})(OperatorDeviceRole || (exports.OperatorDeviceRole = OperatorDeviceRole = {}));
|