grm-shared-library 1.0.150 → 1.0.152
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/kafka/client-ids.d.ts +0 -2
- package/dist/kafka/client-ids.js +1 -3
- package/dist/kafka/interfaces/otp-payload.d.ts +4 -6
- package/dist/kafka/topics.d.ts +1 -0
- package/dist/kafka/topics.js +1 -0
- package/dist/modules/incident/dtos/action/create-incident-action.dto.d.ts +6 -0
- package/dist/modules/{organization/dtos/contact-person.dto.js → incident/dtos/action/create-incident-action.dto.js} +15 -17
- package/dist/modules/incident/dtos/action/incident-action.dto.d.ts +6 -5
- package/dist/modules/incident/dtos/action/incident-action.dto.js +5 -13
- package/dist/modules/incident/dtos/action/update-inident-action.dto.d.ts +5 -0
- package/dist/modules/incident/dtos/action/update-inident-action.dto.js +8 -0
- package/dist/modules/incident/dtos/incident/incident.dto.d.ts +4 -4
- package/dist/modules/incident/dtos/incident/incident.dto.js +14 -11
- package/dist/modules/incident/index.d.ts +2 -0
- package/dist/modules/incident/index.js +2 -0
- package/dist/modules/incident/intefaces/incident-action.d.ts +0 -2
- package/package.json +43 -43
- package/dist/kafka/interfaces/password-reset-payload.d.ts +0 -7
- package/dist/kafka/interfaces/password-reset-payload.js +0 -2
- package/dist/kafka/interfaces/user-created-payload.d.ts +0 -13
- package/dist/kafka/interfaces/user-created-payload.js +0 -2
- package/dist/kafka/interfaces/user-registered-payload.d.ts +0 -9
- package/dist/kafka/interfaces/user-registered-payload.js +0 -2
- package/dist/kafka/topics/index.d.ts +0 -13
- package/dist/kafka/topics/index.js +0 -20
- package/dist/kafka/topics/topics.d.ts +0 -13
- package/dist/kafka/topics/topics.js +0 -20
- package/dist/modules/auth/dtos/set-password.dto.d.ts +0 -4
- package/dist/modules/auth/dtos/set-password.dto.js +0 -33
- package/dist/modules/common/constants/service_names.const.d.ts +0 -8
- package/dist/modules/common/constants/service_names.const.js +0 -11
- package/dist/modules/organization/dtos/contact-person.dto.d.ts +0 -6
- package/dist/modules/organization/interfaces/partner.d.ts +0 -17
- package/dist/modules/organization/interfaces/partner.js +0 -2
- package/dist/modules/partner/dtos/create-partner.dto.d.ts +0 -16
- package/dist/modules/partner/dtos/create-partner.dto.js +0 -85
- package/dist/modules/partner/dtos/update-partner.dto.d.ts +0 -5
- package/dist/modules/partner/dtos/update-partner.dto.js +0 -8
- package/dist/modules/partner/enums/partner-status.enum.d.ts +0 -7
- package/dist/modules/partner/enums/partner-status.enum.js +0 -11
- package/dist/modules/partner/index.d.ts +0 -4
- package/dist/modules/partner/index.js +0 -20
- package/dist/modules/partner/interfaces/partner.d.ts +0 -20
- package/dist/modules/partner/interfaces/partner.js +0 -2
- package/dist/modules/response-unit/enums/ambulance-vehicle-type.enum.d.ts +0 -8
- package/dist/modules/response-unit/enums/ambulance-vehicle-type.enum.js +0 -12
- package/dist/modules/response-unit/enums/fire-vehicle-type.enum.d.ts +0 -8
- package/dist/modules/response-unit/enums/fire-vehicle-type.enum.js +0 -12
- package/dist/modules/response-unit/enums/person-unit-category.enum.d.ts +0 -10
- package/dist/modules/response-unit/enums/person-unit-category.enum.js +0 -14
- package/dist/modules/response-unit/enums/person-unit-status.enum.d.ts +0 -7
- package/dist/modules/response-unit/enums/person-unit-status.enum.js +0 -11
- package/dist/modules/response-unit/enums/response-unit-type.enum.d.ts +0 -5
- package/dist/modules/response-unit/enums/response-unit-type.enum.js +0 -9
- package/dist/modules/response-unit/enums/road-rescue-vehicle-type.enum.d.ts +0 -6
- package/dist/modules/response-unit/enums/road-rescue-vehicle-type.enum.js +0 -10
- package/dist/modules/response-unit/enums/security-vehicle-type.enum.d.ts +0 -7
- package/dist/modules/response-unit/enums/security-vehicle-type.enum.js +0 -11
- package/dist/modules/response-unit/enums/vehicle-unit-ownership.enum.d.ts +0 -7
- package/dist/modules/response-unit/enums/vehicle-unit-ownership.enum.js +0 -11
- package/dist/modules/response-unit/enums/vehicle-unit-status.enum.d.ts +0 -5
- package/dist/modules/response-unit/enums/vehicle-unit-status.enum.js +0 -9
- package/dist/modules/response-unit/enums/vehicle-unit-type.enum.d.ts +0 -6
- package/dist/modules/response-unit/enums/vehicle-unit-type.enum.js +0 -10
- package/dist/modules/response-unit/interfaces/ambulance-vehicle.d.ts +0 -5
- package/dist/modules/response-unit/interfaces/ambulance-vehicle.js +0 -2
- package/dist/modules/response-unit/interfaces/fire-vehicle.d.ts +0 -5
- package/dist/modules/response-unit/interfaces/fire-vehicle.js +0 -2
- package/dist/modules/response-unit/interfaces/person-unit.d.ts +0 -11
- package/dist/modules/response-unit/interfaces/person-unit.js +0 -2
- package/dist/modules/response-unit/interfaces/response-unit.d.ts +0 -16
- package/dist/modules/response-unit/interfaces/response-unit.js +0 -2
- package/dist/modules/response-unit/interfaces/road-rescue-vehicle.d.ts +0 -5
- package/dist/modules/response-unit/interfaces/road-rescue-vehicle.js +0 -2
- package/dist/modules/response-unit/interfaces/security-vehicle.d.ts +0 -5
- package/dist/modules/response-unit/interfaces/security-vehicle.js +0 -2
- package/dist/modules/response-unit/interfaces/team-unit.d.ts +0 -7
- package/dist/modules/response-unit/interfaces/team-unit.js +0 -2
- package/dist/modules/response-unit/interfaces/vehicle-unit-crew.d.ts +0 -8
- package/dist/modules/response-unit/interfaces/vehicle-unit-crew.js +0 -2
- package/dist/modules/response-unit/interfaces/vehicle-unit-device.d.ts +0 -15
- package/dist/modules/response-unit/interfaces/vehicle-unit-device.js +0 -2
- package/dist/modules/response-unit/interfaces/vehicle-unit.d.ts +0 -22
- package/dist/modules/response-unit/interfaces/vehicle-unit.js +0 -2
- package/dist/modules/role/data/permissions.data.d.ts +0 -2
- package/dist/modules/role/data/permissions.data.js +0 -52
- package/dist/modules/role/dtos/create-permission.dto.d.ts +0 -4
- package/dist/modules/role/dtos/create-permission.dto.js +0 -27
- package/dist/modules/role/dtos/update-permission.dto.d.ts +0 -5
- package/dist/modules/role/dtos/update-permission.dto.js +0 -8
- package/dist/modules/role/dtos/update-role.dto.d.ts +0 -5
- package/dist/modules/role/dtos/update-role.dto.js +0 -8
- package/dist/modules/role/enums/permission-actions.enum.d.ts +0 -22
- package/dist/modules/role/enums/permission-actions.enum.js +0 -31
- package/dist/modules/role/enums/permissions-moudule.enum.d.ts +0 -7
- package/dist/modules/role/enums/permissions-moudule.enum.js +0 -11
- package/dist/modules/role/interfaces/permission.d.ts +0 -4
- package/dist/modules/role/interfaces/permission.js +0 -2
- package/dist/modules/role/permission/data/permissions.data.d.ts +0 -2
- package/dist/modules/role/permission/data/permissions.data.js +0 -52
- package/dist/modules/role/permission/dtos/create-permission.dto.d.ts +0 -4
- package/dist/modules/role/permission/dtos/create-permission.dto.js +0 -27
- package/dist/modules/role/permission/dtos/update-permission.dto.d.ts +0 -5
- package/dist/modules/role/permission/dtos/update-permission.dto.js +0 -8
- package/dist/modules/role/permission/enums/permission-actions.enum.d.ts +0 -22
- package/dist/modules/role/permission/enums/permission-actions.enum.js +0 -31
- package/dist/modules/role/permission/enums/permissions-moudule.enum.d.ts +0 -7
- package/dist/modules/role/permission/enums/permissions-moudule.enum.js +0 -11
- package/dist/modules/role/permission/interfaces/permission.d.ts +0 -5
- package/dist/modules/role/permission/interfaces/permission.js +0 -2
- package/dist/modules/user/dtos/user-response.dto.d.ts +0 -18
- package/dist/modules/user/dtos/user-response.dto.js +0 -76
- package/dist/modules/user/enums/user-role.enum.d.ts +0 -4
- package/dist/modules/user/enums/user-role.enum.js +0 -8
package/dist/kafka/client-ids.js
CHANGED
|
@@ -5,7 +5,5 @@ exports.CLIENT_IDS = {
|
|
|
5
5
|
API_GATEWAY: 'api-gateway',
|
|
6
6
|
AUTH_SERVICE: 'auth-service',
|
|
7
7
|
ORGANIZATION_SERVICE: 'organization-service',
|
|
8
|
-
EMAIL_SERVICE: 'email-service'
|
|
9
|
-
INCIDENT_SERVICE: 'incident-service',
|
|
10
|
-
NOTIFICATION_SERVICE: 'notification-service',
|
|
8
|
+
EMAIL_SERVICE: 'email-service'
|
|
11
9
|
};
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
export interface OTPPayload {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
email: string;
|
|
5
|
-
phoneNumber: string;
|
|
6
|
-
verificationToken: string;
|
|
7
|
-
verificationTokenExpiresAt: Date;
|
|
2
|
+
userId: number;
|
|
3
|
+
token: string;
|
|
8
4
|
otp: string;
|
|
9
5
|
otpExpiresAt: Date;
|
|
6
|
+
email: string;
|
|
7
|
+
phoneNumber: string;
|
|
10
8
|
attributes: Record<string, any>;
|
|
11
9
|
}
|
package/dist/kafka/topics.d.ts
CHANGED
package/dist/kafka/topics.js
CHANGED
|
@@ -9,30 +9,28 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
12
|
+
exports.CreateIncidentActionDto = void 0;
|
|
13
13
|
const class_validator_1 = require("class-validator");
|
|
14
|
-
|
|
15
|
-
class ContactPersonDto {
|
|
14
|
+
class CreateIncidentActionDto {
|
|
16
15
|
}
|
|
17
|
-
exports.
|
|
16
|
+
exports.CreateIncidentActionDto = CreateIncidentActionDto;
|
|
18
17
|
__decorate([
|
|
19
|
-
(0, class_validator_1.
|
|
20
|
-
(0, case_decorators_1.SentenceCase)(),
|
|
18
|
+
(0, class_validator_1.IsNumber)(),
|
|
21
19
|
(0, class_validator_1.IsNotEmpty)(),
|
|
22
|
-
__metadata("design:type",
|
|
23
|
-
],
|
|
20
|
+
__metadata("design:type", Number)
|
|
21
|
+
], CreateIncidentActionDto.prototype, "incidentId", void 0);
|
|
24
22
|
__decorate([
|
|
25
|
-
(0, class_validator_1.
|
|
26
|
-
(0, class_validator_1.
|
|
27
|
-
__metadata("design:type",
|
|
28
|
-
],
|
|
23
|
+
(0, class_validator_1.IsNumber)(),
|
|
24
|
+
(0, class_validator_1.IsOptional)(),
|
|
25
|
+
__metadata("design:type", Number)
|
|
26
|
+
], CreateIncidentActionDto.prototype, "userId", void 0);
|
|
29
27
|
__decorate([
|
|
30
|
-
(0, class_validator_1.
|
|
28
|
+
(0, class_validator_1.IsString)(),
|
|
31
29
|
(0, class_validator_1.IsNotEmpty)(),
|
|
32
30
|
__metadata("design:type", String)
|
|
33
|
-
],
|
|
31
|
+
], CreateIncidentActionDto.prototype, "action", void 0);
|
|
34
32
|
__decorate([
|
|
35
|
-
(0, class_validator_1.
|
|
33
|
+
(0, class_validator_1.IsDate)(),
|
|
36
34
|
(0, class_validator_1.IsNotEmpty)(),
|
|
37
|
-
__metadata("design:type",
|
|
38
|
-
],
|
|
35
|
+
__metadata("design:type", Date)
|
|
36
|
+
], CreateIncidentActionDto.prototype, "timestamp", void 0);
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
timestamp:
|
|
1
|
+
import { CreateIncidentActionDto } from "./create-incident-action.dto";
|
|
2
|
+
declare const IncidentActionDto_base: import("@nestjs/mapped-types").MappedType<Omit<CreateIncidentActionDto, "timestamp">>;
|
|
3
|
+
export declare class IncidentActionDto extends IncidentActionDto_base {
|
|
4
|
+
id: number;
|
|
5
|
+
timestamp: string;
|
|
6
6
|
}
|
|
7
|
+
export {};
|
|
@@ -10,27 +10,19 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.IncidentActionDto = void 0;
|
|
13
|
+
const mapped_types_1 = require("@nestjs/mapped-types");
|
|
14
|
+
const create_incident_action_dto_1 = require("./create-incident-action.dto");
|
|
13
15
|
const class_validator_1 = require("class-validator");
|
|
14
|
-
class IncidentActionDto {
|
|
16
|
+
class IncidentActionDto extends (0, mapped_types_1.OmitType)(create_incident_action_dto_1.CreateIncidentActionDto, ['timestamp']) {
|
|
15
17
|
}
|
|
16
18
|
exports.IncidentActionDto = IncidentActionDto;
|
|
17
19
|
__decorate([
|
|
18
20
|
(0, class_validator_1.IsNumber)(),
|
|
19
21
|
(0, class_validator_1.IsNotEmpty)(),
|
|
20
22
|
__metadata("design:type", Number)
|
|
21
|
-
], IncidentActionDto.prototype, "
|
|
23
|
+
], IncidentActionDto.prototype, "id", void 0);
|
|
22
24
|
__decorate([
|
|
23
|
-
(0, class_validator_1.
|
|
24
|
-
(0, class_validator_1.IsOptional)(),
|
|
25
|
-
__metadata("design:type", Number)
|
|
26
|
-
], IncidentActionDto.prototype, "userId", void 0);
|
|
27
|
-
__decorate([
|
|
28
|
-
(0, class_validator_1.IsString)(),
|
|
25
|
+
(0, class_validator_1.IsDateString)(),
|
|
29
26
|
(0, class_validator_1.IsNotEmpty)(),
|
|
30
27
|
__metadata("design:type", String)
|
|
31
|
-
], IncidentActionDto.prototype, "action", void 0);
|
|
32
|
-
__decorate([
|
|
33
|
-
(0, class_validator_1.IsDate)(),
|
|
34
|
-
(0, class_validator_1.IsNotEmpty)(),
|
|
35
|
-
__metadata("design:type", Date)
|
|
36
28
|
], IncidentActionDto.prototype, "timestamp", void 0);
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { CreateIncidentActionDto } from "./create-incident-action.dto";
|
|
2
|
+
declare const UpdateIncidentActionDto_base: import("@nestjs/mapped-types").MappedType<Partial<CreateIncidentActionDto>>;
|
|
3
|
+
export declare class UpdateIncidentActionDto extends UpdateIncidentActionDto_base {
|
|
4
|
+
}
|
|
5
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UpdateIncidentActionDto = void 0;
|
|
4
|
+
const mapped_types_1 = require("@nestjs/mapped-types");
|
|
5
|
+
const create_incident_action_dto_1 = require("./create-incident-action.dto");
|
|
6
|
+
class UpdateIncidentActionDto extends (0, mapped_types_1.PartialType)(create_incident_action_dto_1.CreateIncidentActionDto) {
|
|
7
|
+
}
|
|
8
|
+
exports.UpdateIncidentActionDto = UpdateIncidentActionDto;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { CreateIncidentDto } from "./create-incident.dto";
|
|
2
2
|
import { CreateIncidentCategoryDto } from "../category/create-incident-category.dto";
|
|
3
3
|
import { CreateIncidentTypeDto } from "../type/create-incident-type.dto";
|
|
4
|
-
import {
|
|
4
|
+
import { IncidentActionDto } from "../action/incident-action.dto";
|
|
5
5
|
export declare class IncidentDto extends CreateIncidentDto {
|
|
6
6
|
id: number;
|
|
7
|
-
createdAt: string;
|
|
8
|
-
updatedAt: string;
|
|
9
7
|
category?: CreateIncidentCategoryDto;
|
|
10
8
|
type?: CreateIncidentTypeDto;
|
|
11
|
-
actions?:
|
|
9
|
+
actions?: IncidentActionDto[];
|
|
10
|
+
createdAt: string;
|
|
11
|
+
updatedAt: string;
|
|
12
12
|
}
|
|
@@ -15,6 +15,7 @@ const create_incident_dto_1 = require("./create-incident.dto");
|
|
|
15
15
|
const class_transformer_1 = require("class-transformer");
|
|
16
16
|
const create_incident_category_dto_1 = require("../category/create-incident-category.dto");
|
|
17
17
|
const create_incident_type_dto_1 = require("../type/create-incident-type.dto");
|
|
18
|
+
const incident_action_dto_1 = require("../action/incident-action.dto");
|
|
18
19
|
class IncidentDto extends create_incident_dto_1.CreateIncidentDto {
|
|
19
20
|
}
|
|
20
21
|
exports.IncidentDto = IncidentDto;
|
|
@@ -23,16 +24,6 @@ __decorate([
|
|
|
23
24
|
(0, class_validator_1.IsNotEmpty)(),
|
|
24
25
|
__metadata("design:type", Number)
|
|
25
26
|
], IncidentDto.prototype, "id", void 0);
|
|
26
|
-
__decorate([
|
|
27
|
-
(0, class_validator_1.IsDateString)(),
|
|
28
|
-
(0, class_validator_1.IsNotEmpty)(),
|
|
29
|
-
__metadata("design:type", String)
|
|
30
|
-
], IncidentDto.prototype, "createdAt", void 0);
|
|
31
|
-
__decorate([
|
|
32
|
-
(0, class_validator_1.IsDateString)(),
|
|
33
|
-
(0, class_validator_1.IsNotEmpty)(),
|
|
34
|
-
__metadata("design:type", String)
|
|
35
|
-
], IncidentDto.prototype, "updatedAt", void 0);
|
|
36
27
|
__decorate([
|
|
37
28
|
(0, class_validator_1.ValidateNested)(),
|
|
38
29
|
(0, class_transformer_1.Type)(() => create_incident_category_dto_1.CreateIncidentCategoryDto),
|
|
@@ -46,7 +37,19 @@ __decorate([
|
|
|
46
37
|
__metadata("design:type", create_incident_type_dto_1.CreateIncidentTypeDto)
|
|
47
38
|
], IncidentDto.prototype, "type", void 0);
|
|
48
39
|
__decorate([
|
|
49
|
-
(0, class_validator_1.IsArray)(),
|
|
50
40
|
(0, class_validator_1.IsOptional)(),
|
|
41
|
+
(0, class_validator_1.IsArray)(),
|
|
42
|
+
(0, class_validator_1.ValidateNested)({ each: true }),
|
|
43
|
+
(0, class_transformer_1.Type)(() => incident_action_dto_1.IncidentActionDto),
|
|
51
44
|
__metadata("design:type", Array)
|
|
52
45
|
], IncidentDto.prototype, "actions", void 0);
|
|
46
|
+
__decorate([
|
|
47
|
+
(0, class_validator_1.IsDateString)(),
|
|
48
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
49
|
+
__metadata("design:type", String)
|
|
50
|
+
], IncidentDto.prototype, "createdAt", void 0);
|
|
51
|
+
__decorate([
|
|
52
|
+
(0, class_validator_1.IsDateString)(),
|
|
53
|
+
(0, class_validator_1.IsNotEmpty)(),
|
|
54
|
+
__metadata("design:type", String)
|
|
55
|
+
], IncidentDto.prototype, "updatedAt", void 0);
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
export * from './dtos/action/incident-action.dto';
|
|
2
|
+
export * from './dtos/action/create-incident-action.dto';
|
|
3
|
+
export * from './dtos/action/update-inident-action.dto';
|
|
2
4
|
export * from './dtos/attachment/create-incident-attachment.dto';
|
|
3
5
|
export * from './dtos/attachment/update-incident-attachment.dto';
|
|
4
6
|
export * from './dtos/category/create-incident-category.dto';
|
|
@@ -16,6 +16,8 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
// Dtos
|
|
18
18
|
__exportStar(require("./dtos/action/incident-action.dto"), exports);
|
|
19
|
+
__exportStar(require("./dtos/action/create-incident-action.dto"), exports);
|
|
20
|
+
__exportStar(require("./dtos/action/update-inident-action.dto"), exports);
|
|
19
21
|
__exportStar(require("./dtos/attachment/create-incident-attachment.dto"), exports);
|
|
20
22
|
__exportStar(require("./dtos/attachment/update-incident-attachment.dto"), exports);
|
|
21
23
|
__exportStar(require("./dtos/category/create-incident-category.dto"), exports);
|
package/package.json
CHANGED
|
@@ -1,43 +1,43 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "grm-shared-library",
|
|
3
|
-
"version": "1.0.
|
|
4
|
-
"main": "dist/index.js",
|
|
5
|
-
"types": "dist/index.d.ts",
|
|
6
|
-
"files": [
|
|
7
|
-
"dist/**/*"
|
|
8
|
-
],
|
|
9
|
-
"scripts": {
|
|
10
|
-
"build": "tsc",
|
|
11
|
-
"test": "echo \"Error: no test specified\" && exit 1"
|
|
12
|
-
},
|
|
13
|
-
"keywords": [],
|
|
14
|
-
"author": "",
|
|
15
|
-
"license": "ISC",
|
|
16
|
-
"description": "",
|
|
17
|
-
"publishConfig": {
|
|
18
|
-
"access": "public"
|
|
19
|
-
},
|
|
20
|
-
"devDependencies": {
|
|
21
|
-
"@types/node": "^22.10.5",
|
|
22
|
-
"typescript": "^5.7.3"
|
|
23
|
-
},
|
|
24
|
-
"dependencies": {
|
|
25
|
-
"@nestjs/common": "^11.0.6",
|
|
26
|
-
"@nestjs/core": "^11.0.6",
|
|
27
|
-
"@nestjs/mapped-types": "^2.0.6",
|
|
28
|
-
"@nestjs/microservices": "^11.0.6",
|
|
29
|
-
"@sentry/node": "^8.52.0",
|
|
30
|
-
"class-transformer": "^0.5.1",
|
|
31
|
-
"class-validator": "^0.14.1",
|
|
32
|
-
"rxjs": "^7.8.1"
|
|
33
|
-
},
|
|
34
|
-
"peerDependencies": {
|
|
35
|
-
"@nestjs/common": "^11.0.0",
|
|
36
|
-
"@nestjs/core": "^11.0.0",
|
|
37
|
-
"@nestjs/microservices": "^11.0.0",
|
|
38
|
-
"@sentry/node": "^8.0.0",
|
|
39
|
-
"rxjs": "^7.8.0",
|
|
40
|
-
"class-transformer": "^0.5.0",
|
|
41
|
-
"class-validator": "^0.14.0"
|
|
42
|
-
}
|
|
43
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "grm-shared-library",
|
|
3
|
+
"version": "1.0.152",
|
|
4
|
+
"main": "dist/index.js",
|
|
5
|
+
"types": "dist/index.d.ts",
|
|
6
|
+
"files": [
|
|
7
|
+
"dist/**/*"
|
|
8
|
+
],
|
|
9
|
+
"scripts": {
|
|
10
|
+
"build": "tsc",
|
|
11
|
+
"test": "echo \"Error: no test specified\" && exit 1"
|
|
12
|
+
},
|
|
13
|
+
"keywords": [],
|
|
14
|
+
"author": "",
|
|
15
|
+
"license": "ISC",
|
|
16
|
+
"description": "",
|
|
17
|
+
"publishConfig": {
|
|
18
|
+
"access": "public"
|
|
19
|
+
},
|
|
20
|
+
"devDependencies": {
|
|
21
|
+
"@types/node": "^22.10.5",
|
|
22
|
+
"typescript": "^5.7.3"
|
|
23
|
+
},
|
|
24
|
+
"dependencies": {
|
|
25
|
+
"@nestjs/common": "^11.0.6",
|
|
26
|
+
"@nestjs/core": "^11.0.6",
|
|
27
|
+
"@nestjs/mapped-types": "^2.0.6",
|
|
28
|
+
"@nestjs/microservices": "^11.0.6",
|
|
29
|
+
"@sentry/node": "^8.52.0",
|
|
30
|
+
"class-transformer": "^0.5.1",
|
|
31
|
+
"class-validator": "^0.14.1",
|
|
32
|
+
"rxjs": "^7.8.1"
|
|
33
|
+
},
|
|
34
|
+
"peerDependencies": {
|
|
35
|
+
"@nestjs/common": "^11.0.0",
|
|
36
|
+
"@nestjs/core": "^11.0.0",
|
|
37
|
+
"@nestjs/microservices": "^11.0.0",
|
|
38
|
+
"@sentry/node": "^8.0.0",
|
|
39
|
+
"rxjs": "^7.8.0",
|
|
40
|
+
"class-transformer": "^0.5.0",
|
|
41
|
+
"class-validator": "^0.14.0"
|
|
42
|
+
}
|
|
43
|
+
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
export interface UserCreatedPayload {
|
|
2
|
-
id: number;
|
|
3
|
-
firstName: string;
|
|
4
|
-
lastName: string;
|
|
5
|
-
email: string;
|
|
6
|
-
phoneNumber: string;
|
|
7
|
-
roles: string[];
|
|
8
|
-
otp: string;
|
|
9
|
-
otpExpiresAt: Date;
|
|
10
|
-
verificationToken: string;
|
|
11
|
-
createdAt: Date;
|
|
12
|
-
attributes: Record<string, any>;
|
|
13
|
-
}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
export declare const KAFKA_TOPICS: {
|
|
2
|
-
USER_REGISTERED: string;
|
|
3
|
-
USER_LOGGED_IN: string;
|
|
4
|
-
USER_LOGGED_OUT: string;
|
|
5
|
-
USER_CREATED: string;
|
|
6
|
-
USER_UPDATED: string;
|
|
7
|
-
USER_DELETED: string;
|
|
8
|
-
ORG_CREATED: string;
|
|
9
|
-
ORG_UPDATED: string;
|
|
10
|
-
ORG_DELETED: string;
|
|
11
|
-
OTP_VALIDATED: string;
|
|
12
|
-
OTP_REQUESTED: string;
|
|
13
|
-
};
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.KAFKA_TOPICS = void 0;
|
|
4
|
-
exports.KAFKA_TOPICS = {
|
|
5
|
-
// Auth
|
|
6
|
-
USER_REGISTERED: 'user.registered',
|
|
7
|
-
USER_LOGGED_IN: 'user.logged.in',
|
|
8
|
-
USER_LOGGED_OUT: 'user.logged.out',
|
|
9
|
-
// User
|
|
10
|
-
USER_CREATED: 'user.created',
|
|
11
|
-
USER_UPDATED: 'user.updated',
|
|
12
|
-
USER_DELETED: 'user.deleted',
|
|
13
|
-
// Org
|
|
14
|
-
ORG_CREATED: 'org.created',
|
|
15
|
-
ORG_UPDATED: 'org.updated',
|
|
16
|
-
ORG_DELETED: 'org.deleted',
|
|
17
|
-
// OTP
|
|
18
|
-
OTP_VALIDATED: 'otp.validated',
|
|
19
|
-
OTP_REQUESTED: 'otp.requested'
|
|
20
|
-
};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
export declare const KAFKA_TOPICS: {
|
|
2
|
-
USER_REGISTERED: string;
|
|
3
|
-
USER_LOGGED_IN: string;
|
|
4
|
-
USER_LOGGED_OUT: string;
|
|
5
|
-
USER_CREATED: string;
|
|
6
|
-
USER_UPDATED: string;
|
|
7
|
-
USER_DELETED: string;
|
|
8
|
-
ORG_CREATED: string;
|
|
9
|
-
ORG_UPDATED: string;
|
|
10
|
-
ORG_DELETED: string;
|
|
11
|
-
OTP_VALIDATED: string;
|
|
12
|
-
OTP_REQUESTED: string;
|
|
13
|
-
};
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.KAFKA_TOPICS = void 0;
|
|
4
|
-
exports.KAFKA_TOPICS = {
|
|
5
|
-
// Auth
|
|
6
|
-
USER_REGISTERED: 'user.registered',
|
|
7
|
-
USER_LOGGED_IN: 'user.logged.in',
|
|
8
|
-
USER_LOGGED_OUT: 'user.logged.out',
|
|
9
|
-
// User
|
|
10
|
-
USER_CREATED: 'user.created',
|
|
11
|
-
USER_UPDATED: 'user.updated',
|
|
12
|
-
USER_DELETED: 'user.deleted',
|
|
13
|
-
// Org
|
|
14
|
-
ORG_CREATED: 'org.created',
|
|
15
|
-
ORG_UPDATED: 'org.updated',
|
|
16
|
-
ORG_DELETED: 'org.deleted',
|
|
17
|
-
// OTP
|
|
18
|
-
OTP_VALIDATED: 'otp.validated',
|
|
19
|
-
OTP_REQUESTED: 'otp.requested'
|
|
20
|
-
};
|
|
@@ -1,33 +0,0 @@
|
|
|
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.SetPasswordDto = void 0;
|
|
13
|
-
const class_validator_1 = require("class-validator");
|
|
14
|
-
const match_decorator_1 = require("../validators/match.decorator");
|
|
15
|
-
const password_regex_const_1 = require("../../common/constants/password-regex.const");
|
|
16
|
-
class SetPasswordDto {
|
|
17
|
-
}
|
|
18
|
-
exports.SetPasswordDto = SetPasswordDto;
|
|
19
|
-
__decorate([
|
|
20
|
-
(0, class_validator_1.IsString)(),
|
|
21
|
-
(0, class_validator_1.IsNotEmpty)(),
|
|
22
|
-
(0, class_validator_1.MinLength)(8),
|
|
23
|
-
(0, class_validator_1.Matches)(password_regex_const_1.PASSWORD_REGEX, { message: password_regex_const_1.PASSWORD_ERROR_MESSAGE }),
|
|
24
|
-
__metadata("design:type", String)
|
|
25
|
-
], SetPasswordDto.prototype, "password", void 0);
|
|
26
|
-
__decorate([
|
|
27
|
-
(0, class_validator_1.IsString)(),
|
|
28
|
-
(0, class_validator_1.IsNotEmpty)(),
|
|
29
|
-
(0, class_validator_1.MinLength)(8),
|
|
30
|
-
(0, class_validator_1.Matches)(password_regex_const_1.PASSWORD_REGEX, { message: password_regex_const_1.PASSWORD_ERROR_MESSAGE }),
|
|
31
|
-
(0, match_decorator_1.Match)('password', { message: 'Passwords do not match' }),
|
|
32
|
-
__metadata("design:type", String)
|
|
33
|
-
], SetPasswordDto.prototype, "confirmPassword", void 0);
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.SERVICE_NAMES = void 0;
|
|
4
|
-
exports.SERVICE_NAMES = {
|
|
5
|
-
API_GATEWAY: 'api-gateway',
|
|
6
|
-
AUTH_SERVICE: 'auth-service',
|
|
7
|
-
ORGANIZATION_SERVICE: 'organization-service',
|
|
8
|
-
EMAIL_SERVICE: 'email-service',
|
|
9
|
-
INCIDENT_SERVICE: 'incident-service',
|
|
10
|
-
NOTIFICATION_SERVICE: 'notification-service',
|
|
11
|
-
};
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { MapAddressDto } from "../../common";
|
|
2
|
-
import { Organization } from "./organization";
|
|
3
|
-
export interface Partner {
|
|
4
|
-
id?: number;
|
|
5
|
-
name: string;
|
|
6
|
-
phoneNumber?: string;
|
|
7
|
-
email?: string;
|
|
8
|
-
physicalAddress: MapAddressDto;
|
|
9
|
-
website: string;
|
|
10
|
-
type: string;
|
|
11
|
-
description?: string;
|
|
12
|
-
status: string;
|
|
13
|
-
logo?: string;
|
|
14
|
-
organization: Organization;
|
|
15
|
-
createdAt?: Date;
|
|
16
|
-
updatedAt?: Date;
|
|
17
|
-
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { MapAddressDto } from "../../common/dtos/map-address.dto";
|
|
2
|
-
import { ContactPersonDto } from "../../common/dtos/contact-person.dto";
|
|
3
|
-
export declare class CreatePartnerDto {
|
|
4
|
-
organizationId: number;
|
|
5
|
-
name: string;
|
|
6
|
-
phoneNumber?: string;
|
|
7
|
-
email?: string;
|
|
8
|
-
physicalAddress: MapAddressDto;
|
|
9
|
-
website: string;
|
|
10
|
-
type: string;
|
|
11
|
-
description?: string;
|
|
12
|
-
status: string;
|
|
13
|
-
logo?: string;
|
|
14
|
-
contactPerson: ContactPersonDto;
|
|
15
|
-
controlCentreIds?: number[];
|
|
16
|
-
}
|