@platform-modules/civil-aviation-authority 2.2.86 → 2.2.87
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/.env +10 -4
- package/dist/data-source.js +10 -10
- package/dist/index.d.ts +5 -5
- package/dist/index.js +5 -5
- package/dist/models/AccessCardChatModel.d.ts +4 -1
- package/dist/models/AccessCardChatModel.js +16 -5
- package/dist/models/AccessCardWorkflowModel.d.ts +5 -1
- package/dist/models/AccessCardWorkflowModel.js +22 -2
- package/dist/models/LogisticsWorkflowModel.d.ts +5 -1
- package/dist/models/LogisticsWorkflowModel.js +22 -2
- package/dist/models/{AirportEntryPermitApprovalModel.d.ts → SecurityAwarenessApprovalModel.d.ts} +4 -4
- package/dist/models/{AirportEntryPermitApprovalModel.js → SecurityAwarenessApprovalModel.js} +27 -27
- package/dist/models/SecurityAwarenessAttachmentModel.d.ts +12 -0
- package/dist/models/{AirportEntryPermitAttachmentModel.js → SecurityAwarenessAttachmentModel.js} +16 -26
- package/dist/models/SecurityAwarenessChatModel.d.ts +20 -0
- package/dist/models/SecurityAwarenessChatModel.js +78 -0
- package/dist/models/SecurityAwarenessRequestModel.d.ts +29 -0
- package/dist/models/SecurityAwarenessRequestModel.js +117 -0
- package/dist/models/SecurityAwarenessWorkflowModel.d.ts +18 -0
- package/dist/models/SecurityAwarenessWorkflowModel.js +76 -0
- package/dist/models/SecurityThreatApprovalModel.js +1 -1
- package/dist/models/SecurityThreatChatModel.d.ts +4 -1
- package/dist/models/SecurityThreatChatModel.js +13 -2
- package/dist/models/SecurityThreatWorkflowModel.d.ts +5 -1
- package/dist/models/SecurityThreatWorkflowModel.js +22 -2
- package/dist/models/VpnRequestChatModel.d.ts +2 -1
- package/dist/models/VpnRequestChatModel.js +7 -2
- package/dist/models/VpnWorkflowModel.d.ts +4 -1
- package/dist/models/VpnWorkflowModel.js +17 -2
- package/package.json +1 -1
- package/src/data-source.ts +10 -10
- package/src/index.ts +5 -5
- package/src/models/AccessCardChatModel.ts +15 -4
- package/src/models/AccessCardWorkflowModel.ts +21 -1
- package/src/models/LogisticsWorkflowModel.ts +21 -1
- package/src/models/{AirportEntryPermitApprovalModel.ts → SecurityAwarenessApprovalModel.ts} +11 -10
- package/src/models/SecurityAwarenessAttachmentModel.ts +52 -0
- package/src/models/SecurityAwarenessChatModel.ts +66 -0
- package/src/models/SecurityAwarenessRequestModel.ts +105 -0
- package/src/models/SecurityAwarenessWorkflowModel.ts +63 -0
- package/src/models/SecurityThreatApprovalModel.ts +1 -1
- package/src/models/SecurityThreatChatModel.ts +12 -1
- package/src/models/SecurityThreatWorkflowModel.ts +21 -1
- package/src/models/VpnRequestChatModel.ts +6 -1
- package/src/models/VpnWorkflowModel.ts +16 -1
- package/dist/models/AirportEntryPermitAttachmentModel.d.ts +0 -14
- package/dist/models/AirportEntryPermitChatModel.d.ts +0 -17
- package/dist/models/AirportEntryPermitChatModel.js +0 -67
- package/dist/models/AirportEntryPermitModel.d.ts +0 -75
- package/dist/models/AirportEntryPermitModel.js +0 -253
- package/dist/models/AirportEntryPermitWorkflowModel.d.ts +0 -14
- package/dist/models/AirportEntryPermitWorkflowModel.js +0 -55
- package/dist/models/HotelreservationModal.d.ts +0 -30
- package/dist/models/HotelreservationModal.js +0 -119
- package/src/models/AirportEntryPermitAttachmentModel.ts +0 -62
- package/src/models/AirportEntryPermitChatModel.ts +0 -55
- package/src/models/AirportEntryPermitModel.ts +0 -246
- package/src/models/AirportEntryPermitWorkflowModel.ts +0 -42
package/.env
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
|
-
DB_HOST=localhost
|
|
2
|
-
DB_PORT=5433
|
|
3
|
-
DB_USER=postgres
|
|
4
|
-
DB_PASS=123
|
|
1
|
+
# DB_HOST=localhost
|
|
2
|
+
# DB_PORT=5433
|
|
3
|
+
# DB_USER=postgres
|
|
4
|
+
# DB_PASS=123
|
|
5
|
+
# DB_NAME=CAA
|
|
6
|
+
|
|
7
|
+
DB_HOST=164.52.222.169
|
|
8
|
+
DB_PORT=5432
|
|
9
|
+
DB_USER=postgres_admin_user
|
|
10
|
+
DB_PASS=pg_admin_user_pwd_caa_fa_$%^&OIukhjgcvbn
|
|
5
11
|
DB_NAME=CAA
|
package/dist/data-source.js
CHANGED
|
@@ -64,11 +64,11 @@ const SecurityThreatApprovalModel_1 = require("./models/SecurityThreatApprovalMo
|
|
|
64
64
|
const SecurityThreatAttachmentModel_1 = require("./models/SecurityThreatAttachmentModel");
|
|
65
65
|
const SecurityThreatChatModel_1 = require("./models/SecurityThreatChatModel");
|
|
66
66
|
const SecurityThreatWorkflowModel_1 = require("./models/SecurityThreatWorkflowModel");
|
|
67
|
-
const
|
|
68
|
-
const
|
|
69
|
-
const
|
|
70
|
-
const
|
|
71
|
-
const
|
|
67
|
+
const SecurityAwarenessRequestModel_1 = require("./models/SecurityAwarenessRequestModel");
|
|
68
|
+
const SecurityAwarenessApprovalModel_1 = require("./models/SecurityAwarenessApprovalModel");
|
|
69
|
+
const SecurityAwarenessAttachmentModel_1 = require("./models/SecurityAwarenessAttachmentModel");
|
|
70
|
+
const SecurityAwarenessChatModel_1 = require("./models/SecurityAwarenessChatModel");
|
|
71
|
+
const SecurityAwarenessWorkflowModel_1 = require("./models/SecurityAwarenessWorkflowModel");
|
|
72
72
|
exports.AppDataSource = new typeorm_1.DataSource({
|
|
73
73
|
type: 'postgres',
|
|
74
74
|
host: process.env.DB_HOST || 'localhost',
|
|
@@ -137,10 +137,10 @@ exports.AppDataSource = new typeorm_1.DataSource({
|
|
|
137
137
|
SecurityThreatAttachmentModel_1.SecurityThreatAttachment,
|
|
138
138
|
SecurityThreatChatModel_1.SecurityThreatChat,
|
|
139
139
|
SecurityThreatWorkflowModel_1.SecurityThreatWorkFlow,
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
140
|
+
SecurityAwarenessRequestModel_1.SecurityAwarenessRequest,
|
|
141
|
+
SecurityAwarenessApprovalModel_1.SecurityAwarenessApproval,
|
|
142
|
+
SecurityAwarenessAttachmentModel_1.SecurityAwarenessAttachment,
|
|
143
|
+
SecurityAwarenessChatModel_1.SecurityAwarenessChat,
|
|
144
|
+
SecurityAwarenessWorkflowModel_1.SecurityAwarenessWorkFlow
|
|
145
145
|
],
|
|
146
146
|
});
|
package/dist/index.d.ts
CHANGED
|
@@ -53,8 +53,8 @@ export * from './models/SecurityThreatApprovalModel';
|
|
|
53
53
|
export * from './models/SecurityThreatAttachmentModel';
|
|
54
54
|
export * from './models/SecurityThreatChatModel';
|
|
55
55
|
export * from './models/SecurityThreatWorkflowModel';
|
|
56
|
-
export * from './models/
|
|
57
|
-
export * from './models/
|
|
58
|
-
export * from './models/
|
|
59
|
-
export * from './models/
|
|
60
|
-
export * from './models/
|
|
56
|
+
export * from './models/SecurityAwarenessRequestModel';
|
|
57
|
+
export * from './models/SecurityAwarenessApprovalModel';
|
|
58
|
+
export * from './models/SecurityAwarenessAttachmentModel';
|
|
59
|
+
export * from './models/SecurityAwarenessChatModel';
|
|
60
|
+
export * from './models/SecurityAwarenessWorkflowModel';
|
package/dist/index.js
CHANGED
|
@@ -73,8 +73,8 @@ __exportStar(require("./models/SecurityThreatApprovalModel"), exports);
|
|
|
73
73
|
__exportStar(require("./models/SecurityThreatAttachmentModel"), exports);
|
|
74
74
|
__exportStar(require("./models/SecurityThreatChatModel"), exports);
|
|
75
75
|
__exportStar(require("./models/SecurityThreatWorkflowModel"), exports);
|
|
76
|
-
__exportStar(require("./models/
|
|
77
|
-
__exportStar(require("./models/
|
|
78
|
-
__exportStar(require("./models/
|
|
79
|
-
__exportStar(require("./models/
|
|
80
|
-
__exportStar(require("./models/
|
|
76
|
+
__exportStar(require("./models/SecurityAwarenessRequestModel"), exports);
|
|
77
|
+
__exportStar(require("./models/SecurityAwarenessApprovalModel"), exports);
|
|
78
|
+
__exportStar(require("./models/SecurityAwarenessAttachmentModel"), exports);
|
|
79
|
+
__exportStar(require("./models/SecurityAwarenessChatModel"), exports);
|
|
80
|
+
__exportStar(require("./models/SecurityAwarenessWorkflowModel"), exports);
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { BaseModel } from "./BaseModel";
|
|
2
|
+
import { AccessCardApprovalStatus } from "./AccessCardApprovalModel";
|
|
2
3
|
export declare enum AccessCardMessageType {
|
|
3
4
|
TEXT = "text",
|
|
4
5
|
IMAGE = "image",
|
|
@@ -11,7 +12,9 @@ export declare class AccessCardRequestChat extends BaseModel {
|
|
|
11
12
|
service_id: number | null;
|
|
12
13
|
sub_service_id: number | null;
|
|
13
14
|
user_id: number;
|
|
15
|
+
role_id: number;
|
|
14
16
|
message: string;
|
|
15
17
|
messageType: AccessCardMessageType;
|
|
16
|
-
|
|
18
|
+
status: AccessCardApprovalStatus;
|
|
19
|
+
constructor(request_id: number, user_id: number, role_id: number, message: string, service_id?: number, sub_service_id?: number, messageType?: AccessCardMessageType, status?: AccessCardApprovalStatus);
|
|
17
20
|
}
|
|
@@ -12,6 +12,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
12
12
|
exports.AccessCardRequestChat = exports.AccessCardMessageType = void 0;
|
|
13
13
|
const typeorm_1 = require("typeorm");
|
|
14
14
|
const BaseModel_1 = require("./BaseModel");
|
|
15
|
+
const AccessCardApprovalModel_1 = require("./AccessCardApprovalModel");
|
|
15
16
|
var AccessCardMessageType;
|
|
16
17
|
(function (AccessCardMessageType) {
|
|
17
18
|
AccessCardMessageType["TEXT"] = "text";
|
|
@@ -21,14 +22,16 @@ var AccessCardMessageType;
|
|
|
21
22
|
AccessCardMessageType["LINK"] = "link";
|
|
22
23
|
})(AccessCardMessageType || (exports.AccessCardMessageType = AccessCardMessageType = {}));
|
|
23
24
|
let AccessCardRequestChat = class AccessCardRequestChat extends BaseModel_1.BaseModel {
|
|
24
|
-
constructor(request_id, user_id, message, service_id, sub_service_id, messageType) {
|
|
25
|
+
constructor(request_id, user_id, role_id, message, service_id, sub_service_id, messageType, status) {
|
|
25
26
|
super();
|
|
26
27
|
this.request_id = request_id;
|
|
27
|
-
this.service_id = service_id
|
|
28
|
-
this.sub_service_id = sub_service_id
|
|
28
|
+
this.service_id = service_id || null;
|
|
29
|
+
this.sub_service_id = sub_service_id || null;
|
|
29
30
|
this.user_id = user_id;
|
|
31
|
+
this.role_id = role_id;
|
|
30
32
|
this.message = message;
|
|
31
|
-
this.messageType = messageType
|
|
33
|
+
this.messageType = messageType || AccessCardMessageType.TEXT;
|
|
34
|
+
this.status = status || AccessCardApprovalModel_1.AccessCardApprovalStatus.PENDING;
|
|
32
35
|
}
|
|
33
36
|
};
|
|
34
37
|
exports.AccessCardRequestChat = AccessCardRequestChat;
|
|
@@ -48,6 +51,10 @@ __decorate([
|
|
|
48
51
|
(0, typeorm_1.Column)({ type: "integer", nullable: false }),
|
|
49
52
|
__metadata("design:type", Number)
|
|
50
53
|
], AccessCardRequestChat.prototype, "user_id", void 0);
|
|
54
|
+
__decorate([
|
|
55
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
56
|
+
__metadata("design:type", Number)
|
|
57
|
+
], AccessCardRequestChat.prototype, "role_id", void 0);
|
|
51
58
|
__decorate([
|
|
52
59
|
(0, typeorm_1.Column)({ type: "text", nullable: false }),
|
|
53
60
|
__metadata("design:type", String)
|
|
@@ -61,7 +68,11 @@ __decorate([
|
|
|
61
68
|
}),
|
|
62
69
|
__metadata("design:type", String)
|
|
63
70
|
], AccessCardRequestChat.prototype, "messageType", void 0);
|
|
71
|
+
__decorate([
|
|
72
|
+
(0, typeorm_1.Column)({ type: 'enum', enum: AccessCardApprovalModel_1.AccessCardApprovalStatus, default: AccessCardApprovalModel_1.AccessCardApprovalStatus.PENDING, nullable: false }),
|
|
73
|
+
__metadata("design:type", String)
|
|
74
|
+
], AccessCardRequestChat.prototype, "status", void 0);
|
|
64
75
|
exports.AccessCardRequestChat = AccessCardRequestChat = __decorate([
|
|
65
76
|
(0, typeorm_1.Entity)({ name: "access_card_request_chat" }),
|
|
66
|
-
__metadata("design:paramtypes", [Number, Number, String, Number, Number, String])
|
|
77
|
+
__metadata("design:paramtypes", [Number, Number, Number, String, Number, Number, String, String])
|
|
67
78
|
], AccessCardRequestChat);
|
|
@@ -10,5 +10,9 @@ export declare class AccessCardWorkflow extends BaseModel {
|
|
|
10
10
|
sub_service_id: number | null;
|
|
11
11
|
content: string;
|
|
12
12
|
status: AccessCardWorkflowStatus;
|
|
13
|
-
|
|
13
|
+
user_id: number | null;
|
|
14
|
+
role_id: number | null;
|
|
15
|
+
department_id: number | null;
|
|
16
|
+
section_id: number | null;
|
|
17
|
+
constructor(request_id: number, content: string, status: AccessCardWorkflowStatus, service_id?: number, sub_service_id?: number, user_id?: number, role_id?: number, department_id?: number, section_id?: number);
|
|
14
18
|
}
|
|
@@ -19,13 +19,17 @@ var AccessCardWorkflowStatus;
|
|
|
19
19
|
AccessCardWorkflowStatus["PENDING"] = "Pending";
|
|
20
20
|
})(AccessCardWorkflowStatus || (exports.AccessCardWorkflowStatus = AccessCardWorkflowStatus = {}));
|
|
21
21
|
let AccessCardWorkflow = class AccessCardWorkflow extends BaseModel_1.BaseModel {
|
|
22
|
-
constructor(request_id, content, status, service_id, sub_service_id) {
|
|
22
|
+
constructor(request_id, content, status, service_id, sub_service_id, user_id, role_id, department_id, section_id) {
|
|
23
23
|
super();
|
|
24
24
|
this.request_id = request_id;
|
|
25
25
|
this.service_id = service_id ?? null;
|
|
26
26
|
this.sub_service_id = sub_service_id ?? null;
|
|
27
27
|
this.content = content;
|
|
28
28
|
this.status = status;
|
|
29
|
+
this.user_id = user_id ?? null;
|
|
30
|
+
this.role_id = role_id ?? null;
|
|
31
|
+
this.department_id = department_id ?? null;
|
|
32
|
+
this.section_id = section_id ?? null;
|
|
29
33
|
}
|
|
30
34
|
};
|
|
31
35
|
exports.AccessCardWorkflow = AccessCardWorkflow;
|
|
@@ -54,7 +58,23 @@ __decorate([
|
|
|
54
58
|
}),
|
|
55
59
|
__metadata("design:type", String)
|
|
56
60
|
], AccessCardWorkflow.prototype, "status", void 0);
|
|
61
|
+
__decorate([
|
|
62
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
63
|
+
__metadata("design:type", Object)
|
|
64
|
+
], AccessCardWorkflow.prototype, "user_id", void 0);
|
|
65
|
+
__decorate([
|
|
66
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
67
|
+
__metadata("design:type", Object)
|
|
68
|
+
], AccessCardWorkflow.prototype, "role_id", void 0);
|
|
69
|
+
__decorate([
|
|
70
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
71
|
+
__metadata("design:type", Object)
|
|
72
|
+
], AccessCardWorkflow.prototype, "department_id", void 0);
|
|
73
|
+
__decorate([
|
|
74
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
75
|
+
__metadata("design:type", Object)
|
|
76
|
+
], AccessCardWorkflow.prototype, "section_id", void 0);
|
|
57
77
|
exports.AccessCardWorkflow = AccessCardWorkflow = __decorate([
|
|
58
78
|
(0, typeorm_1.Entity)({ name: "access_card_workflows" }),
|
|
59
|
-
__metadata("design:paramtypes", [Number, String, String, Number, Number])
|
|
79
|
+
__metadata("design:paramtypes", [Number, String, String, Number, Number, Number, Number, Number, Number])
|
|
60
80
|
], AccessCardWorkflow);
|
|
@@ -10,5 +10,9 @@ export declare class LogisticsWorkFlow extends BaseModel {
|
|
|
10
10
|
sub_service_id: number | null;
|
|
11
11
|
content: string;
|
|
12
12
|
status: LogisticsWorkFlowStatus;
|
|
13
|
-
|
|
13
|
+
user_id: number | null;
|
|
14
|
+
role_id: number | null;
|
|
15
|
+
department_id: number | null;
|
|
16
|
+
section_id: number | null;
|
|
17
|
+
constructor(request_id: number, content: string, status: LogisticsWorkFlowStatus, service_id?: number, sub_service_id?: number, user_id?: number, role_id?: number, department_id?: number, section_id?: number);
|
|
14
18
|
}
|
|
@@ -20,13 +20,17 @@ var LogisticsWorkFlowStatus;
|
|
|
20
20
|
})(LogisticsWorkFlowStatus || (exports.LogisticsWorkFlowStatus = LogisticsWorkFlowStatus = {}));
|
|
21
21
|
//This model is used to store the logistics workflow status and activity logs
|
|
22
22
|
let LogisticsWorkFlow = class LogisticsWorkFlow extends BaseModel_1.BaseModel {
|
|
23
|
-
constructor(request_id, content, status, service_id, sub_service_id) {
|
|
23
|
+
constructor(request_id, content, status, service_id, sub_service_id, user_id, role_id, department_id, section_id) {
|
|
24
24
|
super();
|
|
25
25
|
this.request_id = request_id;
|
|
26
26
|
this.service_id = service_id || null;
|
|
27
27
|
this.sub_service_id = sub_service_id || null;
|
|
28
28
|
this.content = content;
|
|
29
29
|
this.status = status;
|
|
30
|
+
this.user_id = user_id || null;
|
|
31
|
+
this.role_id = role_id || null;
|
|
32
|
+
this.department_id = department_id || null;
|
|
33
|
+
this.section_id = section_id || null;
|
|
30
34
|
}
|
|
31
35
|
};
|
|
32
36
|
exports.LogisticsWorkFlow = LogisticsWorkFlow;
|
|
@@ -50,7 +54,23 @@ __decorate([
|
|
|
50
54
|
(0, typeorm_1.Column)({ type: 'enum', enum: LogisticsWorkFlowStatus, default: LogisticsWorkFlowStatus.NOT_YET_STARTED, nullable: false }),
|
|
51
55
|
__metadata("design:type", String)
|
|
52
56
|
], LogisticsWorkFlow.prototype, "status", void 0);
|
|
57
|
+
__decorate([
|
|
58
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
59
|
+
__metadata("design:type", Object)
|
|
60
|
+
], LogisticsWorkFlow.prototype, "user_id", void 0);
|
|
61
|
+
__decorate([
|
|
62
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
63
|
+
__metadata("design:type", Object)
|
|
64
|
+
], LogisticsWorkFlow.prototype, "role_id", void 0);
|
|
65
|
+
__decorate([
|
|
66
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
67
|
+
__metadata("design:type", Object)
|
|
68
|
+
], LogisticsWorkFlow.prototype, "department_id", void 0);
|
|
69
|
+
__decorate([
|
|
70
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
71
|
+
__metadata("design:type", Object)
|
|
72
|
+
], LogisticsWorkFlow.prototype, "section_id", void 0);
|
|
53
73
|
exports.LogisticsWorkFlow = LogisticsWorkFlow = __decorate([
|
|
54
74
|
(0, typeorm_1.Entity)({ name: 'logistics_workflows' }),
|
|
55
|
-
__metadata("design:paramtypes", [Number, String, String, Number, Number])
|
|
75
|
+
__metadata("design:paramtypes", [Number, String, String, Number, Number, Number, Number, Number, Number])
|
|
56
76
|
], LogisticsWorkFlow);
|
package/dist/models/{AirportEntryPermitApprovalModel.d.ts → SecurityAwarenessApprovalModel.d.ts}
RENAMED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { BaseModel } from './BaseModel';
|
|
2
|
-
export declare enum
|
|
2
|
+
export declare enum SecurityAwarenessApprovalStatus {
|
|
3
3
|
PENDING = "Pending",
|
|
4
4
|
IN_PROGRESS = "In Progress",
|
|
5
5
|
APPROVED = "Approved",
|
|
6
6
|
REJECTED = "Rejected"
|
|
7
7
|
}
|
|
8
|
-
export declare class
|
|
8
|
+
export declare class SecurityAwarenessApproval extends BaseModel {
|
|
9
9
|
request_id: number;
|
|
10
10
|
service_id: number | null;
|
|
11
11
|
sub_service_id: number | null;
|
|
@@ -17,6 +17,6 @@ export declare class AirportEntryPermitApproval extends BaseModel {
|
|
|
17
17
|
delegate_user_id: number | null;
|
|
18
18
|
approved_by: number | null;
|
|
19
19
|
comment: string;
|
|
20
|
-
approval_status:
|
|
21
|
-
constructor(request_id: number, approver_role_id: number, comment: string, approval_status:
|
|
20
|
+
approval_status: SecurityAwarenessApprovalStatus;
|
|
21
|
+
constructor(request_id: number, approver_role_id: number, comment: string, approval_status: SecurityAwarenessApprovalStatus, level: number, department_id?: number | null, section_id?: number | null, approver_user_id?: number | null, delegate_user_id?: number | null, approved_by?: number | null, service_id?: number, sub_service_id?: number);
|
|
22
22
|
}
|
package/dist/models/{AirportEntryPermitApprovalModel.js → SecurityAwarenessApprovalModel.js}
RENAMED
|
@@ -9,17 +9,17 @@ 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.SecurityAwarenessApproval = exports.SecurityAwarenessApprovalStatus = void 0;
|
|
13
13
|
const typeorm_1 = require("typeorm");
|
|
14
14
|
const BaseModel_1 = require("./BaseModel");
|
|
15
|
-
var
|
|
16
|
-
(function (
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
})(
|
|
22
|
-
let
|
|
15
|
+
var SecurityAwarenessApprovalStatus;
|
|
16
|
+
(function (SecurityAwarenessApprovalStatus) {
|
|
17
|
+
SecurityAwarenessApprovalStatus["PENDING"] = "Pending";
|
|
18
|
+
SecurityAwarenessApprovalStatus["IN_PROGRESS"] = "In Progress";
|
|
19
|
+
SecurityAwarenessApprovalStatus["APPROVED"] = "Approved";
|
|
20
|
+
SecurityAwarenessApprovalStatus["REJECTED"] = "Rejected";
|
|
21
|
+
})(SecurityAwarenessApprovalStatus || (exports.SecurityAwarenessApprovalStatus = SecurityAwarenessApprovalStatus = {}));
|
|
22
|
+
let SecurityAwarenessApproval = class SecurityAwarenessApproval extends BaseModel_1.BaseModel {
|
|
23
23
|
constructor(request_id, approver_role_id, comment, approval_status, level, department_id, section_id, approver_user_id, delegate_user_id, approved_by, service_id, sub_service_id) {
|
|
24
24
|
super();
|
|
25
25
|
this.request_id = request_id;
|
|
@@ -36,56 +36,56 @@ let AirportEntryPermitApproval = class AirportEntryPermitApproval extends BaseMo
|
|
|
36
36
|
this.approved_by = approved_by || null;
|
|
37
37
|
}
|
|
38
38
|
};
|
|
39
|
-
exports.
|
|
39
|
+
exports.SecurityAwarenessApproval = SecurityAwarenessApproval;
|
|
40
40
|
__decorate([
|
|
41
41
|
(0, typeorm_1.Column)({ type: 'integer', nullable: false }),
|
|
42
42
|
__metadata("design:type", Number)
|
|
43
|
-
],
|
|
43
|
+
], SecurityAwarenessApproval.prototype, "request_id", void 0);
|
|
44
44
|
__decorate([
|
|
45
45
|
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
46
46
|
__metadata("design:type", Object)
|
|
47
|
-
],
|
|
47
|
+
], SecurityAwarenessApproval.prototype, "service_id", void 0);
|
|
48
48
|
__decorate([
|
|
49
49
|
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
50
50
|
__metadata("design:type", Object)
|
|
51
|
-
],
|
|
51
|
+
], SecurityAwarenessApproval.prototype, "sub_service_id", void 0);
|
|
52
52
|
__decorate([
|
|
53
53
|
(0, typeorm_1.Column)({ type: 'integer', nullable: false }),
|
|
54
54
|
__metadata("design:type", Number)
|
|
55
|
-
],
|
|
55
|
+
], SecurityAwarenessApproval.prototype, "level", void 0);
|
|
56
56
|
__decorate([
|
|
57
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable:
|
|
57
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
58
58
|
__metadata("design:type", Number)
|
|
59
|
-
],
|
|
59
|
+
], SecurityAwarenessApproval.prototype, "approver_role_id", void 0);
|
|
60
60
|
__decorate([
|
|
61
61
|
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
62
62
|
__metadata("design:type", Object)
|
|
63
|
-
],
|
|
63
|
+
], SecurityAwarenessApproval.prototype, "department_id", void 0);
|
|
64
64
|
__decorate([
|
|
65
65
|
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
66
66
|
__metadata("design:type", Object)
|
|
67
|
-
],
|
|
67
|
+
], SecurityAwarenessApproval.prototype, "section_id", void 0);
|
|
68
68
|
__decorate([
|
|
69
69
|
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
70
70
|
__metadata("design:type", Object)
|
|
71
|
-
],
|
|
71
|
+
], SecurityAwarenessApproval.prototype, "approver_user_id", void 0);
|
|
72
72
|
__decorate([
|
|
73
73
|
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
74
74
|
__metadata("design:type", Object)
|
|
75
|
-
],
|
|
75
|
+
], SecurityAwarenessApproval.prototype, "delegate_user_id", void 0);
|
|
76
76
|
__decorate([
|
|
77
77
|
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
78
78
|
__metadata("design:type", Object)
|
|
79
|
-
],
|
|
79
|
+
], SecurityAwarenessApproval.prototype, "approved_by", void 0);
|
|
80
80
|
__decorate([
|
|
81
81
|
(0, typeorm_1.Column)({ type: 'varchar', length: 500, nullable: true, default: '' }),
|
|
82
82
|
__metadata("design:type", String)
|
|
83
|
-
],
|
|
83
|
+
], SecurityAwarenessApproval.prototype, "comment", void 0);
|
|
84
84
|
__decorate([
|
|
85
|
-
(0, typeorm_1.Column)({ type: 'enum', enum:
|
|
85
|
+
(0, typeorm_1.Column)({ type: 'enum', enum: SecurityAwarenessApprovalStatus, default: SecurityAwarenessApprovalStatus.PENDING, nullable: false }),
|
|
86
86
|
__metadata("design:type", String)
|
|
87
|
-
],
|
|
88
|
-
exports.
|
|
89
|
-
(0, typeorm_1.Entity)({ name: '
|
|
87
|
+
], SecurityAwarenessApproval.prototype, "approval_status", void 0);
|
|
88
|
+
exports.SecurityAwarenessApproval = SecurityAwarenessApproval = __decorate([
|
|
89
|
+
(0, typeorm_1.Entity)({ name: 'security_awareness_approvals' }),
|
|
90
90
|
__metadata("design:paramtypes", [Number, Number, String, String, Number, Object, Object, Object, Object, Object, Number, Number])
|
|
91
|
-
],
|
|
91
|
+
], SecurityAwarenessApproval);
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { BaseModel } from './BaseModel';
|
|
2
|
+
export declare class SecurityAwarenessAttachment extends BaseModel {
|
|
3
|
+
request_id: number;
|
|
4
|
+
service_id: number | null;
|
|
5
|
+
sub_service_id: number | null;
|
|
6
|
+
file_url: string;
|
|
7
|
+
file_name: string;
|
|
8
|
+
file_type: string;
|
|
9
|
+
file_size: number | null;
|
|
10
|
+
chat_id: number | null;
|
|
11
|
+
constructor(request_id: number, file_url: string, file_name?: string, file_type?: string, file_size?: number, service_id?: number, sub_service_id?: number, chat_id?: number);
|
|
12
|
+
}
|
package/dist/models/{AirportEntryPermitAttachmentModel.js → SecurityAwarenessAttachmentModel.js}
RENAMED
|
@@ -9,11 +9,11 @@ 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.SecurityAwarenessAttachment = void 0;
|
|
13
13
|
const typeorm_1 = require("typeorm");
|
|
14
14
|
const BaseModel_1 = require("./BaseModel");
|
|
15
|
-
let
|
|
16
|
-
constructor(request_id,
|
|
15
|
+
let SecurityAwarenessAttachment = class SecurityAwarenessAttachment extends BaseModel_1.BaseModel {
|
|
16
|
+
constructor(request_id, file_url, file_name, file_type, file_size, service_id, sub_service_id, chat_id) {
|
|
17
17
|
super();
|
|
18
18
|
this.request_id = request_id;
|
|
19
19
|
this.service_id = service_id || null;
|
|
@@ -23,52 +23,42 @@ let AirportEntryPermitAttachment = class AirportEntryPermitAttachment extends Ba
|
|
|
23
23
|
this.file_type = file_type || '';
|
|
24
24
|
this.file_size = file_size || null;
|
|
25
25
|
this.chat_id = chat_id || null;
|
|
26
|
-
this.uploaded_by = uploaded_by;
|
|
27
|
-
this.description = description || '';
|
|
28
26
|
}
|
|
29
27
|
};
|
|
30
|
-
exports.
|
|
28
|
+
exports.SecurityAwarenessAttachment = SecurityAwarenessAttachment;
|
|
31
29
|
__decorate([
|
|
32
30
|
(0, typeorm_1.Column)({ type: 'integer', nullable: false }),
|
|
33
31
|
__metadata("design:type", Number)
|
|
34
|
-
],
|
|
32
|
+
], SecurityAwarenessAttachment.prototype, "request_id", void 0);
|
|
35
33
|
__decorate([
|
|
36
34
|
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
37
35
|
__metadata("design:type", Object)
|
|
38
|
-
],
|
|
36
|
+
], SecurityAwarenessAttachment.prototype, "service_id", void 0);
|
|
39
37
|
__decorate([
|
|
40
38
|
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
41
39
|
__metadata("design:type", Object)
|
|
42
|
-
],
|
|
40
|
+
], SecurityAwarenessAttachment.prototype, "sub_service_id", void 0);
|
|
43
41
|
__decorate([
|
|
44
42
|
(0, typeorm_1.Column)({ type: 'varchar', length: 500, nullable: false }),
|
|
45
43
|
__metadata("design:type", String)
|
|
46
|
-
],
|
|
44
|
+
], SecurityAwarenessAttachment.prototype, "file_url", void 0);
|
|
47
45
|
__decorate([
|
|
48
46
|
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
|
|
49
47
|
__metadata("design:type", String)
|
|
50
|
-
],
|
|
48
|
+
], SecurityAwarenessAttachment.prototype, "file_name", void 0);
|
|
51
49
|
__decorate([
|
|
52
50
|
(0, typeorm_1.Column)({ type: 'varchar', length: 100, nullable: true }),
|
|
53
51
|
__metadata("design:type", String)
|
|
54
|
-
],
|
|
52
|
+
], SecurityAwarenessAttachment.prototype, "file_type", void 0);
|
|
55
53
|
__decorate([
|
|
56
54
|
(0, typeorm_1.Column)({ type: 'bigint', nullable: true }),
|
|
57
55
|
__metadata("design:type", Object)
|
|
58
|
-
],
|
|
56
|
+
], SecurityAwarenessAttachment.prototype, "file_size", void 0);
|
|
59
57
|
__decorate([
|
|
60
58
|
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
61
59
|
__metadata("design:type", Object)
|
|
62
|
-
],
|
|
63
|
-
__decorate([
|
|
64
|
-
(0, typeorm_1.
|
|
65
|
-
__metadata("design:
|
|
66
|
-
],
|
|
67
|
-
__decorate([
|
|
68
|
-
(0, typeorm_1.Column)({ type: "text", nullable: true }),
|
|
69
|
-
__metadata("design:type", String)
|
|
70
|
-
], AirportEntryPermitAttachment.prototype, "description", void 0);
|
|
71
|
-
exports.AirportEntryPermitAttachment = AirportEntryPermitAttachment = __decorate([
|
|
72
|
-
(0, typeorm_1.Entity)({ name: 'airport_entry_permit_attachments' }),
|
|
73
|
-
__metadata("design:paramtypes", [Number, Number, String, String, String, Number, Number, Number, Number, String])
|
|
74
|
-
], AirportEntryPermitAttachment);
|
|
60
|
+
], SecurityAwarenessAttachment.prototype, "chat_id", void 0);
|
|
61
|
+
exports.SecurityAwarenessAttachment = SecurityAwarenessAttachment = __decorate([
|
|
62
|
+
(0, typeorm_1.Entity)({ name: 'security_awareness_attachments' }),
|
|
63
|
+
__metadata("design:paramtypes", [Number, String, String, String, Number, Number, Number, Number])
|
|
64
|
+
], SecurityAwarenessAttachment);
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { BaseModel } from './BaseModel';
|
|
2
|
+
import { SecurityAwarenessApprovalStatus } from './SecurityAwarenessApprovalModel';
|
|
3
|
+
export declare enum SecurityAwarenessMessageType {
|
|
4
|
+
TEXT = "text",
|
|
5
|
+
IMAGE = "image",
|
|
6
|
+
VIDEO = "video",
|
|
7
|
+
FILE = "file",
|
|
8
|
+
LINK = "link"
|
|
9
|
+
}
|
|
10
|
+
export declare class SecurityAwarenessChat extends BaseModel {
|
|
11
|
+
request_id: number;
|
|
12
|
+
service_id: number | null;
|
|
13
|
+
sub_service_id: number | null;
|
|
14
|
+
user_id: number;
|
|
15
|
+
role_id: number;
|
|
16
|
+
message: string;
|
|
17
|
+
messageType: SecurityAwarenessMessageType;
|
|
18
|
+
status: SecurityAwarenessApprovalStatus;
|
|
19
|
+
constructor(request_id: number, user_id: number, role_id: number, message: string, service_id?: number, sub_service_id?: number, messageType?: SecurityAwarenessMessageType, status?: SecurityAwarenessApprovalStatus);
|
|
20
|
+
}
|
|
@@ -0,0 +1,78 @@
|
|
|
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.SecurityAwarenessChat = exports.SecurityAwarenessMessageType = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
const BaseModel_1 = require("./BaseModel");
|
|
15
|
+
const SecurityAwarenessApprovalModel_1 = require("./SecurityAwarenessApprovalModel");
|
|
16
|
+
var SecurityAwarenessMessageType;
|
|
17
|
+
(function (SecurityAwarenessMessageType) {
|
|
18
|
+
SecurityAwarenessMessageType["TEXT"] = "text";
|
|
19
|
+
SecurityAwarenessMessageType["IMAGE"] = "image";
|
|
20
|
+
SecurityAwarenessMessageType["VIDEO"] = "video";
|
|
21
|
+
SecurityAwarenessMessageType["FILE"] = "file";
|
|
22
|
+
SecurityAwarenessMessageType["LINK"] = "link";
|
|
23
|
+
})(SecurityAwarenessMessageType || (exports.SecurityAwarenessMessageType = SecurityAwarenessMessageType = {}));
|
|
24
|
+
let SecurityAwarenessChat = class SecurityAwarenessChat extends BaseModel_1.BaseModel {
|
|
25
|
+
constructor(request_id, user_id, role_id, message, service_id, sub_service_id, messageType, status) {
|
|
26
|
+
super();
|
|
27
|
+
this.request_id = request_id;
|
|
28
|
+
this.service_id = service_id || null;
|
|
29
|
+
this.sub_service_id = sub_service_id || null;
|
|
30
|
+
this.user_id = user_id;
|
|
31
|
+
this.role_id = role_id;
|
|
32
|
+
this.message = message;
|
|
33
|
+
this.messageType = messageType || SecurityAwarenessMessageType.TEXT;
|
|
34
|
+
this.status = status || SecurityAwarenessApprovalModel_1.SecurityAwarenessApprovalStatus.PENDING;
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
exports.SecurityAwarenessChat = SecurityAwarenessChat;
|
|
38
|
+
__decorate([
|
|
39
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: false }),
|
|
40
|
+
__metadata("design:type", Number)
|
|
41
|
+
], SecurityAwarenessChat.prototype, "request_id", void 0);
|
|
42
|
+
__decorate([
|
|
43
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
44
|
+
__metadata("design:type", Object)
|
|
45
|
+
], SecurityAwarenessChat.prototype, "service_id", void 0);
|
|
46
|
+
__decorate([
|
|
47
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
48
|
+
__metadata("design:type", Object)
|
|
49
|
+
], SecurityAwarenessChat.prototype, "sub_service_id", void 0);
|
|
50
|
+
__decorate([
|
|
51
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: false }),
|
|
52
|
+
__metadata("design:type", Number)
|
|
53
|
+
], SecurityAwarenessChat.prototype, "user_id", void 0);
|
|
54
|
+
__decorate([
|
|
55
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
56
|
+
__metadata("design:type", Number)
|
|
57
|
+
], SecurityAwarenessChat.prototype, "role_id", void 0);
|
|
58
|
+
__decorate([
|
|
59
|
+
(0, typeorm_1.Column)({ type: 'text', nullable: false }),
|
|
60
|
+
__metadata("design:type", String)
|
|
61
|
+
], SecurityAwarenessChat.prototype, "message", void 0);
|
|
62
|
+
__decorate([
|
|
63
|
+
(0, typeorm_1.Column)({
|
|
64
|
+
type: 'enum',
|
|
65
|
+
enum: SecurityAwarenessMessageType,
|
|
66
|
+
default: SecurityAwarenessMessageType.TEXT,
|
|
67
|
+
nullable: false
|
|
68
|
+
}),
|
|
69
|
+
__metadata("design:type", String)
|
|
70
|
+
], SecurityAwarenessChat.prototype, "messageType", void 0);
|
|
71
|
+
__decorate([
|
|
72
|
+
(0, typeorm_1.Column)({ type: 'enum', enum: SecurityAwarenessApprovalModel_1.SecurityAwarenessApprovalStatus, default: SecurityAwarenessApprovalModel_1.SecurityAwarenessApprovalStatus.PENDING, nullable: false }),
|
|
73
|
+
__metadata("design:type", String)
|
|
74
|
+
], SecurityAwarenessChat.prototype, "status", void 0);
|
|
75
|
+
exports.SecurityAwarenessChat = SecurityAwarenessChat = __decorate([
|
|
76
|
+
(0, typeorm_1.Entity)({ name: 'security_awareness_chats' }),
|
|
77
|
+
__metadata("design:paramtypes", [Number, Number, Number, String, Number, Number, String, String])
|
|
78
|
+
], SecurityAwarenessChat);
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { BaseModel } from './BaseModel';
|
|
2
|
+
export declare enum SecurityAwarenessRequestStatus {
|
|
3
|
+
PENDING = "Pending",
|
|
4
|
+
ASSIGNED = "Assigned",
|
|
5
|
+
IN_PROGRESS = "In Progress",
|
|
6
|
+
APPROVED = "Approved",
|
|
7
|
+
REJECTED = "Rejected"
|
|
8
|
+
}
|
|
9
|
+
export declare enum MediaCoverageRequired {
|
|
10
|
+
YES = "Yes",
|
|
11
|
+
NO = "No"
|
|
12
|
+
}
|
|
13
|
+
export declare class SecurityAwarenessRequest extends BaseModel {
|
|
14
|
+
req_user_department_id: number | null;
|
|
15
|
+
req_user_section_id: number | null;
|
|
16
|
+
service_id: number;
|
|
17
|
+
sub_service_id: number;
|
|
18
|
+
user_id: number;
|
|
19
|
+
title: string;
|
|
20
|
+
date_of_submission: Date;
|
|
21
|
+
phone_number: string;
|
|
22
|
+
place: string | null;
|
|
23
|
+
description: string | null;
|
|
24
|
+
event_date_time: Date | null;
|
|
25
|
+
media_coverage_required: MediaCoverageRequired;
|
|
26
|
+
status: SecurityAwarenessRequestStatus;
|
|
27
|
+
workflow_execution_id: string | null;
|
|
28
|
+
constructor(req_user_department_id: number | null, req_user_section_id: number | null, service_id: number, sub_service_id: number, user_id: number, title: string, date_of_submission: Date, phone_number: string, place: string | null, description: string | null, event_date_time: Date | null, media_coverage_required: MediaCoverageRequired, status: SecurityAwarenessRequestStatus, workflow_execution_id?: string | null);
|
|
29
|
+
}
|