grm-shared-library 1.1.143 → 1.1.145
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/cjs/index.js +1 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/modules/socket/index.js +1 -2
- package/dist/cjs/modules/socket/index.js.map +1 -1
- package/dist/cjs/modules/web-notification/dtos/create-web-notification.dto.js +119 -0
- package/dist/cjs/modules/web-notification/dtos/create-web-notification.dto.js.map +1 -0
- package/dist/cjs/modules/web-notification/dtos/update-web-notification.dto.js +9 -0
- package/dist/cjs/modules/web-notification/dtos/update-web-notification.dto.js.map +1 -0
- package/dist/cjs/modules/web-notification/enums/notification-priority.enum.js.map +1 -0
- package/dist/cjs/modules/web-notification/enums/notification-provider.enum.js +11 -0
- package/dist/cjs/modules/web-notification/enums/notification-provider.enum.js.map +1 -0
- package/dist/cjs/modules/web-notification/enums/notification-type.enum.js +15 -0
- package/dist/cjs/modules/web-notification/enums/notification-type.enum.js.map +1 -0
- package/dist/cjs/modules/web-notification/enums/web-notification-data-type.enum.js +14 -0
- package/dist/cjs/modules/web-notification/enums/web-notification-data-type.enum.js.map +1 -0
- package/dist/cjs/modules/{notification → web-notification}/index.js +9 -1
- package/dist/cjs/modules/web-notification/index.js.map +1 -0
- package/dist/cjs/modules/{notification/interfaces/notification.js → web-notification/interfaces/web-notification.js} +1 -1
- package/dist/cjs/modules/web-notification/interfaces/web-notification.js.map +1 -0
- package/dist/esm/index.js +1 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/modules/socket/index.js +1 -2
- package/dist/esm/modules/socket/index.js.map +1 -1
- package/dist/esm/modules/web-notification/dtos/create-web-notification.dto.js +115 -0
- package/dist/esm/modules/web-notification/dtos/create-web-notification.dto.js.map +1 -0
- package/dist/esm/modules/web-notification/dtos/update-web-notification.dto.js +5 -0
- package/dist/esm/modules/web-notification/dtos/update-web-notification.dto.js.map +1 -0
- package/dist/esm/modules/web-notification/enums/notification-priority.enum.js.map +1 -0
- package/dist/esm/modules/web-notification/enums/notification-provider.enum.js +8 -0
- package/dist/esm/modules/web-notification/enums/notification-provider.enum.js.map +1 -0
- package/dist/esm/modules/web-notification/enums/notification-type.enum.js +12 -0
- package/dist/esm/modules/web-notification/enums/notification-type.enum.js.map +1 -0
- package/dist/esm/modules/web-notification/enums/web-notification-data-type.enum.js +11 -0
- package/dist/esm/modules/web-notification/enums/web-notification-data-type.enum.js.map +1 -0
- package/dist/esm/modules/web-notification/index.js +11 -0
- package/dist/esm/modules/web-notification/index.js.map +1 -0
- package/dist/esm/modules/web-notification/interfaces/web-notification.js +2 -0
- package/dist/esm/modules/web-notification/interfaces/web-notification.js.map +1 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/modules/socket/index.d.ts +1 -2
- package/dist/types/modules/web-notification/dtos/create-web-notification.dto.d.ts +27 -0
- package/dist/types/modules/web-notification/dtos/update-web-notification.dto.d.ts +5 -0
- package/dist/types/modules/web-notification/enums/notification-provider.enum.d.ts +6 -0
- package/dist/types/modules/web-notification/enums/notification-type.enum.d.ts +10 -0
- package/dist/types/modules/web-notification/enums/web-notification-data-type.enum.d.ts +9 -0
- package/dist/types/modules/web-notification/index.d.ts +7 -0
- package/dist/types/modules/web-notification/interfaces/web-notification.d.ts +30 -0
- package/package.json +1 -1
- package/dist/cjs/modules/notification/enums/notification-priority.enum.js.map +0 -1
- package/dist/cjs/modules/notification/enums/notification-type.enum.js +0 -14
- package/dist/cjs/modules/notification/enums/notification-type.enum.js.map +0 -1
- package/dist/cjs/modules/notification/index.js.map +0 -1
- package/dist/cjs/modules/notification/interfaces/notification.js.map +0 -1
- package/dist/cjs/modules/socket/enums/notification-priority.enum.js +0 -11
- package/dist/cjs/modules/socket/enums/notification-priority.enum.js.map +0 -1
- package/dist/cjs/modules/socket/interfaces/notification.js +0 -3
- package/dist/cjs/modules/socket/interfaces/notification.js.map +0 -1
- package/dist/esm/modules/notification/enums/notification-priority.enum.js.map +0 -1
- package/dist/esm/modules/notification/enums/notification-type.enum.js +0 -11
- package/dist/esm/modules/notification/enums/notification-type.enum.js.map +0 -1
- package/dist/esm/modules/notification/index.js +0 -3
- package/dist/esm/modules/notification/index.js.map +0 -1
- package/dist/esm/modules/notification/interfaces/notification.js +0 -2
- package/dist/esm/modules/notification/interfaces/notification.js.map +0 -1
- package/dist/esm/modules/socket/enums/notification-priority.enum.js +0 -8
- package/dist/esm/modules/socket/enums/notification-priority.enum.js.map +0 -1
- package/dist/esm/modules/socket/interfaces/notification.js +0 -2
- package/dist/esm/modules/socket/interfaces/notification.js.map +0 -1
- package/dist/types/modules/notification/enums/notification-type.enum.d.ts +0 -9
- package/dist/types/modules/notification/index.d.ts +0 -2
- package/dist/types/modules/notification/interfaces/notification.d.ts +0 -16
- package/dist/types/modules/socket/enums/notification-priority.enum.d.ts +0 -6
- package/dist/types/modules/socket/interfaces/notification.d.ts +0 -16
- /package/dist/cjs/modules/{notification → web-notification}/enums/notification-priority.enum.js +0 -0
- /package/dist/esm/modules/{notification → web-notification}/enums/notification-priority.enum.js +0 -0
- /package/dist/types/modules/{notification → web-notification}/enums/notification-priority.enum.d.ts +0 -0
package/dist/cjs/index.js
CHANGED
|
@@ -30,6 +30,7 @@ __exportStar(require("./modules/dms/index"), exports);
|
|
|
30
30
|
__exportStar(require("./modules/sms/index"), exports);
|
|
31
31
|
__exportStar(require("./modules/gis/index"), exports);
|
|
32
32
|
__exportStar(require("./modules/socket/index"), exports);
|
|
33
|
+
__exportStar(require("./modules/web-notification/index"), exports);
|
|
33
34
|
// Interfaces
|
|
34
35
|
__exportStar(require("./interfaces/server-message"), exports);
|
|
35
36
|
__exportStar(require("./interfaces/i-request-with-user"), exports);
|
package/dist/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,UAAU;AACV,uDAAqC;AACrC,+DAA6C;AAC7C,yDAAuC;AACvC,6DAA2C;AAC3C,uDAAqC;AACrC,uDAAqC;AACrC,iEAA+C;AAC/C,wDAAsC;AACtC,gEAA8C;AAC9C,2DAAyC;AACzC,2DAAyC;AACzC,sDAAoC;AACpC,sDAAoC;AACpC,sDAAoC;AACpC,yDAAuC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,UAAU;AACV,uDAAqC;AACrC,+DAA6C;AAC7C,yDAAuC;AACvC,6DAA2C;AAC3C,uDAAqC;AACrC,uDAAqC;AACrC,iEAA+C;AAC/C,wDAAsC;AACtC,gEAA8C;AAC9C,2DAAyC;AACzC,2DAAyC;AACzC,sDAAoC;AACpC,sDAAoC;AACpC,sDAAoC;AACpC,yDAAuC;AACvC,mEAAiD;AAEjD,aAAa;AACb,8DAA4C;AAC5C,mEAAiD;AACjD,8DAA4C;AAC5C,2DAAyC;AACzC,0DAAwC;AAExC,YAAY;AACZ,2DAAyC;AAEzC,QAAQ;AACR,gDAA8B;AAE9B,YAAY;AACZ,+DAA6C;AAC7C,wFAAsE;AAEtE,aAAa;AACb,qDAAmC"}
|
|
@@ -19,7 +19,6 @@ __exportStar(require("./interfaces/event-response"), exports);
|
|
|
19
19
|
__exportStar(require("./interfaces/online-user"), exports);
|
|
20
20
|
__exportStar(require("./interfaces/event-envelope"), exports);
|
|
21
21
|
__exportStar(require("./interfaces/client-safe-incident"), exports);
|
|
22
|
-
__exportStar(require("./interfaces/notification"), exports);
|
|
23
22
|
__exportStar(require("./enums/room-type.enum"), exports);
|
|
24
|
-
__exportStar(require("
|
|
23
|
+
__exportStar(require("../web-notification/enums/web-notification-data-type.enum"), exports);
|
|
25
24
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/modules/socket/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2DAAyC;AACzC,8DAA4C;AAC5C,2DAAyC;AACzC,8DAA4C;AAC5C,oEAAkD;AAClD,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/modules/socket/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,2DAAyC;AACzC,8DAA4C;AAC5C,2DAAyC;AACzC,8DAA4C;AAC5C,oEAAkD;AAClD,yDAAuC;AACvC,4FAA0E"}
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.CreateWebNotificationDto = void 0;
|
|
13
|
+
const class_validator_1 = require("class-validator");
|
|
14
|
+
const web_notification_data_type_enum_1 = require("../enums/web-notification-data-type.enum");
|
|
15
|
+
const notification_priority_enum_1 = require("../enums/notification-priority.enum");
|
|
16
|
+
const notification_type_enum_1 = require("../enums/notification-type.enum");
|
|
17
|
+
const notification_provider_enum_1 = require("../enums/notification-provider.enum");
|
|
18
|
+
class CreateWebNotificationDto {
|
|
19
|
+
}
|
|
20
|
+
exports.CreateWebNotificationDto = CreateWebNotificationDto;
|
|
21
|
+
__decorate([
|
|
22
|
+
(0, class_validator_1.IsString)(),
|
|
23
|
+
(0, class_validator_1.IsOptional)(),
|
|
24
|
+
__metadata("design:type", String)
|
|
25
|
+
], CreateWebNotificationDto.prototype, "deviceToken", void 0);
|
|
26
|
+
__decorate([
|
|
27
|
+
(0, class_validator_1.IsEnum)(notification_provider_enum_1.NotificationProvider),
|
|
28
|
+
(0, class_validator_1.IsOptional)(),
|
|
29
|
+
__metadata("design:type", String)
|
|
30
|
+
], CreateWebNotificationDto.prototype, "provider", void 0);
|
|
31
|
+
__decorate([
|
|
32
|
+
(0, class_validator_1.IsNumber)(),
|
|
33
|
+
(0, class_validator_1.IsOptional)(),
|
|
34
|
+
__metadata("design:type", Number)
|
|
35
|
+
], CreateWebNotificationDto.prototype, "dataId", void 0);
|
|
36
|
+
__decorate([
|
|
37
|
+
(0, class_validator_1.IsOptional)(),
|
|
38
|
+
__metadata("design:type", Object)
|
|
39
|
+
], CreateWebNotificationDto.prototype, "data", void 0);
|
|
40
|
+
__decorate([
|
|
41
|
+
(0, class_validator_1.IsEnum)(web_notification_data_type_enum_1.WebNotificationDataType),
|
|
42
|
+
(0, class_validator_1.IsOptional)(),
|
|
43
|
+
__metadata("design:type", String)
|
|
44
|
+
], CreateWebNotificationDto.prototype, "dataType", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
(0, class_validator_1.IsEnum)(notification_type_enum_1.NotificationType),
|
|
47
|
+
(0, class_validator_1.IsOptional)(),
|
|
48
|
+
__metadata("design:type", String)
|
|
49
|
+
], CreateWebNotificationDto.prototype, "type", void 0);
|
|
50
|
+
__decorate([
|
|
51
|
+
(0, class_validator_1.IsUrl)(),
|
|
52
|
+
(0, class_validator_1.IsOptional)(),
|
|
53
|
+
__metadata("design:type", String)
|
|
54
|
+
], CreateWebNotificationDto.prototype, "imageUrl", void 0);
|
|
55
|
+
__decorate([
|
|
56
|
+
(0, class_validator_1.IsString)(),
|
|
57
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
58
|
+
__metadata("design:type", String)
|
|
59
|
+
], CreateWebNotificationDto.prototype, "title", void 0);
|
|
60
|
+
__decorate([
|
|
61
|
+
(0, class_validator_1.IsString)(),
|
|
62
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
63
|
+
__metadata("design:type", String)
|
|
64
|
+
], CreateWebNotificationDto.prototype, "body", void 0);
|
|
65
|
+
__decorate([
|
|
66
|
+
(0, class_validator_1.IsDateString)(),
|
|
67
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
68
|
+
__metadata("design:type", String)
|
|
69
|
+
], CreateWebNotificationDto.prototype, "timestamp", void 0);
|
|
70
|
+
__decorate([
|
|
71
|
+
(0, class_validator_1.IsEnum)(notification_priority_enum_1.NotificationPriority),
|
|
72
|
+
(0, class_validator_1.IsOptional)(),
|
|
73
|
+
__metadata("design:type", String)
|
|
74
|
+
], CreateWebNotificationDto.prototype, "priority", void 0);
|
|
75
|
+
__decorate([
|
|
76
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
77
|
+
__metadata("design:type", String)
|
|
78
|
+
], CreateWebNotificationDto.prototype, "action", void 0);
|
|
79
|
+
__decorate([
|
|
80
|
+
(0, class_validator_1.IsBoolean)(),
|
|
81
|
+
(0, class_validator_1.IsOptional)(),
|
|
82
|
+
__metadata("design:type", Boolean)
|
|
83
|
+
], CreateWebNotificationDto.prototype, "isRead", void 0);
|
|
84
|
+
__decorate([
|
|
85
|
+
(0, class_validator_1.IsString)(),
|
|
86
|
+
(0, class_validator_1.IsOptional)(),
|
|
87
|
+
__metadata("design:type", String)
|
|
88
|
+
], CreateWebNotificationDto.prototype, "actionUrl", void 0);
|
|
89
|
+
__decorate([
|
|
90
|
+
(0, class_validator_1.IsString)(),
|
|
91
|
+
(0, class_validator_1.IsOptional)(),
|
|
92
|
+
__metadata("design:type", String)
|
|
93
|
+
], CreateWebNotificationDto.prototype, "clickAction", void 0);
|
|
94
|
+
__decorate([
|
|
95
|
+
(0, class_validator_1.IsNumber)(),
|
|
96
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
97
|
+
__metadata("design:type", Number)
|
|
98
|
+
], CreateWebNotificationDto.prototype, "userId", void 0);
|
|
99
|
+
__decorate([
|
|
100
|
+
(0, class_validator_1.IsNumber)(),
|
|
101
|
+
(0, class_validator_1.IsOptional)(),
|
|
102
|
+
__metadata("design:type", Number)
|
|
103
|
+
], CreateWebNotificationDto.prototype, "actorUserId", void 0);
|
|
104
|
+
__decorate([
|
|
105
|
+
(0, class_validator_1.IsString)(),
|
|
106
|
+
(0, class_validator_1.IsOptional)(),
|
|
107
|
+
__metadata("design:type", String)
|
|
108
|
+
], CreateWebNotificationDto.prototype, "controlCentreId", void 0);
|
|
109
|
+
__decorate([
|
|
110
|
+
(0, class_validator_1.IsString)(),
|
|
111
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
112
|
+
__metadata("design:type", String)
|
|
113
|
+
], CreateWebNotificationDto.prototype, "organizationId", void 0);
|
|
114
|
+
__decorate([
|
|
115
|
+
(0, class_validator_1.IsObject)(),
|
|
116
|
+
(0, class_validator_1.IsOptional)(),
|
|
117
|
+
__metadata("design:type", Object)
|
|
118
|
+
], CreateWebNotificationDto.prototype, "metadata", void 0);
|
|
119
|
+
//# sourceMappingURL=create-web-notification.dto.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-web-notification.dto.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/dtos/create-web-notification.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA+H;AAE/H,8FAAmF;AACnF,oFAA2E;AAC3E,4EAAmE;AACnE,oFAA2E;AAE3E,MAAa,wBAAwB;CA8EpC;AA9ED,4DA8EC;AA3EG;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;6DACQ;AAIrB;IAFC,IAAA,wBAAM,EAAC,iDAAoB,CAAC;IAC5B,IAAA,4BAAU,GAAE;;0DACmB;AAIhC;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;wDACG;AAGhB;IADC,IAAA,4BAAU,GAAE;;sDACE;AAIf;IAFC,IAAA,wBAAM,EAAC,yDAAuB,CAAC;IAC/B,IAAA,4BAAU,GAAE;;0DACsB;AAInC;IAFC,IAAA,wBAAM,EAAC,yCAAgB,CAAC;IACxB,IAAA,4BAAU,GAAE;;sDACW;AAIxB;IAFC,IAAA,uBAAK,GAAE;IACP,IAAA,4BAAU,GAAE;;0DACK;AAIlB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;uDACE;AAIf;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;sDACC;AAId;IAFC,IAAA,8BAAY,GAAE;IACd,IAAA,4BAAU,GAAE;;2DACM;AAInB;IAFC,IAAA,wBAAM,EAAC,iDAAoB,CAAC;IAC5B,IAAA,4BAAU,GAAE;;0DACmB;AAGhC;IADC,IAAA,4BAAU,GAAE;;wDACqB;AAIlC;IAFC,IAAA,2BAAS,GAAE;IACX,IAAA,4BAAU,GAAE;;wDACI;AAIjB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;2DACM;AAInB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;6DACQ;AAIrB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;wDACG;AAIhB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;6DACQ;AAIrB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;iEACY;AAIzB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;gEACW;AAIxB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;0DACkB"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UpdateWebNotificationDto = void 0;
|
|
4
|
+
const mapped_types_1 = require("@nestjs/mapped-types");
|
|
5
|
+
const create_web_notification_dto_1 = require("./create-web-notification.dto");
|
|
6
|
+
class UpdateWebNotificationDto extends (0, mapped_types_1.PartialType)(create_web_notification_dto_1.CreateWebNotificationDto) {
|
|
7
|
+
}
|
|
8
|
+
exports.UpdateWebNotificationDto = UpdateWebNotificationDto;
|
|
9
|
+
//# sourceMappingURL=update-web-notification.dto.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"update-web-notification.dto.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/dtos/update-web-notification.dto.ts"],"names":[],"mappings":";;;AAAA,uDAAmD;AACnD,+EAAyE;AAEzE,MAAa,wBAAyB,SAAQ,IAAA,0BAAW,EAAC,sDAAwB,CAAC;CAAI;AAAvF,4DAAuF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification-priority.enum.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/enums/notification-priority.enum.ts"],"names":[],"mappings":";;;AAAA,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC9B,mCAAW,CAAA;IACX,yCAAiB,CAAA;IACjB,qCAAa,CAAA;IACb,6CAAqB,CAAA;AACvB,CAAC,EALW,oBAAoB,oCAApB,oBAAoB,QAK/B"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.NotificationProvider = void 0;
|
|
4
|
+
var NotificationProvider;
|
|
5
|
+
(function (NotificationProvider) {
|
|
6
|
+
NotificationProvider["FCM"] = "FCM";
|
|
7
|
+
NotificationProvider["APNS"] = "APNS";
|
|
8
|
+
NotificationProvider["WEB_PUSH"] = "WEB_PUSH";
|
|
9
|
+
NotificationProvider["MOCK"] = "MOCK";
|
|
10
|
+
})(NotificationProvider || (exports.NotificationProvider = NotificationProvider = {}));
|
|
11
|
+
//# sourceMappingURL=notification-provider.enum.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification-provider.enum.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/enums/notification-provider.enum.ts"],"names":[],"mappings":";;;AAAA,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC5B,mCAAW,CAAA;IACX,qCAAa,CAAA;IACb,6CAAqB,CAAA;IACrB,qCAAa,CAAA;AACjB,CAAC,EALW,oBAAoB,oCAApB,oBAAoB,QAK/B"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.NotificationType = void 0;
|
|
4
|
+
var NotificationType;
|
|
5
|
+
(function (NotificationType) {
|
|
6
|
+
NotificationType["INCIDENT"] = "INCIDENT";
|
|
7
|
+
NotificationType["ALERT"] = "ALERT";
|
|
8
|
+
NotificationType["TASK"] = "TASK";
|
|
9
|
+
NotificationType["ACCOUNT"] = "ACCOUNT";
|
|
10
|
+
NotificationType["ANNOUNCEMENT"] = "ANNOUNCEMENT";
|
|
11
|
+
NotificationType["MESSAGE"] = "MESSAGE";
|
|
12
|
+
NotificationType["WORKFLOW"] = "WORKFLOW";
|
|
13
|
+
NotificationType["GENERAL"] = "GENERAL";
|
|
14
|
+
})(NotificationType || (exports.NotificationType = NotificationType = {}));
|
|
15
|
+
//# sourceMappingURL=notification-type.enum.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification-type.enum.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/enums/notification-type.enum.ts"],"names":[],"mappings":";;;AAAA,IAAY,gBASX;AATD,WAAY,gBAAgB;IAC1B,yCAAqB,CAAA;IACrB,mCAAe,CAAA;IACf,iCAAa,CAAA;IACb,uCAAmB,CAAA;IACnB,iDAA6B,CAAA;IAC7B,uCAAmB,CAAA;IACnB,yCAAqB,CAAA;IACrB,uCAAmB,CAAA;AACrB,CAAC,EATW,gBAAgB,gCAAhB,gBAAgB,QAS3B"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.WebNotificationDataType = void 0;
|
|
4
|
+
var WebNotificationDataType;
|
|
5
|
+
(function (WebNotificationDataType) {
|
|
6
|
+
WebNotificationDataType["INCIDENT"] = "INCIDENT";
|
|
7
|
+
WebNotificationDataType["TASK"] = "TASK";
|
|
8
|
+
WebNotificationDataType["MESSAGE"] = "MESSAGE";
|
|
9
|
+
WebNotificationDataType["SUPPORT_TICKET"] = "SUPPORT_TICKET";
|
|
10
|
+
WebNotificationDataType["ALERT"] = "ALERT";
|
|
11
|
+
WebNotificationDataType["SYSTEM_ALERT"] = "SYSTEM_ALERT";
|
|
12
|
+
WebNotificationDataType["OTHER"] = "OTHER";
|
|
13
|
+
})(WebNotificationDataType || (exports.WebNotificationDataType = WebNotificationDataType = {}));
|
|
14
|
+
//# sourceMappingURL=web-notification-data-type.enum.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"web-notification-data-type.enum.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/enums/web-notification-data-type.enum.ts"],"names":[],"mappings":";;;AAAA,IAAY,uBAQX;AARD,WAAY,uBAAuB;IAC/B,gDAAqB,CAAA;IACrB,wCAAa,CAAA;IACb,8CAAmB,CAAA;IACnB,4DAAiC,CAAA;IACjC,0CAAe,CAAA;IACf,wDAA6B,CAAA;IAC7B,0CAAe,CAAA;AACnB,CAAC,EARW,uBAAuB,uCAAvB,uBAAuB,QAQlC"}
|
|
@@ -14,6 +14,14 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
// Enums
|
|
18
|
+
__exportStar(require("./enums/notification-priority.enum"), exports);
|
|
19
|
+
__exportStar(require("./enums/web-notification-data-type.enum"), exports);
|
|
17
20
|
__exportStar(require("./enums/notification-type.enum"), exports);
|
|
18
|
-
__exportStar(require("./enums/notification-
|
|
21
|
+
__exportStar(require("./enums/notification-provider.enum"), exports);
|
|
22
|
+
// Interfaces
|
|
23
|
+
__exportStar(require("./interfaces/web-notification"), exports);
|
|
24
|
+
// DTOs
|
|
25
|
+
__exportStar(require("./dtos/create-web-notification.dto"), exports);
|
|
26
|
+
__exportStar(require("./dtos/update-web-notification.dto"), exports);
|
|
19
27
|
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/modules/web-notification/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,QAAQ;AACR,qEAAmD;AACnD,0EAAwD;AACxD,iEAA+C;AAC/C,qEAAmD;AAEnD,aAAa;AACb,gEAA8C;AAE9C,OAAO;AACP,qEAAmD;AACnD,qEAAmD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"web-notification.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/interfaces/web-notification.ts"],"names":[],"mappings":""}
|
package/dist/esm/index.js
CHANGED
|
@@ -14,6 +14,7 @@ export * from './modules/dms/index';
|
|
|
14
14
|
export * from './modules/sms/index';
|
|
15
15
|
export * from './modules/gis/index';
|
|
16
16
|
export * from './modules/socket/index';
|
|
17
|
+
export * from './modules/web-notification/index';
|
|
17
18
|
// Interfaces
|
|
18
19
|
export * from './interfaces/server-message';
|
|
19
20
|
export * from './interfaces/i-request-with-user';
|
package/dist/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,UAAU;AACV,cAAc,sBAAsB,CAAC;AACrC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,wBAAwB,CAAC;AACvC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,uBAAuB,CAAC;AACtC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,UAAU;AACV,cAAc,sBAAsB,CAAC;AACrC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,wBAAwB,CAAC;AACvC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,sBAAsB,CAAC;AACrC,cAAc,sBAAsB,CAAC;AACrC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,uBAAuB,CAAC;AACtC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,qBAAqB,CAAC;AACpC,cAAc,wBAAwB,CAAC;AACvC,cAAc,kCAAkC,CAAC;AAEjD,aAAa;AACb,cAAc,6BAA6B,CAAC;AAC5C,cAAc,kCAAkC,CAAC;AACjD,cAAc,6BAA6B,CAAC;AAC5C,cAAc,0BAA0B,CAAC;AACzC,cAAc,yBAAyB,CAAC;AAExC,YAAY;AACZ,cAAc,0BAA0B,CAAC;AAEzC,QAAQ;AACR,cAAc,eAAe,CAAC;AAE9B,YAAY;AACZ,cAAc,8BAA8B,CAAC;AAC7C,cAAc,uDAAuD,CAAC;AAEtE,aAAa;AACb,cAAc,oBAAoB,CAAC"}
|
|
@@ -3,7 +3,6 @@ export * from './interfaces/event-response';
|
|
|
3
3
|
export * from './interfaces/online-user';
|
|
4
4
|
export * from './interfaces/event-envelope';
|
|
5
5
|
export * from './interfaces/client-safe-incident';
|
|
6
|
-
export * from './interfaces/notification';
|
|
7
6
|
export * from './enums/room-type.enum';
|
|
8
|
-
export * from '
|
|
7
|
+
export * from '../web-notification/enums/web-notification-data-type.enum';
|
|
9
8
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/modules/socket/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC;AACzC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,0BAA0B,CAAC;AACzC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,mCAAmC,CAAC;AAClD,cAAc,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/modules/socket/index.ts"],"names":[],"mappings":"AAAA,cAAc,0BAA0B,CAAC;AACzC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,0BAA0B,CAAC;AACzC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,mCAAmC,CAAC;AAClD,cAAc,wBAAwB,CAAC;AACvC,cAAc,2DAA2D,CAAC"}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
|
+
};
|
|
10
|
+
import { IsBoolean, IsDateString, IsEnum, IsNotEmpty, IsNumber, IsObject, IsOptional, IsString, IsUrl } from "class-validator";
|
|
11
|
+
import { WebNotificationDataType } from "../enums/web-notification-data-type.enum";
|
|
12
|
+
import { NotificationPriority } from "../enums/notification-priority.enum";
|
|
13
|
+
import { NotificationType } from "../enums/notification-type.enum";
|
|
14
|
+
import { NotificationProvider } from "../enums/notification-provider.enum";
|
|
15
|
+
export class CreateWebNotificationDto {
|
|
16
|
+
}
|
|
17
|
+
__decorate([
|
|
18
|
+
IsString(),
|
|
19
|
+
IsOptional(),
|
|
20
|
+
__metadata("design:type", String)
|
|
21
|
+
], CreateWebNotificationDto.prototype, "deviceToken", void 0);
|
|
22
|
+
__decorate([
|
|
23
|
+
IsEnum(NotificationProvider),
|
|
24
|
+
IsOptional(),
|
|
25
|
+
__metadata("design:type", String)
|
|
26
|
+
], CreateWebNotificationDto.prototype, "provider", void 0);
|
|
27
|
+
__decorate([
|
|
28
|
+
IsNumber(),
|
|
29
|
+
IsOptional(),
|
|
30
|
+
__metadata("design:type", Number)
|
|
31
|
+
], CreateWebNotificationDto.prototype, "dataId", void 0);
|
|
32
|
+
__decorate([
|
|
33
|
+
IsOptional(),
|
|
34
|
+
__metadata("design:type", Object)
|
|
35
|
+
], CreateWebNotificationDto.prototype, "data", void 0);
|
|
36
|
+
__decorate([
|
|
37
|
+
IsEnum(WebNotificationDataType),
|
|
38
|
+
IsOptional(),
|
|
39
|
+
__metadata("design:type", String)
|
|
40
|
+
], CreateWebNotificationDto.prototype, "dataType", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
IsEnum(NotificationType),
|
|
43
|
+
IsOptional(),
|
|
44
|
+
__metadata("design:type", String)
|
|
45
|
+
], CreateWebNotificationDto.prototype, "type", void 0);
|
|
46
|
+
__decorate([
|
|
47
|
+
IsUrl(),
|
|
48
|
+
IsOptional(),
|
|
49
|
+
__metadata("design:type", String)
|
|
50
|
+
], CreateWebNotificationDto.prototype, "imageUrl", void 0);
|
|
51
|
+
__decorate([
|
|
52
|
+
IsString(),
|
|
53
|
+
IsNotEmpty(),
|
|
54
|
+
__metadata("design:type", String)
|
|
55
|
+
], CreateWebNotificationDto.prototype, "title", void 0);
|
|
56
|
+
__decorate([
|
|
57
|
+
IsString(),
|
|
58
|
+
IsNotEmpty(),
|
|
59
|
+
__metadata("design:type", String)
|
|
60
|
+
], CreateWebNotificationDto.prototype, "body", void 0);
|
|
61
|
+
__decorate([
|
|
62
|
+
IsDateString(),
|
|
63
|
+
IsNotEmpty(),
|
|
64
|
+
__metadata("design:type", String)
|
|
65
|
+
], CreateWebNotificationDto.prototype, "timestamp", void 0);
|
|
66
|
+
__decorate([
|
|
67
|
+
IsEnum(NotificationPriority),
|
|
68
|
+
IsOptional(),
|
|
69
|
+
__metadata("design:type", String)
|
|
70
|
+
], CreateWebNotificationDto.prototype, "priority", void 0);
|
|
71
|
+
__decorate([
|
|
72
|
+
IsNotEmpty(),
|
|
73
|
+
__metadata("design:type", String)
|
|
74
|
+
], CreateWebNotificationDto.prototype, "action", void 0);
|
|
75
|
+
__decorate([
|
|
76
|
+
IsBoolean(),
|
|
77
|
+
IsOptional(),
|
|
78
|
+
__metadata("design:type", Boolean)
|
|
79
|
+
], CreateWebNotificationDto.prototype, "isRead", void 0);
|
|
80
|
+
__decorate([
|
|
81
|
+
IsString(),
|
|
82
|
+
IsOptional(),
|
|
83
|
+
__metadata("design:type", String)
|
|
84
|
+
], CreateWebNotificationDto.prototype, "actionUrl", void 0);
|
|
85
|
+
__decorate([
|
|
86
|
+
IsString(),
|
|
87
|
+
IsOptional(),
|
|
88
|
+
__metadata("design:type", String)
|
|
89
|
+
], CreateWebNotificationDto.prototype, "clickAction", void 0);
|
|
90
|
+
__decorate([
|
|
91
|
+
IsNumber(),
|
|
92
|
+
IsNotEmpty(),
|
|
93
|
+
__metadata("design:type", Number)
|
|
94
|
+
], CreateWebNotificationDto.prototype, "userId", void 0);
|
|
95
|
+
__decorate([
|
|
96
|
+
IsNumber(),
|
|
97
|
+
IsOptional(),
|
|
98
|
+
__metadata("design:type", Number)
|
|
99
|
+
], CreateWebNotificationDto.prototype, "actorUserId", void 0);
|
|
100
|
+
__decorate([
|
|
101
|
+
IsString(),
|
|
102
|
+
IsOptional(),
|
|
103
|
+
__metadata("design:type", String)
|
|
104
|
+
], CreateWebNotificationDto.prototype, "controlCentreId", void 0);
|
|
105
|
+
__decorate([
|
|
106
|
+
IsString(),
|
|
107
|
+
IsNotEmpty(),
|
|
108
|
+
__metadata("design:type", String)
|
|
109
|
+
], CreateWebNotificationDto.prototype, "organizationId", void 0);
|
|
110
|
+
__decorate([
|
|
111
|
+
IsObject(),
|
|
112
|
+
IsOptional(),
|
|
113
|
+
__metadata("design:type", Object)
|
|
114
|
+
], CreateWebNotificationDto.prototype, "metadata", void 0);
|
|
115
|
+
//# sourceMappingURL=create-web-notification.dto.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-web-notification.dto.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/dtos/create-web-notification.dto.ts"],"names":[],"mappings":";;;;;;;;;AAAA,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,EAAE,UAAU,EAAE,QAAQ,EAAE,QAAQ,EAAE,UAAU,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AAE/H,OAAO,EAAE,uBAAuB,EAAE,MAAM,0CAA0C,CAAC;AACnF,OAAO,EAAE,oBAAoB,EAAE,MAAM,qCAAqC,CAAC;AAC3E,OAAO,EAAE,gBAAgB,EAAE,MAAM,iCAAiC,CAAC;AACnE,OAAO,EAAE,oBAAoB,EAAE,MAAM,qCAAqC,CAAC;AAE3E,MAAM,OAAO,wBAAwB;CA8EpC;AA3EG;IAFC,QAAQ,EAAE;IACV,UAAU,EAAE;;6DACQ;AAIrB;IAFC,MAAM,CAAC,oBAAoB,CAAC;IAC5B,UAAU,EAAE;;0DACmB;AAIhC;IAFC,QAAQ,EAAE;IACV,UAAU,EAAE;;wDACG;AAGhB;IADC,UAAU,EAAE;;sDACE;AAIf;IAFC,MAAM,CAAC,uBAAuB,CAAC;IAC/B,UAAU,EAAE;;0DACsB;AAInC;IAFC,MAAM,CAAC,gBAAgB,CAAC;IACxB,UAAU,EAAE;;sDACW;AAIxB;IAFC,KAAK,EAAE;IACP,UAAU,EAAE;;0DACK;AAIlB;IAFC,QAAQ,EAAE;IACV,UAAU,EAAE;;uDACE;AAIf;IAFC,QAAQ,EAAE;IACV,UAAU,EAAE;;sDACC;AAId;IAFC,YAAY,EAAE;IACd,UAAU,EAAE;;2DACM;AAInB;IAFC,MAAM,CAAC,oBAAoB,CAAC;IAC5B,UAAU,EAAE;;0DACmB;AAGhC;IADC,UAAU,EAAE;;wDACqB;AAIlC;IAFC,SAAS,EAAE;IACX,UAAU,EAAE;;wDACI;AAIjB;IAFC,QAAQ,EAAE;IACV,UAAU,EAAE;;2DACM;AAInB;IAFC,QAAQ,EAAE;IACV,UAAU,EAAE;;6DACQ;AAIrB;IAFC,QAAQ,EAAE;IACV,UAAU,EAAE;;wDACG;AAIhB;IAFC,QAAQ,EAAE;IACV,UAAU,EAAE;;6DACQ;AAIrB;IAFC,QAAQ,EAAE;IACV,UAAU,EAAE;;iEACY;AAIzB;IAFC,QAAQ,EAAE;IACV,UAAU,EAAE;;gEACW;AAIxB;IAFC,QAAQ,EAAE;IACV,UAAU,EAAE;;0DACkB"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { PartialType } from "@nestjs/mapped-types";
|
|
2
|
+
import { CreateWebNotificationDto } from "./create-web-notification.dto";
|
|
3
|
+
export class UpdateWebNotificationDto extends PartialType(CreateWebNotificationDto) {
|
|
4
|
+
}
|
|
5
|
+
//# sourceMappingURL=update-web-notification.dto.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"update-web-notification.dto.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/dtos/update-web-notification.dto.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AACnD,OAAO,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AAEzE,MAAM,OAAO,wBAAyB,SAAQ,WAAW,CAAC,wBAAwB,CAAC;CAAI"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification-priority.enum.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/enums/notification-priority.enum.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC9B,mCAAW,CAAA;IACX,yCAAiB,CAAA;IACjB,qCAAa,CAAA;IACb,6CAAqB,CAAA;AACvB,CAAC,EALW,oBAAoB,KAApB,oBAAoB,QAK/B"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export var NotificationProvider;
|
|
2
|
+
(function (NotificationProvider) {
|
|
3
|
+
NotificationProvider["FCM"] = "FCM";
|
|
4
|
+
NotificationProvider["APNS"] = "APNS";
|
|
5
|
+
NotificationProvider["WEB_PUSH"] = "WEB_PUSH";
|
|
6
|
+
NotificationProvider["MOCK"] = "MOCK";
|
|
7
|
+
})(NotificationProvider || (NotificationProvider = {}));
|
|
8
|
+
//# sourceMappingURL=notification-provider.enum.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification-provider.enum.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/enums/notification-provider.enum.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC5B,mCAAW,CAAA;IACX,qCAAa,CAAA;IACb,6CAAqB,CAAA;IACrB,qCAAa,CAAA;AACjB,CAAC,EALW,oBAAoB,KAApB,oBAAoB,QAK/B"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export var NotificationType;
|
|
2
|
+
(function (NotificationType) {
|
|
3
|
+
NotificationType["INCIDENT"] = "INCIDENT";
|
|
4
|
+
NotificationType["ALERT"] = "ALERT";
|
|
5
|
+
NotificationType["TASK"] = "TASK";
|
|
6
|
+
NotificationType["ACCOUNT"] = "ACCOUNT";
|
|
7
|
+
NotificationType["ANNOUNCEMENT"] = "ANNOUNCEMENT";
|
|
8
|
+
NotificationType["MESSAGE"] = "MESSAGE";
|
|
9
|
+
NotificationType["WORKFLOW"] = "WORKFLOW";
|
|
10
|
+
NotificationType["GENERAL"] = "GENERAL";
|
|
11
|
+
})(NotificationType || (NotificationType = {}));
|
|
12
|
+
//# sourceMappingURL=notification-type.enum.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification-type.enum.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/enums/notification-type.enum.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,gBASX;AATD,WAAY,gBAAgB;IAC1B,yCAAqB,CAAA;IACrB,mCAAe,CAAA;IACf,iCAAa,CAAA;IACb,uCAAmB,CAAA;IACnB,iDAA6B,CAAA;IAC7B,uCAAmB,CAAA;IACnB,yCAAqB,CAAA;IACrB,uCAAmB,CAAA;AACrB,CAAC,EATW,gBAAgB,KAAhB,gBAAgB,QAS3B"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export var WebNotificationDataType;
|
|
2
|
+
(function (WebNotificationDataType) {
|
|
3
|
+
WebNotificationDataType["INCIDENT"] = "INCIDENT";
|
|
4
|
+
WebNotificationDataType["TASK"] = "TASK";
|
|
5
|
+
WebNotificationDataType["MESSAGE"] = "MESSAGE";
|
|
6
|
+
WebNotificationDataType["SUPPORT_TICKET"] = "SUPPORT_TICKET";
|
|
7
|
+
WebNotificationDataType["ALERT"] = "ALERT";
|
|
8
|
+
WebNotificationDataType["SYSTEM_ALERT"] = "SYSTEM_ALERT";
|
|
9
|
+
WebNotificationDataType["OTHER"] = "OTHER";
|
|
10
|
+
})(WebNotificationDataType || (WebNotificationDataType = {}));
|
|
11
|
+
//# sourceMappingURL=web-notification-data-type.enum.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"web-notification-data-type.enum.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/enums/web-notification-data-type.enum.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,uBAQX;AARD,WAAY,uBAAuB;IAC/B,gDAAqB,CAAA;IACrB,wCAAa,CAAA;IACb,8CAAmB,CAAA;IACnB,4DAAiC,CAAA;IACjC,0CAAe,CAAA;IACf,wDAA6B,CAAA;IAC7B,0CAAe,CAAA;AACnB,CAAC,EARW,uBAAuB,KAAvB,uBAAuB,QAQlC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
// Enums
|
|
2
|
+
export * from './enums/notification-priority.enum';
|
|
3
|
+
export * from './enums/web-notification-data-type.enum';
|
|
4
|
+
export * from './enums/notification-type.enum';
|
|
5
|
+
export * from './enums/notification-provider.enum';
|
|
6
|
+
// Interfaces
|
|
7
|
+
export * from './interfaces/web-notification';
|
|
8
|
+
// DTOs
|
|
9
|
+
export * from './dtos/create-web-notification.dto';
|
|
10
|
+
export * from './dtos/update-web-notification.dto';
|
|
11
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/modules/web-notification/index.ts"],"names":[],"mappings":"AAAA,QAAQ;AACR,cAAc,oCAAoC,CAAC;AACnD,cAAc,yCAAyC,CAAC;AACxD,cAAc,gCAAgC,CAAC;AAC/C,cAAc,oCAAoC,CAAC;AAEnD,aAAa;AACb,cAAc,+BAA+B,CAAC;AAE9C,OAAO;AACP,cAAc,oCAAoC,CAAC;AACnD,cAAc,oCAAoC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"web-notification.js","sourceRoot":"","sources":["../../../../../src/modules/web-notification/interfaces/web-notification.ts"],"names":[],"mappings":""}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -13,6 +13,7 @@ export * from './modules/dms/index';
|
|
|
13
13
|
export * from './modules/sms/index';
|
|
14
14
|
export * from './modules/gis/index';
|
|
15
15
|
export * from './modules/socket/index';
|
|
16
|
+
export * from './modules/web-notification/index';
|
|
16
17
|
export * from './interfaces/server-message';
|
|
17
18
|
export * from './interfaces/i-request-with-user';
|
|
18
19
|
export * from './interfaces/validated-user';
|
|
@@ -3,6 +3,5 @@ export * from './interfaces/event-response';
|
|
|
3
3
|
export * from './interfaces/online-user';
|
|
4
4
|
export * from './interfaces/event-envelope';
|
|
5
5
|
export * from './interfaces/client-safe-incident';
|
|
6
|
-
export * from './interfaces/notification';
|
|
7
6
|
export * from './enums/room-type.enum';
|
|
8
|
-
export * from '
|
|
7
|
+
export * from '../web-notification/enums/web-notification-data-type.enum';
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { IncidentActions } from "../../incident";
|
|
2
|
+
import { WebNotificationDataType } from "../enums/web-notification-data-type.enum";
|
|
3
|
+
import { NotificationPriority } from "../enums/notification-priority.enum";
|
|
4
|
+
import { NotificationType } from "../enums/notification-type.enum";
|
|
5
|
+
import { NotificationProvider } from "../enums/notification-provider.enum";
|
|
6
|
+
export declare class CreateWebNotificationDto<TEntity = any> {
|
|
7
|
+
deviceToken?: string;
|
|
8
|
+
provider?: NotificationProvider;
|
|
9
|
+
dataId?: number;
|
|
10
|
+
data?: TEntity;
|
|
11
|
+
dataType?: WebNotificationDataType;
|
|
12
|
+
type?: NotificationType;
|
|
13
|
+
imageUrl?: string;
|
|
14
|
+
title: string;
|
|
15
|
+
body: string;
|
|
16
|
+
timestamp: string;
|
|
17
|
+
priority?: NotificationPriority;
|
|
18
|
+
action: IncidentActions | string;
|
|
19
|
+
isRead?: boolean;
|
|
20
|
+
actionUrl?: string;
|
|
21
|
+
clickAction?: string;
|
|
22
|
+
userId: number;
|
|
23
|
+
actorUserId?: number;
|
|
24
|
+
controlCentreId?: string;
|
|
25
|
+
organizationId: string;
|
|
26
|
+
metadata?: Record<string, any>;
|
|
27
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { CreateWebNotificationDto } from "./create-web-notification.dto";
|
|
2
|
+
declare const UpdateWebNotificationDto_base: import("@nestjs/mapped-types").MappedType<Partial<CreateWebNotificationDto<unknown>>>;
|
|
3
|
+
export declare class UpdateWebNotificationDto extends UpdateWebNotificationDto_base {
|
|
4
|
+
}
|
|
5
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export * from './enums/notification-priority.enum';
|
|
2
|
+
export * from './enums/web-notification-data-type.enum';
|
|
3
|
+
export * from './enums/notification-type.enum';
|
|
4
|
+
export * from './enums/notification-provider.enum';
|
|
5
|
+
export * from './interfaces/web-notification';
|
|
6
|
+
export * from './dtos/create-web-notification.dto';
|
|
7
|
+
export * from './dtos/update-web-notification.dto';
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { IncidentActions } from "../../incident";
|
|
2
|
+
import { WebNotificationDataType } from "../enums/web-notification-data-type.enum";
|
|
3
|
+
import { NotificationPriority } from "../enums/notification-priority.enum";
|
|
4
|
+
import { NotificationType } from "../enums/notification-type.enum";
|
|
5
|
+
import { NotificationProvider } from "../enums/notification-provider.enum";
|
|
6
|
+
export interface WebNotification<TEntity = any> {
|
|
7
|
+
id: number;
|
|
8
|
+
deviceToken?: string;
|
|
9
|
+
provider?: NotificationProvider;
|
|
10
|
+
dataId?: number;
|
|
11
|
+
data?: TEntity;
|
|
12
|
+
dataType?: WebNotificationDataType;
|
|
13
|
+
type?: NotificationType;
|
|
14
|
+
imageUrl?: string;
|
|
15
|
+
title: string;
|
|
16
|
+
body: string;
|
|
17
|
+
timestamp: string;
|
|
18
|
+
priority?: NotificationPriority;
|
|
19
|
+
action: IncidentActions | string;
|
|
20
|
+
isRead: boolean;
|
|
21
|
+
actionUrl?: string;
|
|
22
|
+
clickAction?: string;
|
|
23
|
+
userId: number;
|
|
24
|
+
actorUserId?: number;
|
|
25
|
+
controlCentreId?: string;
|
|
26
|
+
organizationId: string;
|
|
27
|
+
metadata?: Record<string, any>;
|
|
28
|
+
createdAt: string;
|
|
29
|
+
updatedAt: string;
|
|
30
|
+
}
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"notification-priority.enum.js","sourceRoot":"","sources":["../../../../../src/modules/notification/enums/notification-priority.enum.ts"],"names":[],"mappings":";;;AAAA,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC9B,mCAAW,CAAA;IACX,yCAAiB,CAAA;IACjB,qCAAa,CAAA;IACb,6CAAqB,CAAA;AACvB,CAAC,EALW,oBAAoB,oCAApB,oBAAoB,QAK/B"}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.NotificationType = void 0;
|
|
4
|
-
var NotificationType;
|
|
5
|
-
(function (NotificationType) {
|
|
6
|
-
NotificationType["INCIDENT_CREATED"] = "INCIDENT_CREATED";
|
|
7
|
-
NotificationType["INCIDENT_UPDATED"] = "INCIDENT_UPDATED";
|
|
8
|
-
NotificationType["INCIDENT_ASSIGNED"] = "INCIDENT_ASSIGNED";
|
|
9
|
-
NotificationType["INCIDENT_STATUS_CHANGED"] = "INCIDENT_STATUS_CHANGED";
|
|
10
|
-
NotificationType["INCIDENT_RESPONSE_UNIT_ASSIGNED"] = "INCIDENT_RESPONSE_UNIT_ASSIGNED";
|
|
11
|
-
NotificationType["INCIDENT_REPORT_CREATED"] = "INCIDENT_REPORT_CREATED";
|
|
12
|
-
NotificationType["INCIDENT_WITHDRAWN"] = "INCIDENT_WITHDRAWN";
|
|
13
|
-
})(NotificationType || (exports.NotificationType = NotificationType = {}));
|
|
14
|
-
//# sourceMappingURL=notification-type.enum.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"notification-type.enum.js","sourceRoot":"","sources":["../../../../../src/modules/notification/enums/notification-type.enum.ts"],"names":[],"mappings":";;;AAAA,IAAY,gBAQX;AARD,WAAY,gBAAgB;IAC1B,yDAAqC,CAAA;IACrC,yDAAqC,CAAA;IACrC,2DAAuC,CAAA;IACvC,uEAAmD,CAAA;IACnD,uFAAmE,CAAA;IACnE,uEAAmD,CAAA;IACnD,6DAAyC,CAAA;AAC3C,CAAC,EARW,gBAAgB,gCAAhB,gBAAgB,QAQ3B"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/modules/notification/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,iEAA+C;AAC/C,iEAA+C"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"notification.js","sourceRoot":"","sources":["../../../../../src/modules/notification/interfaces/notification.ts"],"names":[],"mappings":""}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.NotificationPriority = void 0;
|
|
4
|
-
var NotificationPriority;
|
|
5
|
-
(function (NotificationPriority) {
|
|
6
|
-
NotificationPriority["LOW"] = "Low";
|
|
7
|
-
NotificationPriority["MEDIUM"] = "Medium";
|
|
8
|
-
NotificationPriority["HIGH"] = "High";
|
|
9
|
-
NotificationPriority["CRITICAL"] = "Critical";
|
|
10
|
-
})(NotificationPriority || (exports.NotificationPriority = NotificationPriority = {}));
|
|
11
|
-
//# sourceMappingURL=notification-priority.enum.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"notification-priority.enum.js","sourceRoot":"","sources":["../../../../../src/modules/socket/enums/notification-priority.enum.ts"],"names":[],"mappings":";;;AAAA,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC5B,mCAAW,CAAA;IACX,yCAAiB,CAAA;IACjB,qCAAa,CAAA;IACb,6CAAqB,CAAA;AACzB,CAAC,EALW,oBAAoB,oCAApB,oBAAoB,QAK/B"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"notification.js","sourceRoot":"","sources":["../../../../../src/modules/socket/interfaces/notification.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"notification-priority.enum.js","sourceRoot":"","sources":["../../../../../src/modules/notification/enums/notification-priority.enum.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC9B,mCAAW,CAAA;IACX,yCAAiB,CAAA;IACjB,qCAAa,CAAA;IACb,6CAAqB,CAAA;AACvB,CAAC,EALW,oBAAoB,KAApB,oBAAoB,QAK/B"}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
export var NotificationType;
|
|
2
|
-
(function (NotificationType) {
|
|
3
|
-
NotificationType["INCIDENT_CREATED"] = "INCIDENT_CREATED";
|
|
4
|
-
NotificationType["INCIDENT_UPDATED"] = "INCIDENT_UPDATED";
|
|
5
|
-
NotificationType["INCIDENT_ASSIGNED"] = "INCIDENT_ASSIGNED";
|
|
6
|
-
NotificationType["INCIDENT_STATUS_CHANGED"] = "INCIDENT_STATUS_CHANGED";
|
|
7
|
-
NotificationType["INCIDENT_RESPONSE_UNIT_ASSIGNED"] = "INCIDENT_RESPONSE_UNIT_ASSIGNED";
|
|
8
|
-
NotificationType["INCIDENT_REPORT_CREATED"] = "INCIDENT_REPORT_CREATED";
|
|
9
|
-
NotificationType["INCIDENT_WITHDRAWN"] = "INCIDENT_WITHDRAWN";
|
|
10
|
-
})(NotificationType || (NotificationType = {}));
|
|
11
|
-
//# sourceMappingURL=notification-type.enum.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"notification-type.enum.js","sourceRoot":"","sources":["../../../../../src/modules/notification/enums/notification-type.enum.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,gBAQX;AARD,WAAY,gBAAgB;IAC1B,yDAAqC,CAAA;IACrC,yDAAqC,CAAA;IACrC,2DAAuC,CAAA;IACvC,uEAAmD,CAAA;IACnD,uFAAmE,CAAA;IACnE,uEAAmD,CAAA;IACnD,6DAAyC,CAAA;AAC3C,CAAC,EARW,gBAAgB,KAAhB,gBAAgB,QAQ3B"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/modules/notification/index.ts"],"names":[],"mappings":"AAAA,cAAc,gCAAgC,CAAC;AAC/C,cAAc,gCAAgC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"notification.js","sourceRoot":"","sources":["../../../../../src/modules/notification/interfaces/notification.ts"],"names":[],"mappings":""}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
export var NotificationPriority;
|
|
2
|
-
(function (NotificationPriority) {
|
|
3
|
-
NotificationPriority["LOW"] = "Low";
|
|
4
|
-
NotificationPriority["MEDIUM"] = "Medium";
|
|
5
|
-
NotificationPriority["HIGH"] = "High";
|
|
6
|
-
NotificationPriority["CRITICAL"] = "Critical";
|
|
7
|
-
})(NotificationPriority || (NotificationPriority = {}));
|
|
8
|
-
//# sourceMappingURL=notification-priority.enum.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"notification-priority.enum.js","sourceRoot":"","sources":["../../../../../src/modules/socket/enums/notification-priority.enum.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC5B,mCAAW,CAAA;IACX,yCAAiB,CAAA;IACjB,qCAAa,CAAA;IACb,6CAAqB,CAAA;AACzB,CAAC,EALW,oBAAoB,KAApB,oBAAoB,QAK/B"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"notification.js","sourceRoot":"","sources":["../../../../../src/modules/socket/interfaces/notification.ts"],"names":[],"mappings":""}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
export declare enum NotificationType {
|
|
2
|
-
INCIDENT_CREATED = "INCIDENT_CREATED",
|
|
3
|
-
INCIDENT_UPDATED = "INCIDENT_UPDATED",
|
|
4
|
-
INCIDENT_ASSIGNED = "INCIDENT_ASSIGNED",
|
|
5
|
-
INCIDENT_STATUS_CHANGED = "INCIDENT_STATUS_CHANGED",
|
|
6
|
-
INCIDENT_RESPONSE_UNIT_ASSIGNED = "INCIDENT_RESPONSE_UNIT_ASSIGNED",
|
|
7
|
-
INCIDENT_REPORT_CREATED = "INCIDENT_REPORT_CREATED",
|
|
8
|
-
INCIDENT_WITHDRAWN = "INCIDENT_WITHDRAWN"
|
|
9
|
-
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
export interface Notification {
|
|
2
|
-
id: number;
|
|
3
|
-
userIds: number[];
|
|
4
|
-
type: string;
|
|
5
|
-
title: string;
|
|
6
|
-
message: string;
|
|
7
|
-
priority: string;
|
|
8
|
-
isRead: boolean;
|
|
9
|
-
readAt: Date | null;
|
|
10
|
-
incidentId: number;
|
|
11
|
-
controlCentreId: number;
|
|
12
|
-
organizationId: number;
|
|
13
|
-
actorUserId: number;
|
|
14
|
-
metadata?: Record<string, any>;
|
|
15
|
-
createdAt: Date;
|
|
16
|
-
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { IncidentActions } from "../../incident";
|
|
2
|
-
import { NotificationPriority } from "../enums/notification-priority.enum";
|
|
3
|
-
export interface Notification<TEntity = any> {
|
|
4
|
-
id: string;
|
|
5
|
-
entityId: string;
|
|
6
|
-
payload: TEntity;
|
|
7
|
-
action: IncidentActions | string;
|
|
8
|
-
title: string;
|
|
9
|
-
message: string;
|
|
10
|
-
timestamp: Date;
|
|
11
|
-
priority: NotificationPriority;
|
|
12
|
-
isRead: boolean;
|
|
13
|
-
userId?: string;
|
|
14
|
-
organizationId?: string;
|
|
15
|
-
controlCentreId?: string;
|
|
16
|
-
}
|
/package/dist/cjs/modules/{notification → web-notification}/enums/notification-priority.enum.js
RENAMED
|
File without changes
|
/package/dist/esm/modules/{notification → web-notification}/enums/notification-priority.enum.js
RENAMED
|
File without changes
|
/package/dist/types/modules/{notification → web-notification}/enums/notification-priority.enum.d.ts
RENAMED
|
File without changes
|