sml-baseline 1.0.1 → 1.0.3

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.
Files changed (26) hide show
  1. package/dist/common/core/SmlBaseService.d.ts +1 -0
  2. package/dist/common/core/SmlBaseService.js +15 -0
  3. package/dist/common/core/SmlBaseService.js.map +1 -1
  4. package/dist/index.d.ts +39 -0
  5. package/dist/index.js +61 -1
  6. package/dist/index.js.map +1 -1
  7. package/dist/sml-system-notification/dto/create-sml-system-notification.dto.d.ts +9 -0
  8. package/dist/sml-system-notification/dto/create-sml-system-notification.dto.js +66 -0
  9. package/dist/sml-system-notification/dto/create-sml-system-notification.dto.js.map +1 -0
  10. package/dist/sml-system-notification/dto/update-sml-system-notification.dto.d.ts +5 -0
  11. package/dist/sml-system-notification/dto/update-sml-system-notification.dto.js +9 -0
  12. package/dist/sml-system-notification/dto/update-sml-system-notification.dto.js.map +1 -0
  13. package/dist/sml-system-notification/entities/sml-system-notification.entity.d.ts +21 -0
  14. package/dist/sml-system-notification/entities/sml-system-notification.entity.js +82 -0
  15. package/dist/sml-system-notification/entities/sml-system-notification.entity.js.map +1 -0
  16. package/dist/sml-system-notification/sml-system-notification.controller.d.ts +15 -0
  17. package/dist/sml-system-notification/sml-system-notification.controller.js +75 -0
  18. package/dist/sml-system-notification/sml-system-notification.controller.js.map +1 -0
  19. package/dist/sml-system-notification/sml-system-notification.module.d.ts +2 -0
  20. package/dist/sml-system-notification/sml-system-notification.module.js +27 -0
  21. package/dist/sml-system-notification/sml-system-notification.module.js.map +1 -0
  22. package/dist/sml-system-notification/sml-system-notification.service.d.ts +11 -0
  23. package/dist/sml-system-notification/sml-system-notification.service.js +55 -0
  24. package/dist/sml-system-notification/sml-system-notification.service.js.map +1 -0
  25. package/dist/tsconfig.build.tsbuildinfo +1 -1
  26. package/package.json +2 -1
@@ -11,6 +11,7 @@ export declare class SmlBaseService<T> {
11
11
  }> & {
12
12
  __v?: number;
13
13
  })>;
14
+ findAll(filters: any, limit: number, offset: number): Promise<import("mongoose").IfAny<T, any, import("mongoose").Document<unknown, {}, T> & import("mongoose").Default__v<import("mongoose").Require_id<T>>>[]>;
14
15
  findOne(id: string): Promise<import("mongoose").IfAny<T, any, import("mongoose").Document<unknown, {}, T> & import("mongoose").Default__v<import("mongoose").Require_id<T>>>>;
15
16
  update(id: string, updateDto: any): Promise<import("mongoose").IfAny<T, any, import("mongoose").Document<unknown, {}, T> & import("mongoose").Default__v<import("mongoose").Require_id<T>>>>;
16
17
  remove(id: string): Promise<{
@@ -17,6 +17,21 @@ class SmlBaseService {
17
17
  });
18
18
  }
19
19
  }
