dt-common-device 9.1.10 → 9.2.0
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.
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const excludeEvents: string[];
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.excludeEvents = void 0;
|
|
4
|
+
exports.excludeEvents = [
|
|
5
|
+
"device.event.received",
|
|
6
|
+
"device.event.processed",
|
|
7
|
+
"rpa.accessibility.enabled",
|
|
8
|
+
"alert.create.skipped",
|
|
9
|
+
"heartbeat.lock.local_codes",
|
|
10
|
+
"device.state.changed",
|
|
11
|
+
"lock.code.set.success",
|
|
12
|
+
"lock.unlocked_non_business_hour.alert",
|
|
13
|
+
"lock.left_unlocked.alert",
|
|
14
|
+
"network.connection.on",
|
|
15
|
+
"rpa.accessibility.disabled",
|
|
16
|
+
"heartbeat.device.further_checks_skipped",
|
|
17
|
+
"lock.code.usage_count",
|
|
18
|
+
"device.webhook.received",
|
|
19
|
+
"$screen",
|
|
20
|
+
"lock.code.delete.pending",
|
|
21
|
+
"heartbeat.lock.missing_codes",
|
|
22
|
+
"schedule.create.success",
|
|
23
|
+
"playlist.play.start",
|
|
24
|
+
"heartbeat.lock.unset_codes",
|
|
25
|
+
"setup.success",
|
|
26
|
+
"playlist.play.end",
|
|
27
|
+
"alert.create.success",
|
|
28
|
+
"lock.locked_unlocked_frequently.alert",
|
|
29
|
+
"issue.create.skipped",
|
|
30
|
+
"heartbeat.lock.additional_codes",
|
|
31
|
+
"reservation.info.receive",
|
|
32
|
+
"app.accessibility.enabled",
|
|
33
|
+
"lock.provision.auto.generate.step_update",
|
|
34
|
+
"heartbeat.lock.marked_to_delete_codes",
|
|
35
|
+
"guest_codes.generate.attempt",
|
|
36
|
+
"guest_codes.generate.success",
|
|
37
|
+
"collection.add.zone.success",
|
|
38
|
+
"device.event.unprocessed",
|
|
39
|
+
"heartbeat.lock.schedule_codes",
|
|
40
|
+
"account.device.new",
|
|
41
|
+
"pms.connect.success",
|
|
42
|
+
"device.update.success",
|
|
43
|
+
"lock.provision.auto.generate.start",
|
|
44
|
+
"issue.resolve.success",
|
|
45
|
+
"lock.provision.auto.generate.complete",
|
|
46
|
+
];
|
package/dist/audit/PushAudit.js
CHANGED
|
@@ -7,10 +7,16 @@ exports.pushAudit = pushAudit;
|
|
|
7
7
|
const dt_audit_library_1 = require("dt-audit-library");
|
|
8
8
|
const AuditUtils_1 = require("./AuditUtils");
|
|
9
9
|
const typedi_1 = __importDefault(require("typedi"));
|
|
10
|
+
const ExcludeAudits_1 = require("./ExcludeAudits");
|
|
10
11
|
async function pushAudit(data) {
|
|
11
12
|
const audit = await typedi_1.default.get(AuditUtils_1.AuditUtils).buildAuditProperties(data.auditData);
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
if (ExcludeAudits_1.excludeEvents.includes(data.auditType)) {
|
|
14
|
+
console.log("Audit event excluded:", data.auditType);
|
|
15
|
+
}
|
|
16
|
+
else {
|
|
17
|
+
await (0, dt_audit_library_1.publishAudit)({
|
|
18
|
+
eventType: data.auditType,
|
|
19
|
+
properties: { ...audit, timestamp: new Date().toISOString() },
|
|
20
|
+
});
|
|
21
|
+
}
|
|
16
22
|
}
|
|
@@ -72,7 +72,8 @@ export declare enum IssueType {
|
|
|
72
72
|
LOCK_JAMMED = "LOCK_JAMMED",
|
|
73
73
|
DEVICE_MALFUNCTION = "DEVICE_MALFUNCTION",
|
|
74
74
|
NO_GUEST_CODES = "NO_GUEST_CODES",
|
|
75
|
-
JUST_ENOUGH_GUEST_CODES = "JUST_ENOUGH_GUEST_CODES"
|
|
75
|
+
JUST_ENOUGH_GUEST_CODES = "JUST_ENOUGH_GUEST_CODES",
|
|
76
|
+
PMS_CODE_NOT_DELIVERED = "PMS_CODE_NOT_DELIVERED"
|
|
76
77
|
}
|
|
77
78
|
export interface IssueDocument {
|
|
78
79
|
id: string;
|
|
@@ -78,4 +78,5 @@ var IssueType;
|
|
|
78
78
|
IssueType["DEVICE_MALFUNCTION"] = "DEVICE_MALFUNCTION";
|
|
79
79
|
IssueType["NO_GUEST_CODES"] = "NO_GUEST_CODES";
|
|
80
80
|
IssueType["JUST_ENOUGH_GUEST_CODES"] = "JUST_ENOUGH_GUEST_CODES";
|
|
81
|
+
IssueType["PMS_CODE_NOT_DELIVERED"] = "PMS_CODE_NOT_DELIVERED";
|
|
81
82
|
})(IssueType || (exports.IssueType = IssueType = {}));
|
|
@@ -155,7 +155,7 @@ class QueueUtils {
|
|
|
155
155
|
}
|
|
156
156
|
};
|
|
157
157
|
checkJob();
|
|
158
|
-
const waitTime = queueKey.includes("cloudbeds") ? 180000 : 60000;
|
|
158
|
+
const waitTime = queueKey.toLowerCase().includes("cloudbeds") ? 180000 : 60000;
|
|
159
159
|
// Backup timeout
|
|
160
160
|
setTimeout(() => {
|
|
161
161
|
clearTimeout(timeoutId);
|