easywork-common-lib 1.0.111 → 1.0.112
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/common/dtos/send-notification.dto.d.ts +4 -2
- package/dist/common/dtos/send-notification.dto.js +14 -4
- package/dist/common/dtos/send-notification.dto.js.map +1 -1
- package/dist/common/enums/notification.enum.d.ts +10 -0
- package/dist/common/enums/notification.enum.js +12 -1
- package/dist/common/enums/notification.enum.js.map +1 -1
- package/package.json +1 -1
- package/tsconfig.tsbuildinfo +1 -1
|
@@ -1,8 +1,10 @@
|
|
|
1
|
-
import { NotificationCategory, NotificationChannel } from "../../common";
|
|
1
|
+
import { NotificationCategory, NotificationChannel, NotificationSubcategory } from "../../common";
|
|
2
2
|
export declare class SendNotificationDto {
|
|
3
3
|
title: string;
|
|
4
4
|
recipientsId: string[];
|
|
5
|
+
entityId: string;
|
|
5
6
|
content: string;
|
|
6
|
-
|
|
7
|
+
channels: NotificationChannel[];
|
|
7
8
|
category?: NotificationCategory;
|
|
9
|
+
subCategory?: NotificationSubcategory;
|
|
8
10
|
}
|
|
@@ -15,9 +15,11 @@ const common_1 = require("../../common");
|
|
|
15
15
|
class SendNotificationDto {
|
|
16
16
|
title;
|
|
17
17
|
recipientsId;
|
|
18
|
+
entityId;
|
|
18
19
|
content;
|
|
19
|
-
|
|
20
|
+
channels;
|
|
20
21
|
category;
|
|
22
|
+
subCategory;
|
|
21
23
|
}
|
|
22
24
|
exports.SendNotificationDto = SendNotificationDto;
|
|
23
25
|
__decorate([
|
|
@@ -28,16 +30,24 @@ __decorate([
|
|
|
28
30
|
(0, class_validator_1.IsUUID)("all", { each: true }),
|
|
29
31
|
__metadata("design:type", Array)
|
|
30
32
|
], SendNotificationDto.prototype, "recipientsId", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
(0, class_validator_1.IsUUID)(),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], SendNotificationDto.prototype, "entityId", void 0);
|
|
31
37
|
__decorate([
|
|
32
38
|
(0, class_validator_1.IsString)(),
|
|
33
39
|
__metadata("design:type", String)
|
|
34
40
|
], SendNotificationDto.prototype, "content", void 0);
|
|
35
41
|
__decorate([
|
|
36
|
-
(0, class_validator_1.IsEnum)(common_1.NotificationChannel),
|
|
37
|
-
__metadata("design:type",
|
|
38
|
-
], SendNotificationDto.prototype, "
|
|
42
|
+
(0, class_validator_1.IsEnum)(common_1.NotificationChannel, { each: true }),
|
|
43
|
+
__metadata("design:type", Array)
|
|
44
|
+
], SendNotificationDto.prototype, "channels", void 0);
|
|
39
45
|
__decorate([
|
|
40
46
|
(0, class_validator_1.IsEnum)(common_1.NotificationCategory),
|
|
41
47
|
__metadata("design:type", String)
|
|
42
48
|
], SendNotificationDto.prototype, "category", void 0);
|
|
49
|
+
__decorate([
|
|
50
|
+
(0, class_validator_1.IsEnum)(common_1.NotificationSubcategory),
|
|
51
|
+
__metadata("design:type", String)
|
|
52
|
+
], SendNotificationDto.prototype, "subCategory", void 0);
|
|
43
53
|
//# sourceMappingURL=send-notification.dto.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"send-notification.dto.js","sourceRoot":"","sources":["../../../src/common/dtos/send-notification.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA2D;AAC3D,
|
|
1
|
+
{"version":3,"file":"send-notification.dto.js","sourceRoot":"","sources":["../../../src/common/dtos/send-notification.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA2D;AAC3D,yCAAkG;AAElG,MAAa,mBAAmB;IAE5B,KAAK,CAAS;IAGd,YAAY,CAAW;IAGvB,QAAQ,CAAS;IAGjB,OAAO,CAAS;IAGhB,QAAQ,CAAwB;IAGhC,QAAQ,CAAwB;IAGhC,WAAW,CAA2B;CACzC;AArBD,kDAqBC;AAnBG;IADC,IAAA,0BAAQ,GAAE;;kDACG;AAGd;IADC,IAAA,wBAAM,EAAC,KAAK,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;;yDACP;AAGvB;IADC,IAAA,wBAAM,GAAE;;qDACQ;AAGjB;IADC,IAAA,0BAAQ,GAAE;;oDACK;AAGhB;IADC,IAAA,wBAAM,EAAC,4BAAmB,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;;qDACZ;AAGhC;IADC,IAAA,wBAAM,EAAC,6BAAoB,CAAC;;qDACG;AAGhC;IADC,IAAA,wBAAM,EAAC,gCAAuB,CAAC;;wDACM"}
|
|
@@ -4,6 +4,16 @@ export declare enum NotificationChannel {
|
|
|
4
4
|
PUSH = "push",
|
|
5
5
|
APP = "app"
|
|
6
6
|
}
|
|
7
|
+
export declare enum NotificationSubcategory {
|
|
8
|
+
NEW_TASK = "new-task",
|
|
9
|
+
TASK_COMPLETED = "task-complete",
|
|
10
|
+
TASK_OVERDUE = "task-overdue",
|
|
11
|
+
TASK_REMINDER = "task-reminder",
|
|
12
|
+
TASK_NEW_COMMNET = "task-new-comment",
|
|
13
|
+
TASK_APPROVED = "task-approved",
|
|
14
|
+
TASK_REJECTED = "task-rejected",
|
|
15
|
+
TASK_UPDATED = "task-updated"
|
|
16
|
+
}
|
|
7
17
|
export declare enum NotificationCategory {
|
|
8
18
|
TASK = "task",
|
|
9
19
|
CRM = "crm",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.NotificationCategory = exports.NotificationChannel = void 0;
|
|
3
|
+
exports.NotificationCategory = exports.NotificationSubcategory = exports.NotificationChannel = void 0;
|
|
4
4
|
var NotificationChannel;
|
|
5
5
|
(function (NotificationChannel) {
|
|
6
6
|
NotificationChannel["EMAIL"] = "email";
|
|
@@ -8,6 +8,17 @@ var NotificationChannel;
|
|
|
8
8
|
NotificationChannel["PUSH"] = "push";
|
|
9
9
|
NotificationChannel["APP"] = "app";
|
|
10
10
|
})(NotificationChannel || (exports.NotificationChannel = NotificationChannel = {}));
|
|
11
|
+
var NotificationSubcategory;
|
|
12
|
+
(function (NotificationSubcategory) {
|
|
13
|
+
NotificationSubcategory["NEW_TASK"] = "new-task";
|
|
14
|
+
NotificationSubcategory["TASK_COMPLETED"] = "task-complete";
|
|
15
|
+
NotificationSubcategory["TASK_OVERDUE"] = "task-overdue";
|
|
16
|
+
NotificationSubcategory["TASK_REMINDER"] = "task-reminder";
|
|
17
|
+
NotificationSubcategory["TASK_NEW_COMMNET"] = "task-new-comment";
|
|
18
|
+
NotificationSubcategory["TASK_APPROVED"] = "task-approved";
|
|
19
|
+
NotificationSubcategory["TASK_REJECTED"] = "task-rejected";
|
|
20
|
+
NotificationSubcategory["TASK_UPDATED"] = "task-updated";
|
|
21
|
+
})(NotificationSubcategory || (exports.NotificationSubcategory = NotificationSubcategory = {}));
|
|
11
22
|
var NotificationCategory;
|
|
12
23
|
(function (NotificationCategory) {
|
|
13
24
|
NotificationCategory["TASK"] = "task";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"notification.enum.js","sourceRoot":"","sources":["../../../src/common/enums/notification.enum.ts"],"names":[],"mappings":";;;AAAA,IAAY,mBAKX;AALD,WAAY,mBAAmB;IAC3B,sCAAe,CAAA;IACf,kCAAW,CAAA;IACX,oCAAa,CAAA;IACb,kCAAW,CAAA;AACf,CAAC,EALW,mBAAmB,mCAAnB,mBAAmB,QAK9B;AAED,IAAY,oBAUX;AAVD,WAAY,oBAAoB;IAC5B,qCAAa,CAAA;IACb,mCAAW,CAAA;IACX,uCAAe,CAAA;IACf,uCAAe,CAAA;IACf,uCAAe,CAAA;IACf,6CAAqB,CAAA;IACrB,uCAAe,CAAA;IACf,qCAAa,CAAA;IACb,2CAAmB,CAAA;AACvB,CAAC,EAVW,oBAAoB,oCAApB,oBAAoB,QAU/B"}
|
|
1
|
+
{"version":3,"file":"notification.enum.js","sourceRoot":"","sources":["../../../src/common/enums/notification.enum.ts"],"names":[],"mappings":";;;AAAA,IAAY,mBAKX;AALD,WAAY,mBAAmB;IAC3B,sCAAe,CAAA;IACf,kCAAW,CAAA;IACX,oCAAa,CAAA;IACb,kCAAW,CAAA;AACf,CAAC,EALW,mBAAmB,mCAAnB,mBAAmB,QAK9B;AAED,IAAY,uBASX;AATD,WAAY,uBAAuB;IAC/B,gDAAqB,CAAA;IACrB,2DAAgC,CAAA;IAChC,wDAA6B,CAAA;IAC7B,0DAA+B,CAAA;IAC/B,gEAAqC,CAAA;IACrC,0DAA+B,CAAA;IAC/B,0DAA+B,CAAA;IAC/B,wDAA6B,CAAA;AACjC,CAAC,EATW,uBAAuB,uCAAvB,uBAAuB,QASlC;AAED,IAAY,oBAUX;AAVD,WAAY,oBAAoB;IAC5B,qCAAa,CAAA;IACb,mCAAW,CAAA;IACX,uCAAe,CAAA;IACf,uCAAe,CAAA;IACf,uCAAe,CAAA;IACf,6CAAqB,CAAA;IACrB,uCAAe,CAAA;IACf,qCAAa,CAAA;IACb,2CAAmB,CAAA;AACvB,CAAC,EAVW,oBAAoB,oCAApB,oBAAoB,QAU/B"}
|