20
+ async findAll(filters, limit, offset) {
21
+ try {
22
+ const query = {};
23
+ if (filters) {
24
+ for (const key in filters) {
25
+ if (filters[key])
26
+ query[key] = filters[key];
27
+ }
28
+ }
29
+ return await this.model.find(query).skip(offset).limit(limit);
30
+ }
31
+ catch (e) {
32
+ throw new common_1.InternalServerErrorException(`Error retrieving entities: ${e.message}`);
33
+ }
34
+ }
20
35
  async findOne(id) {
21
36
  try {
22
37
  const record = await this.model.findById(id).exec();
@@ -1 +1 @@
1
- {"version":3,"file":"SmlBaseService.js","sourceRoot":"","sources":["../../../src/common/core/SmlBaseService.ts"],"names":[],"mappings":";;;AAAA,2CAAiF;AAGjF,MAAa,cAAc;IACzB,YAA+B,KAAe;QAAf,UAAK,GAAL,KAAK,CAAU;IAAG,CAAC;IAElD,KAAK,CAAC,MAAM,CAAC,SAAc;QACzB,IAAI,CAAC;YACH,MAAM,aAAa,GAAG,IAAI,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC;YAChD,OAAO,MAAM,aAAa,CAAC,IAAI,EAAE,CAAC;QACpC,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,MAAM,IAAI,qCAA4B,CAAC;gBACrC,WAAW,EAAE,4BAA4B,CAAC,CAAC,OAAO,EAAE;aACrD,CAAC,CAAC;QACL,CAAC;IACH,CAAC;IAED,KA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AAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,IAAI,CAAC,YAAY,0BAAiB,EAAE,CAAC;gBACnC,MAAM,CAAC,CAAC;YACV,CAAC;YACD,MAAM,IAAI,qCAA4B,CAAC;gBACrC,WAAW,EAAE,qCAAqC,EAAE,KAAK,CAAC,CAAC,OAAO,EAAE;aACrE,CAAC,CAAC;QACL,CAAC;IACH,CAAC;IAED,KAAK,CAAC,MAAM,CAAC,EAAU;QACrB,IAAI,CAAC;YACH,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,KAAK,CAAC,iBAAiB,CAAC,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC;YAC7D,IAAI,CAAC,MAAM,EAAE,CAAC;gBACZ,MAAM,IAAI,0BAAiB,CAAC,mBAAmB,EAAE,YAAY,CAAC,CAAC;YACjE,CAAC;YAED,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;QAC3B,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,MAAM,IAAI,qCAA4B,CAAC;gBACrC,WAAW,EAAE,qCAAqC,EAAE,KAAK,CAAC,CAAC,OAAO,EAAE;aACrE,CAAC,CAAC;QACL,CAAC;IACH,CAAC;CACF;AAtFD,wCAsFC"}
package/dist/index.d.ts CHANGED
@@ -20,3 +20,42 @@ export { SmlProxyQueryModule } from './sml-proxy-query/sml-proxy-query.module';
20
20
  export { SmlrecordlinkModule } from './smlrecordlink/smlrecordlink.module';
21
21
  export { SmlrecordlockModule } from './smlrecordlock/smlrecordlock.module';
22
22
  export { SmlviewModule } from './smlview/smlview.module';
23
+ export { SmlSystemNotificationModule } from './sml-system-notification/sml-system-notification.module';
24
+ export * from './smlentity-definition/schemas/smlentity-definition.schema';
25
+ export * from './smlentity/entities/smlentity.entity';
26
+ export * from './smlgrid/entities/smlgrid.entity';
27
+ export * from './smlform/entities/smlform.entity';
28
+ export * from './smlquery/entities/smlquery.entity';
29
+ export * from './smlappmenu/entities/smlappmenu.entity';
30
+ export * from './smlattachments/entities/smlattachment.entity';
31
+ export * from './smlchart/entities/smlchart.entity';
32
+ export * from './smlcomposedview/entities/smlcomposedview.entity';
33
+ export * from './smlcustomcode/entities/smlcustomcode.entity';
34
+ export * from './smlcustomfunction/entities/smlcustomfunction.entity';
35
+ export * from './smlflowpanelanalistance/entities/smlflowpanelanalistance.entity';
36
+ export * from './smlrecordlink/entities/smlrecordlink.entity';
37
+ export * from './smlrecordlock/entities/smlrecordlock.entity';
38
+ export * from './flow-panels/entities/flow-panel.entity';
39
+ export * from './navigation-panels/entities/navigation-panel.entity';
40
+ export * from './sml-proxy-query/entities/sml-proxy-query.entity';
41
+ export * from './sml-system-notification/entities/sml-system-notification.entity';
42
+ export { SmlentityService } from './smlentity/smlentity.service';
43
+ export { SmlgridService } from './smlgrid/smlgrid.service';
44
+ export { SmlformService } from './smlform/smlform.service';
45
+ export { SmlqueryService } from './smlquery/smlquery.service';
46
+ export { SmlappmenuService } from './smlappmenu/smlappmenu.service';
47
+ export { SmlattachmentService } from './smlattachments/smlattachments.service';
48
+ export { SmlchartService } from './smlchart/smlchart.service';
49
+ export { SmlcomposedviewService } from './smlcomposedview/smlcomposedview.service';
50
+ export { SmlcustomcodeService } from './smlcustomcode/smlcustomcode.service';
51
+ export { SmlcustomfunctionService } from './smlcustomfunction/smlcustomfunction.service';
52
+ export { SmlentityDefinitionService } from './smlentity-definition/smlentity-definition.service';
53
+ export { SmlentityManagerService } from './smlentity-manager/smlentity-manager.service';
54
+ export { SmlflowpanelanalistanceService } from './smlflowpanelanalistance/smlflowpanelanalistance.service';
55
+ export { FlowPanelsService } from './flow-panels/flow-panels.service';
56
+ export { NavigationPanelsService } from './navigation-panels/navigation-panels.service';
57
+ export { SmlProxyQueryService } from './sml-proxy-query/sml-proxy-query.service';
58
+ export { SmlrecordlinkService } from './smlrecordlink/smlrecordlink.service';
59
+ export { SmlrecordlockService } from './smlrecordlock/smlrecordlock.service';
60
+ export { SmlviewService } from './smlview/smlview.service';
61
+ export { SmlSystemNotificationService } from './sml-system-notification/sml-system-notification.service';
package/dist/index.js CHANGED
@@ -14,7 +14,7 @@ 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
- exports.SmlviewModule = exports.SmlrecordlockModule = exports.SmlrecordlinkModule = exports.SmlProxyQueryModule = exports.NavigationPanelsModule = exports.FlowPanelsModule = exports.SmlflowpanelanalistanceModule = exports.SmlentityManagerModule = exports.SmlentityDefinitionModule = exports.SmlcustomfunctionModule = exports.SmlcustomcodeModule = exports.SmlconfigModule = exports.SmlcomposedviewModule = exports.SmlchartModule = exports.SmlattachmentsModule = exports.SmlappmenuModule = exports.SmlqueryModule = exports.SmlformModule = exports.SmlgridModule = exports.SmlentityModule = void 0;
17
+ exports.SmlSystemNotificationService = exports.SmlviewService = exports.SmlrecordlockService = exports.SmlrecordlinkService = exports.SmlProxyQueryService = exports.NavigationPanelsService = exports.FlowPanelsService = exports.SmlflowpanelanalistanceService = exports.SmlentityManagerService = exports.SmlentityDefinitionService = exports.SmlcustomfunctionService = exports.SmlcustomcodeService = exports.SmlcomposedviewService = exports.SmlchartService = exports.SmlattachmentService = exports.SmlappmenuService = exports.SmlqueryService = exports.SmlformService = exports.SmlgridService = exports.SmlentityService = exports.SmlSystemNotificationModule = exports.SmlviewModule = exports.SmlrecordlockModule = exports.SmlrecordlinkModule = exports.SmlProxyQueryModule = exports.NavigationPanelsModule = exports.FlowPanelsModule = exports.SmlflowpanelanalistanceModule = exports.SmlentityManagerModule = exports.SmlentityDefinitionModule = exports.SmlcustomfunctionModule = exports.SmlcustomcodeModule = exports.SmlconfigModule = exports.SmlcomposedviewModule = exports.SmlchartModule = exports.SmlattachmentsModule = exports.SmlappmenuModule = exports.SmlqueryModule = exports.SmlformModule = exports.SmlgridModule = exports.SmlentityModule = void 0;
18
18
  __exportStar(require("./common"), exports);
19
19
  __exportStar(require("./authentication"), exports);
20
20
  var smlentity_module_1 = require("./smlentity/smlentity.module");
@@ -57,4 +57,64 @@ var smlrecordlock_module_1 = require("./smlrecordlock/smlrecordlock.module");
57
57
  Object.defineProperty(exports, "SmlrecordlockModule", { enumerable: true, get: function () { return smlrecordlock_module_1.SmlrecordlockModule; } });
58
58
  var smlview_module_1 = require("./smlview/smlview.module");
59
59
  Object.defineProperty(exports, "SmlviewModule", { enumerable: true, get: function () { return smlview_module_1.SmlviewModule; } });
60
+ var sml_system_notification_module_1 = require("./sml-system-notification/sml-system-notification.module");
61
+ Object.defineProperty(exports, "SmlSystemNotificationModule", { enumerable: true, get: function () { return sml_system_notification_module_1.SmlSystemNotificationModule; } });
62
+ __exportStar(require("./smlentity-definition/schemas/smlentity-definition.schema"), exports);
63
+ __exportStar(require("./smlentity/entities/smlentity.entity"), exports);
64
+ __exportStar(require("./smlgrid/entities/smlgrid.entity"), exports);
65
+ __exportStar(require("./smlform/entities/smlform.entity"), exports);
66
+ __exportStar(require("./smlquery/entities/smlquery.entity"), exports);
67
+ __exportStar(require("./smlappmenu/entities/smlappmenu.entity"), exports);
68
+ __exportStar(require("./smlattachments/entities/smlattachment.entity"), exports);
69
+ __exportStar(require("./smlchart/entities/smlchart.entity"), exports);
70
+ __exportStar(require("./smlcomposedview/entities/smlcomposedview.entity"), exports);
71
+ __exportStar(require("./smlcustomcode/entities/smlcustomcode.entity"), exports);
72
+ __exportStar(require("./smlcustomfunction/entities/smlcustomfunction.entity"), exports);
73
+ __exportStar(require("./smlflowpanelanalistance/entities/smlflowpanelanalistance.entity"), exports);
74
+ __exportStar(require("./smlrecordlink/entities/smlrecordlink.entity"), exports);
75
+ __exportStar(require("./smlrecordlock/entities/smlrecordlock.entity"), exports);
76
+ __exportStar(require("./flow-panels/entities/flow-panel.entity"), exports);
77
+ __exportStar(require("./navigation-panels/entities/navigation-panel.entity"), exports);
78
+ __exportStar(require("./sml-proxy-query/entities/sml-proxy-query.entity"), exports);
79
+ __exportStar(require("./sml-system-notification/entities/sml-system-notification.entity"), exports);
80
+ var smlentity_service_1 = require("./smlentity/smlentity.service");
81
+ Object.defineProperty(exports, "SmlentityService", { enumerable: true, get: function () { return smlentity_service_1.SmlentityService; } });
82
+ var smlgrid_service_1 = require("./smlgrid/smlgrid.service");
83
+ Object.defineProperty(exports, "SmlgridService", { enumerable: true, get: function () { return smlgrid_service_1.SmlgridService; } });
84
+ var smlform_service_1 = require("./smlform/smlform.service");
85
+ Object.defineProperty(exports, "SmlformService", { enumerable: true, get: function () { return smlform_service_1.SmlformService; } });
86
+ var smlquery_service_1 = require("./smlquery/smlquery.service");
87
+ Object.defineProperty(exports, "SmlqueryService", { enumerable: true, get: function () { return smlquery_service_1.SmlqueryService; } });
88
+ var smlappmenu_service_1 = require("./smlappmenu/smlappmenu.service");
89
+ Object.defineProperty(exports, "SmlappmenuService", { enumerable: true, get: function () { return smlappmenu_service_1.SmlappmenuService; } });
90
+ var smlattachments_service_1 = require("./smlattachments/smlattachments.service");
91
+ Object.defineProperty(exports, "SmlattachmentService", { enumerable: true, get: function () { return smlattachments_service_1.SmlattachmentService; } });
92
+ var smlchart_service_1 = require("./smlchart/smlchart.service");
93
+ Object.defineProperty(exports, "SmlchartService", { enumerable: true, get: function () { return smlchart_service_1.SmlchartService; } });
94
+ var smlcomposedview_service_1 = require("./smlcomposedview/smlcomposedview.service");
95
+ Object.defineProperty(exports, "SmlcomposedviewService", { enumerable: true, get: function () { return smlcomposedview_service_1.SmlcomposedviewService; } });
96
+ var smlcustomcode_service_1 = require("./smlcustomcode/smlcustomcode.service");
97
+ Object.defineProperty(exports, "SmlcustomcodeService", { enumerable: true, get: function () { return smlcustomcode_service_1.SmlcustomcodeService; } });
98
+ var smlcustomfunction_service_1 = require("./smlcustomfunction/smlcustomfunction.service");
99
+ Object.defineProperty(exports, "SmlcustomfunctionService", { enumerable: true, get: function () { return smlcustomfunction_service_1.SmlcustomfunctionService; } });
100
+ var smlentity_definition_service_1 = require("./smlentity-definition/smlentity-definition.service");
101
+ Object.defineProperty(exports, "SmlentityDefinitionService", { enumerable: true, get: function () { return smlentity_definition_service_1.SmlentityDefinitionService; } });
102
+ var smlentity_manager_service_1 = require("./smlentity-manager/smlentity-manager.service");
103
+ Object.defineProperty(exports, "SmlentityManagerService", { enumerable: true, get: function () { return smlentity_manager_service_1.SmlentityManagerService; } });
104
+ var smlflowpanelanalistance_service_1 = require("./smlflowpanelanalistance/smlflowpanelanalistance.service");
105
+ Object.defineProperty(exports, "SmlflowpanelanalistanceService", { enumerable: true, get: function () { return smlflowpanelanalistance_service_1.SmlflowpanelanalistanceService; } });
106
+ var flow_panels_service_1 = require("./flow-panels/flow-panels.service");
107
+ Object.defineProperty(exports, "FlowPanelsService", { enumerable: true, get: function () { return flow_panels_service_1.FlowPanelsService; } });
108
+ var navigation_panels_service_1 = require("./navigation-panels/navigation-panels.service");
109
+ Object.defineProperty(exports, "NavigationPanelsService", { enumerable: true, get: function () { return navigation_panels_service_1.NavigationPanelsService; } });
110
+ var sml_proxy_query_service_1 = require("./sml-proxy-query/sml-proxy-query.service");
111
+ Object.defineProperty(exports, "SmlProxyQueryService", { enumerable: true, get: function () { return sml_proxy_query_service_1.SmlProxyQueryService; } });
112
+ var smlrecordlink_service_1 = require("./smlrecordlink/smlrecordlink.service");
113
+ Object.defineProperty(exports, "SmlrecordlinkService", { enumerable: true, get: function () { return smlrecordlink_service_1.SmlrecordlinkService; } });
114
+ var smlrecordlock_service_1 = require("./smlrecordlock/smlrecordlock.service");
115
+ Object.defineProperty(exports, "SmlrecordlockService", { enumerable: true, get: function () { return smlrecordlock_service_1.SmlrecordlockService; } });
116
+ var smlview_service_1 = require("./smlview/smlview.service");
117
+ Object.defineProperty(exports, "SmlviewService", { enumerable: true, get: function () { return smlview_service_1.SmlviewService; } });
118
+ var sml_system_notification_service_1 = require("./sml-system-notification/sml-system-notification.service");
119
+ Object.defineProperty(exports, "SmlSystemNotificationService", { enumerable: true, get: function () { return sml_system_notification_service_1.SmlSystemNotificationService; } });
60
120
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,2CAAyB;AACzB,mDAAiC;AACjC,iEAA+D;AAAtD,mHAAA,eAAe,OAAA;AACxB,2DAAyD;AAAhD,+GAAA,aAAa,OAAA;AACtB,2DAAyD;AAAhD,+GAAA,aAAa,OAAA;AACtB,8DAA4D;AAAnD,iHAAA,cAAc,OAAA;AACvB,oEAAkE;AAAzD,qHAAA,gBAAgB,OAAA;AACzB,gFAA8E;AAArE,6HAAA,oBAAoB,OAAA;AAC7B,8DAA4D;AAAnD,iHAAA,cAAc,OAAA;AACvB,mFAAiF;AAAxE,+HAAA,qBAAqB,OAAA;AAC9B,iEAA+D;AAAtD,mHAAA,eAAe,OAAA;AACxB,6EAA2E;AAAlE,2HAAA,mBAAmB,OAAA;AAC5B,yFAAuF;AAA9E,mIAAA,uBAAuB,OAAA;AAChC,kGAA+F;AAAtF,wIAAA,yBAAyB,OAAA;AAClC,yFAAsF;AAA7E,kIAAA,sBAAsB,OAAA;AAC/B,2GAAyG;AAAhG,+IAAA,6BAA6B,OAAA;AACtC,uEAAoE;AAA3D,sHAAA,gBAAgB,OAAA;AACzB,yFAAsF;AAA7E,kIAAA,sBAAsB,OAAA;AAC/B,mFAA+E;AAAtE,6HAAA,mBAAmB,OAAA;AAC5B,6EAA2E;AAAlE,2HAAA,mBAAmB,OAAA;AAC5B,6EAA2E;AAAlE,2HAAA,mBAAmB,OAAA;AAC5B,2DAAyD;AAAhD,+GAAA,aAAa,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,2CAAyB;AACzB,mDAAiC;AAGjC,iEAA+D;AAAtD,mHAAA,eAAe,OAAA;AACx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HAAA,cAAc,OAAA;AACvB,gEAA8D;AAArD,mHAAA,eAAe,OAAA;AACxB,sEAAoE;AAA3D,uHAAA,iBAAiB,OAAA;AAC1B,kFAA+E;AAAtE,8HAAA,oBAAoB,OAAA;AAC7B,gEAA8D;AAArD,mHAAA,eAAe,OAAA;AACxB,qFAAmF;AAA1E,iIAAA,sBAAsB,OAAA;AAC/B,+EAA6E;AAApE,6HAAA,oBAAoB,OAAA;AAC7B,2FAAyF;AAAhF,qIAAA,wBAAwB,OAAA;AACjC,oGAAiG;AAAxF,0IAAA,0BAA0B,OAAA;AACnC,2FAAwF;AAA/E,oIAAA,uBAAuB,OAAA;AAChC,6GAA2G;AAAlG,iJAAA,8BAA8B,OAAA;AACvC,yEAAsE;AAA7D,wHAAA,iBAAiB,OAAA;AAC1B,2FAAwF;AAA/E,oIAAA,uBAAuB,OAAA;AAChC,qFAAiF;AAAxE,+HAAA,oBAAoB,OAAA;AAC7B,+EAA6E;AAApE,6HAAA,oBAAoB,OAAA;AAC7B,+EAA6E;AAApE,6HAAA,oBAAoB,OAAA;AAC7B,6DAA2D;AAAlD,iHAAA,cAAc,OAAA;AACvB,6GAAyG;AAAhG,+IAAA,4BAA4B,OAAA"}
@@ -0,0 +1,9 @@
1
+ export declare class CreateSmlSystemNotificationDto {
2
+ notificationType: string;
3
+ notificationPriority: string;
4
+ notificationTitle: string;
5
+ notificationText: string;
6
+ notificationDate: Date;
7
+ isReaded: boolean;
8
+ destinationUser: string[];
9
+ }
@@ -0,0 +1,66 @@
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.CreateSmlSystemNotificationDto = void 0;
13
+ const class_validator_1 = require("class-validator");
14
+ const class_transformer_1 = require("class-transformer");
15
+ const swagger_1 = require("@nestjs/swagger");
16
+ class CreateSmlSystemNotificationDto {
17
+ }
18
+ exports.CreateSmlSystemNotificationDto = CreateSmlSystemNotificationDto;
19
+ __decorate([
20
+ (0, class_validator_1.IsString)(),
21
+ (0, class_validator_1.IsNotEmpty)(),
22
+ (0, class_transformer_1.Expose)(),
23
+ (0, swagger_1.ApiProperty)(),
24
+ __metadata("design:type", String)
25
+ ], CreateSmlSystemNotificationDto.prototype, "notificationType", void 0);
26
+ __decorate([
27
+ (0, class_validator_1.IsString)(),
28
+ (0, class_validator_1.IsNotEmpty)(),
29
+ (0, class_transformer_1.Expose)(),
30
+ (0, swagger_1.ApiProperty)(),
31
+ __metadata("design:type", String)
32
+ ], CreateSmlSystemNotificationDto.prototype, "notificationPriority", void 0);
33
+ __decorate([
34
+ (0, class_validator_1.IsString)(),
35
+ (0, class_validator_1.IsNotEmpty)(),
36
+ (0, class_transformer_1.Expose)(),
37
+ (0, swagger_1.ApiProperty)(),
38
+ __metadata("design:type", String)
39
+ ], CreateSmlSystemNotificationDto.prototype, "notificationTitle", void 0);
40
+ __decorate([
41
+ (0, class_validator_1.IsString)(),
42
+ (0, class_validator_1.IsNotEmpty)(),
43
+ (0, class_transformer_1.Expose)(),
44
+ (0, swagger_1.ApiProperty)(),
45
+ __metadata("design:type", String)
46
+ ], CreateSmlSystemNotificationDto.prototype, "notificationText", void 0);
47
+ __decorate([
48
+ (0, swagger_1.ApiProperty)({ type: String, format: 'date' }),
49
+ (0, class_validator_1.IsDate)(),
50
+ (0, class_transformer_1.Type)(() => Date),
51
+ __metadata("design:type", Date)
52
+ ], CreateSmlSystemNotificationDto.prototype, "notificationDate", void 0);
53
+ __decorate([
54
+ (0, class_validator_1.IsBoolean)(),
55
+ (0, class_transformer_1.Expose)(),
56
+ (0, swagger_1.ApiProperty)(),
57
+ __metadata("design:type", Boolean)
58
+ ], CreateSmlSystemNotificationDto.prototype, "isReaded", void 0);
59
+ __decorate([
60
+ (0, class_validator_1.IsArray)(),
61
+ (0, class_validator_1.IsString)({ each: true }),
62
+ (0, class_transformer_1.Expose)(),
63
+ (0, swagger_1.ApiProperty)(),
64
+ __metadata("design:type", Array)
65
+ ], CreateSmlSystemNotificationDto.prototype, "destinationUser", void 0);
66
+ //# sourceMappingURL=create-sml-system-notification.dto.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"create-sml-system-notification.dto.js","sourceRoot":"","sources":["../../../src/sml-system-notification/dto/create-sml-system-notification.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAmF;AACnF,yDAAiD;AACjD,6CAA8C;AAE9C,MAAa,8BAA8B;CAwC1C;AAxCD,wEAwCC;AAnCC;IAJC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;IACZ,IAAA,0BAAM,GAAE;IACR,IAAA,qBAAW,GAAE;;wEACW;AAMzB;IAJC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;IACZ,IAAA,0BAAM,GAAE;IACR,IAAA,qBAAW,GAAE;;4EACe;AAM7B;IAJC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;IACZ,IAAA,0BAAM,GAAE;IACR,IAAA,qBAAW,GAAE;;yEACY;AAM1B;IAJC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;IACZ,IAAA,0BAAM,GAAE;IACR,IAAA,qBAAW,GAAE;;wEACW;AAKzB;IAHC,IAAA,qBAAW,EAAC,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;IAC7C,IAAA,wBAAM,GAAE;IACR,IAAA,wBAAI,EAAC,GAAG,EAAE,CAAC,IAAI,CAAC;8BACC,IAAI;wEAAC;AAKvB;IAHC,IAAA,2BAAS,GAAE;IACX,IAAA,0BAAM,GAAE;IACR,IAAA,qBAAW,GAAE;;gEACI;AAMlB;IAJC,IAAA,yBAAO,GAAE;IACT,IAAA,0BAAQ,EAAC,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;IACxB,IAAA,0BAAM,GAAE;IACR,IAAA,qBAAW,GAAE;;uEACY"}
@@ -0,0 +1,5 @@
1
+ import { CreateSmlSystemNotificationDto } from './create-sml-system-notification.dto';
2
+ declare const UpdateSmlSystemNotificationDto_base: import("@nestjs/common").Type<Partial<CreateSmlSystemNotificationDto>>;
3
+ export declare class UpdateSmlSystemNotificationDto extends UpdateSmlSystemNotificationDto_base {
4
+ }
5
+ export {};
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.UpdateSmlSystemNotificationDto = void 0;
4
+ const swagger_1 = require("@nestjs/swagger");
5
+ const create_sml_system_notification_dto_1 = require("./create-sml-system-notification.dto");
6
+ class UpdateSmlSystemNotificationDto extends (0, swagger_1.PartialType)(create_sml_system_notification_dto_1.CreateSmlSystemNotificationDto) {
7
+ }
8
+ exports.UpdateSmlSystemNotificationDto = UpdateSmlSystemNotificationDto;
9
+ //# sourceMappingURL=update-sml-system-notification.dto.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"update-sml-system-notification.dto.js","sourceRoot":"","sources":["../../../src/sml-system-notification/dto/update-sml-system-notification.dto.ts"],"names":[],"mappings":";;;AAAA,6CAA8C;AAC9C,6FAAsF;AAEtF,MAAa,8BAA+B,SAAQ,IAAA,qBAAW,EAAC,mEAA8B,CAAC;CAAG;AAAlG,wEAAkG"}
@@ -0,0 +1,21 @@
1
+ import mongoose, { HydratedDocument } from 'mongoose';
2
+ export type SmlSystemNotificationDocument = HydratedDocument<SmlSystemNotification>;
3
+ export declare class SmlSystemNotification {
4
+ _id: string;
5
+ notificationType: string;
6
+ notificationPriority: string;
7
+ notificationTitle: string;
8
+ notificationText: string;
9
+ notificationDate: Date;
10
+ isReaded: boolean;
11
+ destinationUser: string[];
12
+ }
13
+ export declare const SmlSystemNotificationSchema: mongoose.Schema<SmlSystemNotification, mongoose.Model<SmlSystemNotification, any, any, any, mongoose.Document<unknown, any, SmlSystemNotification> & SmlSystemNotification & Required<{
14
+ _id: string;
15
+ }> & {
16
+ __v?: number;
17
+ }, any>, {}, {}, {}, {}, mongoose.DefaultSchemaOptions, SmlSystemNotification, mongoose.Document<unknown, {}, mongoose.FlatRecord<SmlSystemNotification>> & mongoose.FlatRecord<SmlSystemNotification> & Required<{
18
+ _id: string;
19
+ }> & {
20
+ __v?: number;
21
+ }>;
@@ -0,0 +1,82 @@
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
+ var __importDefault = (this && this.__importDefault) || function (mod) {
12
+ return (mod && mod.__esModule) ? mod : { "default": mod };
13
+ };
14
+ Object.defineProperty(exports, "__esModule", { value: true });
15
+ exports.SmlSystemNotificationSchema = exports.SmlSystemNotification = void 0;
16
+ const mongoose_1 = __importDefault(require("mongoose"));
17
+ const mongoose_2 = require("@nestjs/mongoose");
18
+ let SmlSystemNotification = class SmlSystemNotification {
19
+ };
20
+ exports.SmlSystemNotification = SmlSystemNotification;
21
+ __decorate([
22
+ (0, mongoose_2.Prop)({ type: mongoose_1.default.Schema.Types.ObjectId, auto: true }),
23
+ __metadata("design:type", String)
24
+ ], SmlSystemNotification.prototype, "_id", void 0);
25
+ __decorate([
26
+ (0, mongoose_2.Prop)({
27
+ type: String,
28
+ required: true
29
+ }),
30
+ __metadata("design:type", String)
31
+ ], SmlSystemNotification.prototype, "notificationType", void 0);
32
+ __decorate([
33
+ (0, mongoose_2.Prop)({
34
+ type: String,
35
+ required: true
36
+ }),
37
+ __metadata("design:type", String)
38
+ ], SmlSystemNotification.prototype, "notificationPriority", void 0);
39
+ __decorate([
40
+ (0, mongoose_2.Prop)({
41
+ type: String,
42
+ required: true
43
+ }),
44
+ __metadata("design:type", String)
45
+ ], SmlSystemNotification.prototype, "notificationTitle", void 0);
46
+ __decorate([
47
+ (0, mongoose_2.Prop)({
48
+ type: String,
49
+ required: true
50
+ }),
51
+ __metadata("design:type", String)
52
+ ], SmlSystemNotification.prototype, "notificationText", void 0);
53
+ __decorate([
54
+ (0, mongoose_2.Prop)({
55
+ type: Date,
56
+ required: true
57
+ }),
58
+ __metadata("design:type", Date)
59
+ ], SmlSystemNotification.prototype, "notificationDate", void 0);
60
+ __decorate([
61
+ (0, mongoose_2.Prop)({
62
+ type: Boolean,
63
+ required: true
64
+ }),
65
+ __metadata("design:type", Boolean)
66
+ ], SmlSystemNotification.prototype, "isReaded", void 0);
67
+ __decorate([
68
+ (0, mongoose_2.Prop)({
69
+ type: [String],
70
+ required: true
71
+ }),
72
+ __metadata("design:type", Array)
73
+ ], SmlSystemNotification.prototype, "destinationUser", void 0);
74
+ exports.SmlSystemNotification = SmlSystemNotification = __decorate([
75
+ (0, mongoose_2.Schema)({
76
+ timestamps: true,
77
+ toJSON: { getters: true, virtuals: true },
78
+ collection: 'smlsystemnotifications',
79
+ })
80
+ ], SmlSystemNotification);
81
+ exports.SmlSystemNotificationSchema = mongoose_2.SchemaFactory.createForClass(SmlSystemNotification);
82
+ //# sourceMappingURL=sml-system-notification.entity.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sml-system-notification.entity.js","sourceRoot":"","sources":["../../../src/sml-system-notification/entities/sml-system-notification.entity.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,wDAAsD;AACtD,+CAA+D;AASxD,IAAM,qBAAqB,GAA3B,MAAM,qBAAqB;CA8CjC,CAAA;AA9CY,sDAAqB;AAEhC;IADC,IAAA,eAAI,EAAC,EAAE,IAAI,EAAE,kBAAQ,CAAC,MAAM,CAAC,KAAK,CAAC,QAAQ,EAAE,IAAI,EAAE,IAAI,EAAE,CAAC;;kDAC/C;AAMZ;IAJC,IAAA,eAAI,EAAC;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACf,CAAC;;+DACuB;AAMzB;IAJC,IAAA,eAAI,EAAC;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACf,CAAC;;mEAC2B;AAM7B;IAJC,IAAA,eAAI,EAAC;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACf,CAAC;;gEACwB;AAM1B;IAJC,IAAA,eAAI,EAAC;QACJ,IAAI,EAAE,MAAM;QACZ,QAAQ,EAAE,IAAI;KACf,CAAC;;+DACuB;AAMzB;IAJC,IAAA,eAAI,EAAC;QACJ,IAAI,EAAE,IAAI;QACV,QAAQ,EAAE,IAAI;KACf,CAAC;8BACgB,IAAI;+DAAC;AAMvB;IAJC,IAAA,eAAI,EAAC;QACJ,IAAI,EAAE,OAAO;QACb,QAAQ,EAAE,IAAI;KACf,CAAC;;uDACgB;AAMlB;IAJC,IAAA,eAAI,EAAC;QACJ,IAAI,EAAE,CAAC,MAAM,CAAC;QACd,QAAQ,EAAE,IAAI;KACf,CAAC;;8DACwB;gCA5Cf,qBAAqB;IALjC,IAAA,iBAAM,EAAC;QACN,UAAU,EAAE,IAAI;QAChB,MAAM,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE;QACzC,UAAU,EAAE,wBAAwB;KACrC,CAAC;GACW,qBAAqB,CA8CjC;AAEY,QAAA,2BAA2B,GAAG,wBAAa,CAAC,cAAc,CAAC,qBAAqB,CAAC,CAAC"}
@@ -0,0 +1,15 @@
1
+ import { SmlSystemNotification } from './entities/sml-system-notification.entity';
2
+ declare const BaseController: {
3
+ new (service: import("..").SmlBaseService<SmlSystemNotification>): {
4
+ create(dto: any): Promise<string>;
5
+ findAll(): Promise<string>;
6
+ findOne(id: string): Promise<string>;
7
+ update(id: string, dto: any): Promise<string>;
8
+ remove(id: string): Promise<string>;
9
+ service: any;
10
+ };
11
+ };
12
+ export declare class SmlSystemNotificationController extends BaseController {
13
+ findAllByUsername(currentUserSetup: any, filters?: string, limit?: number, offset?: number): Promise<string>;
14
+ }
15
+ export {};
@@ -0,0 +1,75 @@
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
+ var __param = (this && this.__param) || function (paramIndex, decorator) {
12
+ return function (target, key) { decorator(target, key, paramIndex); }
13
+ };
14
+ Object.defineProperty(exports, "__esModule", { value: true });
15
+ exports.SmlSystemNotificationController = void 0;
16
+ const CrudControllerFactory_1 = require("../common/core/CrudControllerFactory");
17
+ const has_role_decorator_decorator_1 = require("../authentication/decorators/has-role-decorator.decorator");
18
+ const user_role_enum_1 = require("../authentication/enum/user-role.enum");
19
+ const sml_system_notification_service_1 = require("./sml-system-notification.service");
20
+ const create_sml_system_notification_dto_1 = require("./dto/create-sml-system-notification.dto");
21
+ const sml_system_notification_entity_1 = require("./entities/sml-system-notification.entity");
22
+ const update_sml_system_notification_dto_1 = require("./dto/update-sml-system-notification.dto");
23
+ const common_1 = require("@nestjs/common");
24
+ const swagger_1 = require("@nestjs/swagger");
25
+ const current_user_decorator_1 = require("../authentication/decorators/current-user.decorator");
26
+ const authorization_guard_guard_1 = require("../authentication/guards/authorization-guard.guard");
27
+ const role_guard_guard_1 = require("../authentication/guards/role-guard.guard");
28
+ const BaseController = (0, CrudControllerFactory_1.createCrudController)(sml_system_notification_service_1.SmlSystemNotificationService, {
29
+ path: 'sml-system-notification',
30
+ entity: sml_system_notification_entity_1.SmlSystemNotification,
31
+ createDto: create_sml_system_notification_dto_1.CreateSmlSystemNotificationDto,
32
+ updateDto: update_sml_system_notification_dto_1.UpdateSmlSystemNotificationDto,
33
+ });
34
+ let SmlSystemNotificationController = class SmlSystemNotificationController extends BaseController {
35
+ async findAllByUsername(currentUserSetup, filters, limit = 10, offset = 0) {
36
+ let parsedFilters = {};
37
+ if (filters) {
38
+ try {
39
+ parsedFilters = JSON.parse(filters);
40
+ }
41
+ catch {
42
+ throw new Error('Invalid JSON format for filters');
43
+ }
44
+ }
45
+ const data = await this.service.findAllByUsername(currentUserSetup.username, parsedFilters, limit, offset);
46
+ return JSON.stringify(data, null, 2);
47
+ }
48
+ };
49
+ exports.SmlSystemNotificationController = SmlSystemNotificationController;
50
+ __decorate([
51
+ (0, common_1.UseGuards)(authorization_guard_guard_1.AuthorizationGuard, role_guard_guard_1.RoleGuard),
52
+ (0, swagger_1.ApiBearerAuth)('access-token'),
53
+ (0, common_1.Get)('my-notifications'),
54
+ (0, common_1.Version)('1'),
55
+ (0, swagger_1.ApiQuery)({
56
+ name: 'filters',
57
+ required: false,
58
+ description: 'Filters in JSON format',
59
+ type: String,
60
+ }),
61
+ (0, swagger_1.ApiQuery)({ name: 'limit', required: false, type: Number, default: 10 }),
62
+ (0, swagger_1.ApiQuery)({ name: 'offset', required: false, type: Number, default: 0 }),
63
+ (0, swagger_1.ApiOperation)({ summary: 'Fetch notifications by user logged' }),
64
+ __param(0, (0, current_user_decorator_1.CurrentUser)()),
65
+ __param(1, (0, common_1.Query)('filters')),
66
+ __param(2, (0, common_1.Query)('limit')),
67
+ __param(3, (0, common_1.Query)('offset')),
68
+ __metadata("design:type", Function),
69
+ __metadata("design:paramtypes", [Object, String, Object, Object]),
70
+ __metadata("design:returntype", Promise)
71
+ ], SmlSystemNotificationController.prototype, "findAllByUsername", null);
72
+ exports.SmlSystemNotificationController = SmlSystemNotificationController = __decorate([
73
+ (0, has_role_decorator_decorator_1.HasRoles)(user_role_enum_1.Role.SML_O_ADMIN)
74
+ ], SmlSystemNotificationController);
75
+ //# sourceMappingURL=sml-system-notification.controller.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sml-system-notification.controller.js","sourceRoot":"","sources":["../../src/sml-system-notification/sml-system-notification.controller.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,gFAA4E;AAC5E,4GAAqF;AACrF,0EAA6D;AAC7D,uFAAiF;AACjF,iGAA0F;AAC1F,8FAAkF;AAClF,iGAA0F;AAC1F,2CAAgE;AAChE,6CAAwE;AACxE,gGAAkF;AAClF,kGAAwF;AACxF,gFAAsE;AAEtE,MAAM,cAAc,GAAG,IAAA,4CAAoB,EAAC,8DAA4B,EAAE;IACxE,IAAI,EAAE,yBAAyB;IAC/B,MAAM,EAAE,sDAAqB;IAC7B,SAAS,EAAE,mEAA8B;IACzC,SAAS,EAAE,mEAA8B;CAC1C,CAAC,CAAC;AAGI,IAAM,+BAA+B,GAArC,MAAM,+BAAgC,SAAQ,cAAc;IAkB3D,AAAN,KAAK,CAAC,iBAAiB,CACN,gBAAqB,EA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b,WAAA,IAAA,cAAK,EAAC,SAAS,CAAC,CAAA;IAChB,WAAA,IAAA,cAAK,EAAC,OAAO,CAAC,CAAA;IACd,WAAA,IAAA,cAAK,EAAC,QAAQ,CAAC,CAAA;;;;wEAiBjB;0CAvCU,+BAA+B;IAD3C,IAAA,uCAAQ,EAAC,qBAAI,CAAC,WAAW,CAAC;GACd,+BAA+B,CAwC3C"}
@@ -0,0 +1,2 @@
1
+ export declare class SmlSystemNotificationModule {
2
+ }
@@ -0,0 +1,27 @@
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
+ Object.defineProperty(exports, "__esModule", { value: true });
9
+ exports.SmlSystemNotificationModule = void 0;
10
+ const common_1 = require("@nestjs/common");
11
+ const sml_system_notification_service_1 = require("./sml-system-notification.service");
12
+ const sml_system_notification_controller_1 = require("./sml-system-notification.controller");
13
+ const mongoose_1 = require("@nestjs/mongoose");
14
+ const sml_system_notification_entity_1 = require("./entities/sml-system-notification.entity");
15
+ let SmlSystemNotificationModule = class SmlSystemNotificationModule {
16
+ };
17
+ exports.SmlSystemNotificationModule = SmlSystemNotificationModule;
18
+ exports.SmlSystemNotificationModule = SmlSystemNotificationModule = __decorate([
19
+ (0, common_1.Module)({
20
+ controllers: [sml_system_notification_controller_1.SmlSystemNotificationController],
21
+ providers: [sml_system_notification_service_1.SmlSystemNotificationService],
22
+ imports: [
23
+ mongoose_1.MongooseModule.forFeature([{ name: sml_system_notification_entity_1.SmlSystemNotification.name, schema: sml_system_notification_entity_1.SmlSystemNotificationSchema }]),
24
+ ],
25
+ })
26
+ ], SmlSystemNotificationModule);
27
+ //# sourceMappingURL=sml-system-notification.module.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sml-system-notification.module.js","sourceRoot":"","sources":["../../src/sml-system-notification/sml-system-notification.module.ts"],"names":[],"mappings":";;;;;;;;;AAAA,2CAAwC;AACxC,uFAAiF;AACjF,6FAAuF;AACvF,+CAAkD;AAClD,8FAA+G;AASxG,IAAM,2BAA2B,GAAjC,MAAM,2BAA2B;CAAG,CAAA;AAA9B,kEAA2B;sCAA3B,2BAA2B;IAPvC,IAAA,eAAM,EAAC;QACN,WAAW,EAAE,CAAC,oEAA+B,CAAC;QAC9C,SAAS,EAAE,CAAC,8DAA4B,CAAC;QACzC,OAAO,EAAE;YACP,yBAAc,CAAC,UAAU,CAAC,CAAC,EAAE,IAAI,EAAE,sDAAqB,CAAC,IAAI,EAAE,MAAM,EAAE,4DAA2B,EAAE,CAAC,CAAC;SACvG;KACF,CAAC;GACW,2BAA2B,CAAG"}
@@ -0,0 +1,11 @@
1
+ import { SmlBaseService } from '../common/core/SmlBaseService';
2
+ import { Model } from 'mongoose';
3
+ import { SmlSystemNotification } from './entities/sml-system-notification.entity';
4
+ export declare class SmlSystemNotificationService extends SmlBaseService<SmlSystemNotification> {
5
+ constructor(model: Model<SmlSystemNotification>);
6
+ findAllByUsername(username: string, filters?: any, limit?: number, offset?: number): Promise<(import("mongoose").Document<unknown, {}, SmlSystemNotification> & SmlSystemNotification & Required<{
7
+ _id: string;
8
+ }> & {
9
+ __v?: number;
10
+ })[]>;
11
+ }
@@ -0,0 +1,55 @@
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
+ var __param = (this && this.__param) || function (paramIndex, decorator) {
12
+ return function (target, key) { decorator(target, key, paramIndex); }
13
+ };
14
+ Object.defineProperty(exports, "__esModule", { value: true });
15
+ exports.SmlSystemNotificationService = void 0;
16
+ const common_1 = require("@nestjs/common");
17
+ const SmlBaseService_1 = require("../common/core/SmlBaseService");
18
+ const mongoose_1 = require("@nestjs/mongoose");
19
+ const mongoose_2 = require("mongoose");
20
+ const sml_system_notification_entity_1 = require("./entities/sml-system-notification.entity");
21
+ let SmlSystemNotificationService = class SmlSystemNotificationService extends SmlBaseService_1.SmlBaseService {
22
+ constructor(model) {
23
+ super(model);
24
+ }
25
+ async findAllByUsername(username, filters = {}, limit = 50, offset = 0) {
26
+ try {
27
+ const query = {
28
+ destinationUser: username,
29
+ isReaded: false,
30
+ };
31
+ if (filters) {
32
+ for (const key in filters) {
33
+ if (filters[key] !== undefined && filters[key] !== null) {
34
+ query[key] = filters[key];
35
+ }
36
+ }
37
+ }
38
+ return await this.model
39
+ .find(query)
40
+ .sort({ notificationDate: -1 })
41
+ .skip(offset)
42
+ .limit(limit);
43
+ }
44
+ catch (e) {
45
+ throw new common_1.InternalServerErrorException(`Error retrieving notifications: ${e.message}`);
46
+ }
47
+ }
48
+ };
49
+ exports.SmlSystemNotificationService = SmlSystemNotificationService;
50
+ exports.SmlSystemNotificationService = SmlSystemNotificationService = __decorate([
51
+ (0, common_1.Injectable)(),
52
+ __param(0, (0, mongoose_1.InjectModel)(sml_system_notification_entity_1.SmlSystemNotification.name)),
53
+ __metadata("design:paramtypes", [mongoose_2.Model])
54
+ ], SmlSystemNotificationService);
55
+ //# sourceMappingURL=sml-system-notification.service.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sml-system-notification.service.js","sourceRoot":"","sources":["../../src/sml-system-notification/sml-system-notification.service.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,2CAA0E;AAC1E,kEAA+D;AAC/D,+CAA+C;AAC/C,uCAAiC;AACjC,8FAAkF;AAG3E,IAAM,4BAA4B,GAAlC,MAAM,4BAA6B,SAAQ,+BAAqC;IACrF,YAEE,KAAmC;QAEnC,KAAK,CAAC,KAAK,CAAC,CAAC;IACf,CAAC;IAUD,KAAK,CAAC,iBAAiB,CACrB,QAAgB,EAChB,UAAe,EAAE,EACjB,KAAK,GAAG,EAAE,EACV,MAAM,GAAG,CAAC;QAEV,IAAI,CAAC;YACH,MAAM,KAAK,GAAQ;gBACjB,eAAe,EAAE,QAAQ;gBACzB,QAAQ,EAAE,KAAK;aAChB,CAAC;YAEF,IAAI,OAAO,EAAE,CAAC;gBACZ,KAAK,MAAM,GAAG,IAAI,OAAO,EAAE,CAAC;oBAC1B,IAAI,OAAO,CAAC,GAAG,CAAC,KAAK,SAAS,IAAI,OAAO,CAAC,GAAG,CAAC,KAAK,IAAI,EAAE,CAAC;wBACxD,KAAK,CAAC,GAAG,CAAC,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC;oBAC5B,CAAC;gBACH,CAAC;YACH,CAAC;YAED,OAAO,MAAM,IAAI,CAAC,KAAK;iBACpB,IAAI,CAAC,KAAK,CAAC;iBACX,IAAI,CAAC,EAAE,gBAAgB,EAAE,CAAC,CAAC,EAAE,CAAC;iBAC9B,IAAI,CAAC,MAAM,CAAC;iBACZ,KAAK,CAAC,KAAK,CAAC,CAAC;QAClB,CAAC;QAAC,OAAO,CAAC,EAAE,CAAC;YACX,MAAM,IAAI,qCAA4B,CACpC,mCAAmC,CAAC,CAAC,OAAO,EAAE,CAC/C,CAAC;QACJ,CAAC;IACH,CAAC;CACF,CAAA;AA/CY,oEAA4B;uCAA5B,4BA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