@platform-modules/civil-aviation-authority 2.1.40 → 2.2.20

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 (91) hide show
  1. package/dist/data-source.d.ts +4 -0
  2. package/dist/data-source.js +106 -0
  3. package/dist/helpers/utils/enum.d.ts +75 -0
  4. package/dist/helpers/utils/enum.js +53 -0
  5. package/dist/index.d.ts +40 -0
  6. package/dist/index.js +60 -0
  7. package/dist/models/BaseModel.d.ts +14 -0
  8. package/dist/models/BaseModel.js +66 -0
  9. package/dist/models/CAAServices.d.ts +8 -0
  10. package/dist/models/CAAServices.js +44 -0
  11. package/dist/models/CAASubServices.d.ts +11 -0
  12. package/dist/models/CAASubServices.js +55 -0
  13. package/dist/models/DelegateSettingsModel.d.ts +9 -0
  14. package/dist/models/DelegateSettingsModel.js +50 -0
  15. package/dist/models/DepartmentsModel.d.ts +7 -0
  16. package/dist/models/DepartmentsModel.js +39 -0
  17. package/dist/models/DirectorateModel.d.ts +7 -0
  18. package/dist/models/DirectorateModel.js +39 -0
  19. package/dist/models/ITHelpDeskModel.d.ts +33 -0
  20. package/dist/models/ITHelpDeskModel.js +136 -0
  21. package/dist/models/ITRequestAttachmentModel.d.ts +17 -0
  22. package/dist/models/ITRequestAttachmentModel.js +81 -0
  23. package/dist/models/ITRequestChatModel.d.ts +12 -0
  24. package/dist/models/ITRequestChatModel.js +56 -0
  25. package/dist/models/ItApprovalsModel.d.ts +21 -0
  26. package/dist/models/ItApprovalsModel.js +90 -0
  27. package/dist/models/ItWorkflowModel.d.ts +15 -0
  28. package/dist/models/ItWorkflowModel.js +61 -0
  29. package/dist/models/LogisticsApprovalModel.d.ts +22 -0
  30. package/dist/models/LogisticsApprovalModel.js +91 -0
  31. package/dist/models/LogisticsAttachmentModel.d.ts +12 -0
  32. package/dist/models/LogisticsAttachmentModel.js +64 -0
  33. package/dist/models/LogisticsChatModel.d.ts +17 -0
  34. package/dist/models/LogisticsChatModel.js +67 -0
  35. package/dist/models/LogisticsForeignVehicleModel.d.ts +42 -0
  36. package/dist/models/LogisticsForeignVehicleModel.js +153 -0
  37. package/dist/models/LogisticsForeignVehiclePassengerModel.d.ts +6 -0
  38. package/dist/models/LogisticsForeignVehiclePassengerModel.js +34 -0
  39. package/dist/models/LogisticsModel.d.ts +57 -0
  40. package/dist/models/LogisticsModel.js +195 -0
  41. package/dist/models/LogisticsWorkflowModel.d.ts +14 -0
  42. package/dist/models/LogisticsWorkflowModel.js +56 -0
  43. package/dist/models/NotificationModel.d.ts +23 -0
  44. package/dist/models/NotificationModel.js +92 -0
  45. package/dist/models/PortalFeedbackModel.d.ts +8 -0
  46. package/dist/models/PortalFeedbackModel.js +44 -0
  47. package/dist/models/PositionModel.d.ts +6 -0
  48. package/dist/models/PositionModel.js +34 -0
  49. package/dist/models/SectionModel.d.ts +8 -0
  50. package/dist/models/SectionModel.js +44 -0
  51. package/dist/models/ServiceTypeModel.d.ts +20 -0
  52. package/dist/models/ServiceTypeModel.js +88 -0
  53. package/dist/models/VpnApprovalModel.d.ts +21 -0
  54. package/dist/models/VpnApprovalModel.js +87 -0
  55. package/dist/models/VpnRequestAttachmentModel.d.ts +11 -0
  56. package/dist/models/VpnRequestAttachmentModel.js +59 -0
  57. package/dist/models/VpnRequestChatModel.d.ts +16 -0
  58. package/dist/models/VpnRequestChatModel.js +62 -0
  59. package/dist/models/VpnRequestModel.d.ts +70 -0
  60. package/dist/models/VpnRequestModel.js +175 -0
  61. package/dist/models/VpnWorkflowModel.d.ts +13 -0
  62. package/dist/models/VpnWorkflowModel.js +55 -0
  63. package/dist/models/WorkflowDefinitions.d.ts +16 -0
  64. package/dist/models/WorkflowDefinitions.js +86 -0
  65. package/dist/models/WorkflowHierarchy.d.ts +17 -0
  66. package/dist/models/WorkflowHierarchy.js +86 -0
  67. package/dist/models/WorkflowTask.d.ts +13 -0
  68. package/dist/models/WorkflowTask.js +78 -0
  69. package/dist/models/WorkflowTaskNames.d.ts +17 -0
  70. package/dist/models/WorkflowTaskNames.js +63 -0
  71. package/dist/models/contactInfoModel.d.ts +18 -0
  72. package/dist/models/contactInfoModel.js +80 -0
  73. package/dist/models/feedbackModel.d.ts +16 -0
  74. package/dist/models/feedbackModel.js +61 -0
  75. package/dist/models/importantLinksModel.d.ts +6 -0
  76. package/dist/models/importantLinksModel.js +34 -0
  77. package/dist/models/role.d.ts +16 -0
  78. package/dist/models/role.js +44 -0
  79. package/dist/models/roleRightsModel.d.ts +16 -0
  80. package/dist/models/roleRightsModel.js +44 -0
  81. package/dist/models/serviceBookmarksModel.d.ts +6 -0
  82. package/dist/models/serviceBookmarksModel.js +34 -0
  83. package/dist/models/user-sessions.d.ts +18 -0
  84. package/dist/models/user-sessions.js +54 -0
  85. package/dist/models/user.d.ts +47 -0
  86. package/dist/models/user.js +238 -0
  87. package/dist/models/userRolesModel.d.ts +19 -0
  88. package/dist/models/userRolesModel.js +59 -0
  89. package/dist/scripts.d.ts +1 -0
  90. package/dist/scripts.js +11 -0
  91. package/package.json +1 -1
@@ -0,0 +1,21 @@
1
+ import { BaseModel } from "./BaseModel";
2
+ export declare enum VpnApprovalStatus {
3
+ PENDING = "Pending",
4
+ IN_PROGRESS = "In Progress",
5
+ APPROVED = "Approved",
6
+ REJECTED = "Rejected",
7
+ ASSIGNED = "Assigned"
8
+ }
9
+ export declare class VpnApprovalDetails extends BaseModel {
10
+ request_id: number;
11
+ level: number;
12
+ approver_user_id: number | null;
13
+ approver_role_id: number | null;
14
+ department_id: number | null;
15
+ section_id: number | null;
16
+ approved_by: number | null;
17
+ comment: string;
18
+ approval_status: VpnApprovalStatus;
19
+ is_manager: boolean;
20
+ constructor(request_id: number, approver_user_id: number | null, approver_role_id: number | null, comment: string, approval_status: VpnApprovalStatus, level: number, department_id?: number | null, section_id?: number | null, approved_by?: number | null, is_manager?: boolean);
21
+ }
@@ -0,0 +1,87 @@
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.VpnApprovalDetails = exports.VpnApprovalStatus = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ var VpnApprovalStatus;
16
+ (function (VpnApprovalStatus) {
17
+ VpnApprovalStatus["PENDING"] = "Pending";
18
+ VpnApprovalStatus["IN_PROGRESS"] = "In Progress";
19
+ VpnApprovalStatus["APPROVED"] = "Approved";
20
+ VpnApprovalStatus["REJECTED"] = "Rejected";
21
+ VpnApprovalStatus["ASSIGNED"] = "Assigned";
22
+ })(VpnApprovalStatus || (exports.VpnApprovalStatus = VpnApprovalStatus = {}));
23
+ let VpnApprovalDetails = class VpnApprovalDetails extends BaseModel_1.BaseModel {
24
+ constructor(request_id, approver_user_id, approver_role_id, comment, approval_status, level, department_id, section_id, approved_by, is_manager) {
25
+ super();
26
+ this.request_id = request_id;
27
+ this.approver_user_id = approver_user_id;
28
+ this.approver_role_id = approver_role_id;
29
+ this.comment = comment;
30
+ this.approval_status = approval_status;
31
+ this.level = level;
32
+ this.department_id = department_id || null;
33
+ this.section_id = section_id || null;
34
+ this.approved_by = approved_by || null;
35
+ this.is_manager = is_manager ?? false;
36
+ }
37
+ };
38
+ exports.VpnApprovalDetails = VpnApprovalDetails;
39
+ __decorate([
40
+ (0, typeorm_1.Column)({ type: "integer", nullable: false }),
41
+ __metadata("design:type", Number)
42
+ ], VpnApprovalDetails.prototype, "request_id", void 0);
43
+ __decorate([
44
+ (0, typeorm_1.Column)({ type: "integer", nullable: false }),
45
+ __metadata("design:type", Number)
46
+ ], VpnApprovalDetails.prototype, "level", void 0);
47
+ __decorate([
48
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
49
+ __metadata("design:type", Object)
50
+ ], VpnApprovalDetails.prototype, "approver_user_id", void 0);
51
+ __decorate([
52
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
53
+ __metadata("design:type", Object)
54
+ ], VpnApprovalDetails.prototype, "approver_role_id", void 0);
55
+ __decorate([
56
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
57
+ __metadata("design:type", Object)
58
+ ], VpnApprovalDetails.prototype, "department_id", void 0);
59
+ __decorate([
60
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
61
+ __metadata("design:type", Object)
62
+ ], VpnApprovalDetails.prototype, "section_id", void 0);
63
+ __decorate([
64
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
65
+ __metadata("design:type", Object)
66
+ ], VpnApprovalDetails.prototype, "approved_by", void 0);
67
+ __decorate([
68
+ (0, typeorm_1.Column)({ type: "varchar", length: 255, nullable: true, default: "" }),
69
+ __metadata("design:type", String)
70
+ ], VpnApprovalDetails.prototype, "comment", void 0);
71
+ __decorate([
72
+ (0, typeorm_1.Column)({
73
+ type: "enum",
74
+ enum: VpnApprovalStatus,
75
+ default: VpnApprovalStatus.PENDING,
76
+ nullable: false
77
+ }),
78
+ __metadata("design:type", String)
79
+ ], VpnApprovalDetails.prototype, "approval_status", void 0);
80
+ __decorate([
81
+ (0, typeorm_1.Column)({ type: "boolean", default: false, nullable: false }),
82
+ __metadata("design:type", Boolean)
83
+ ], VpnApprovalDetails.prototype, "is_manager", void 0);
84
+ exports.VpnApprovalDetails = VpnApprovalDetails = __decorate([
85
+ (0, typeorm_1.Entity)({ name: "vpn_approvals" }),
86
+ __metadata("design:paramtypes", [Number, Object, Object, String, String, Number, Object, Object, Object, Boolean])
87
+ ], VpnApprovalDetails);
@@ -0,0 +1,11 @@
1
+ import { BaseModel } from "./BaseModel";
2
+ export declare class VpnRequestAttachment extends BaseModel {
3
+ request_id: number;
4
+ uploaded_by: number;
5
+ file_url: string;
6
+ file_name: string;
7
+ file_type: string;
8
+ file_size: number | null;
9
+ description: string;
10
+ constructor(request_id: number, uploaded_by: number, file_url: string, file_name?: string, file_type?: string, file_size?: number, description?: string);
11
+ }
@@ -0,0 +1,59 @@
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.VpnRequestAttachment = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ let VpnRequestAttachment = class VpnRequestAttachment extends BaseModel_1.BaseModel {
16
+ constructor(request_id, uploaded_by, file_url, file_name, file_type, file_size, description) {
17
+ super();
18
+ this.request_id = request_id;
19
+ this.uploaded_by = uploaded_by;
20
+ this.file_url = file_url;
21
+ this.file_name = file_name || "";
22
+ this.file_type = file_type || "";
23
+ this.file_size = file_size || null;
24
+ this.description = description || "";
25
+ }
26
+ };
27
+ exports.VpnRequestAttachment = VpnRequestAttachment;
28
+ __decorate([
29
+ (0, typeorm_1.Column)({ type: "integer", nullable: false }),
30
+ __metadata("design:type", Number)
31
+ ], VpnRequestAttachment.prototype, "request_id", void 0);
32
+ __decorate([
33
+ (0, typeorm_1.Column)({ type: "integer", nullable: false }),
34
+ __metadata("design:type", Number)
35
+ ], VpnRequestAttachment.prototype, "uploaded_by", void 0);
36
+ __decorate([
37
+ (0, typeorm_1.Column)({ type: "varchar", length: 500, nullable: false }),
38
+ __metadata("design:type", String)
39
+ ], VpnRequestAttachment.prototype, "file_url", void 0);
40
+ __decorate([
41
+ (0, typeorm_1.Column)({ type: "varchar", length: 255, nullable: true }),
42
+ __metadata("design:type", String)
43
+ ], VpnRequestAttachment.prototype, "file_name", void 0);
44
+ __decorate([
45
+ (0, typeorm_1.Column)({ type: "varchar", length: 100, nullable: true }),
46
+ __metadata("design:type", String)
47
+ ], VpnRequestAttachment.prototype, "file_type", void 0);
48
+ __decorate([
49
+ (0, typeorm_1.Column)({ type: "bigint", nullable: true }),
50
+ __metadata("design:type", Object)
51
+ ], VpnRequestAttachment.prototype, "file_size", void 0);
52
+ __decorate([
53
+ (0, typeorm_1.Column)({ type: "text", nullable: true }),
54
+ __metadata("design:type", String)
55
+ ], VpnRequestAttachment.prototype, "description", void 0);
56
+ exports.VpnRequestAttachment = VpnRequestAttachment = __decorate([
57
+ (0, typeorm_1.Entity)({ name: "vpn_request_attachments" }),
58
+ __metadata("design:paramtypes", [Number, Number, String, String, String, Number, String])
59
+ ], VpnRequestAttachment);
@@ -0,0 +1,16 @@
1
+ import { BaseModel } from "./BaseModel";
2
+ export declare enum VpnMessageType {
3
+ TEXT = "text",
4
+ IMAGE = "image",
5
+ VIDEO = "video",
6
+ FILE = "file",
7
+ LINK = "link"
8
+ }
9
+ export declare class VpnRequestChat extends BaseModel {
10
+ request_id: number;
11
+ user_id: number;
12
+ message: string;
13
+ messageType: VpnMessageType;
14
+ is_internal: boolean;
15
+ constructor(request_id: number, user_id: number, message: string, messageType?: VpnMessageType, is_internal?: boolean);
16
+ }
@@ -0,0 +1,62 @@
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.VpnRequestChat = exports.VpnMessageType = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ var VpnMessageType;
16
+ (function (VpnMessageType) {
17
+ VpnMessageType["TEXT"] = "text";
18
+ VpnMessageType["IMAGE"] = "image";
19
+ VpnMessageType["VIDEO"] = "video";
20
+ VpnMessageType["FILE"] = "file";
21
+ VpnMessageType["LINK"] = "link";
22
+ })(VpnMessageType || (exports.VpnMessageType = VpnMessageType = {}));
23
+ let VpnRequestChat = class VpnRequestChat extends BaseModel_1.BaseModel {
24
+ constructor(request_id, user_id, message, messageType, is_internal) {
25
+ super();
26
+ this.request_id = request_id;
27
+ this.user_id = user_id;
28
+ this.message = message;
29
+ this.messageType = messageType || VpnMessageType.TEXT;
30
+ this.is_internal = is_internal || false;
31
+ }
32
+ };
33
+ exports.VpnRequestChat = VpnRequestChat;
34
+ __decorate([
35
+ (0, typeorm_1.Column)({ type: "integer", nullable: false }),
36
+ __metadata("design:type", Number)
37
+ ], VpnRequestChat.prototype, "request_id", void 0);
38
+ __decorate([
39
+ (0, typeorm_1.Column)({ type: "integer", nullable: false }),
40
+ __metadata("design:type", Number)
41
+ ], VpnRequestChat.prototype, "user_id", void 0);
42
+ __decorate([
43
+ (0, typeorm_1.Column)({ type: "text", nullable: false }),
44
+ __metadata("design:type", String)
45
+ ], VpnRequestChat.prototype, "message", void 0);
46
+ __decorate([
47
+ (0, typeorm_1.Column)({
48
+ type: "enum",
49
+ enum: VpnMessageType,
50
+ default: VpnMessageType.TEXT,
51
+ nullable: false
52
+ }),
53
+ __metadata("design:type", String)
54
+ ], VpnRequestChat.prototype, "messageType", void 0);
55
+ __decorate([
56
+ (0, typeorm_1.Column)({ type: "boolean", default: false }),
57
+ __metadata("design:type", Boolean)
58
+ ], VpnRequestChat.prototype, "is_internal", void 0);
59
+ exports.VpnRequestChat = VpnRequestChat = __decorate([
60
+ (0, typeorm_1.Entity)({ name: "vpn_request_chat" }),
61
+ __metadata("design:paramtypes", [Number, Number, String, String, Boolean])
62
+ ], VpnRequestChat);
@@ -0,0 +1,70 @@
1
+ import { BaseModel } from "./BaseModel";
2
+ export declare enum VpnRequestType {
3
+ CAA_STAFF = "CAA_STAFF",
4
+ CONTRACTOR = "CONTRACTOR"
5
+ }
6
+ export declare enum VpnReasonForRequest {
7
+ REMOTE_WORK = "REMOTE_WORK",
8
+ ACCESS_INTERNAL_SYSTEMS = "ACCESS_INTERNAL_SYSTEMS",
9
+ THIRD_PARTY_VENDOR = "THIRD_PARTY_VENDOR",
10
+ PROJECT_SPECIFIC = "PROJECT_SPECIFIC",
11
+ RENEWAL = "RENEWAL"
12
+ }
13
+ export declare enum VpnSystemsAccess {
14
+ INTERNAL_DATABASES = "INTERNAL_DATABASES",
15
+ FILE_SERVERS = "FILE_SERVERS",
16
+ SHARED_SERVERS = "SHARED_SERVERS",
17
+ UFUQ = "UFUQ",
18
+ ERP = "ERP",
19
+ OTHERS = "OTHERS"
20
+ }
21
+ export declare enum VpnSourceIpType {
22
+ PRIVATE = "PRIVATE",
23
+ PUBLIC = "PUBLIC"
24
+ }
25
+ export declare enum VpnAccessType {
26
+ ONE_TIME = "ONE_TIME",
27
+ PERMANENT = "PERMANENT"
28
+ }
29
+ export declare enum VpnDeviceType {
30
+ CAA_LAPTOP = "CAA_LAPTOP",
31
+ PERSONAL_DEVICE = "PERSONAL_DEVICE",
32
+ MOBILE_DEVICE = "MOBILE_DEVICE"
33
+ }
34
+ export declare enum VpnRequestStatus {
35
+ PENDING = "PENDING",
36
+ ASSIGNED = "ASSIGNED",
37
+ IN_PROGRESS = "IN_PROGRESS",
38
+ COMPLETED = "COMPLETED",
39
+ APPROVED = "APPROVED",
40
+ REJECTED = "REJECTED"
41
+ }
42
+ export declare class VpnRequest extends BaseModel {
43
+ job_title: string;
44
+ req_user_department_id: number | null;
45
+ req_user_section_id: number | null;
46
+ req_user_position_id: number | null;
47
+ service_id: number | null;
48
+ sub_service_id: number | null;
49
+ user_id: number;
50
+ request_for: VpnRequestType;
51
+ employee_identifier: string;
52
+ employee_email: string;
53
+ phone_number: string;
54
+ reason_for_request: VpnReasonForRequest[];
55
+ description: string | null;
56
+ systems_to_access: VpnSystemsAccess[];
57
+ source_ip_type: VpnSourceIpType | null;
58
+ source_ip_address: string | null;
59
+ country: string;
60
+ start_date: Date;
61
+ end_date: Date | null;
62
+ access_type: VpnAccessType;
63
+ device_type: VpnDeviceType[];
64
+ acknowledgement: boolean;
65
+ status: VpnRequestStatus;
66
+ reviewer_user_id: number | null;
67
+ assigned_to_user_id: number | null;
68
+ assigned_at: Date | null;
69
+ workflow_execution_id: string | null;
70
+ }
@@ -0,0 +1,175 @@
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.VpnRequest = exports.VpnRequestStatus = exports.VpnDeviceType = exports.VpnAccessType = exports.VpnSourceIpType = exports.VpnSystemsAccess = exports.VpnReasonForRequest = exports.VpnRequestType = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ var VpnRequestType;
16
+ (function (VpnRequestType) {
17
+ VpnRequestType["CAA_STAFF"] = "CAA_STAFF";
18
+ VpnRequestType["CONTRACTOR"] = "CONTRACTOR";
19
+ })(VpnRequestType || (exports.VpnRequestType = VpnRequestType = {}));
20
+ var VpnReasonForRequest;
21
+ (function (VpnReasonForRequest) {
22
+ VpnReasonForRequest["REMOTE_WORK"] = "REMOTE_WORK";
23
+ VpnReasonForRequest["ACCESS_INTERNAL_SYSTEMS"] = "ACCESS_INTERNAL_SYSTEMS";
24
+ VpnReasonForRequest["THIRD_PARTY_VENDOR"] = "THIRD_PARTY_VENDOR";
25
+ VpnReasonForRequest["PROJECT_SPECIFIC"] = "PROJECT_SPECIFIC";
26
+ VpnReasonForRequest["RENEWAL"] = "RENEWAL";
27
+ })(VpnReasonForRequest || (exports.VpnReasonForRequest = VpnReasonForRequest = {}));
28
+ var VpnSystemsAccess;
29
+ (function (VpnSystemsAccess) {
30
+ VpnSystemsAccess["INTERNAL_DATABASES"] = "INTERNAL_DATABASES";
31
+ VpnSystemsAccess["FILE_SERVERS"] = "FILE_SERVERS";
32
+ VpnSystemsAccess["SHARED_SERVERS"] = "SHARED_SERVERS";
33
+ VpnSystemsAccess["UFUQ"] = "UFUQ";
34
+ VpnSystemsAccess["ERP"] = "ERP";
35
+ VpnSystemsAccess["OTHERS"] = "OTHERS";
36
+ })(VpnSystemsAccess || (exports.VpnSystemsAccess = VpnSystemsAccess = {}));
37
+ var VpnSourceIpType;
38
+ (function (VpnSourceIpType) {
39
+ VpnSourceIpType["PRIVATE"] = "PRIVATE";
40
+ VpnSourceIpType["PUBLIC"] = "PUBLIC";
41
+ })(VpnSourceIpType || (exports.VpnSourceIpType = VpnSourceIpType = {}));
42
+ var VpnAccessType;
43
+ (function (VpnAccessType) {
44
+ VpnAccessType["ONE_TIME"] = "ONE_TIME";
45
+ VpnAccessType["PERMANENT"] = "PERMANENT";
46
+ })(VpnAccessType || (exports.VpnAccessType = VpnAccessType = {}));
47
+ var VpnDeviceType;
48
+ (function (VpnDeviceType) {
49
+ VpnDeviceType["CAA_LAPTOP"] = "CAA_LAPTOP";
50
+ VpnDeviceType["PERSONAL_DEVICE"] = "PERSONAL_DEVICE";
51
+ VpnDeviceType["MOBILE_DEVICE"] = "MOBILE_DEVICE";
52
+ })(VpnDeviceType || (exports.VpnDeviceType = VpnDeviceType = {}));
53
+ var VpnRequestStatus;
54
+ (function (VpnRequestStatus) {
55
+ VpnRequestStatus["PENDING"] = "PENDING";
56
+ VpnRequestStatus["ASSIGNED"] = "ASSIGNED";
57
+ VpnRequestStatus["IN_PROGRESS"] = "IN_PROGRESS";
58
+ VpnRequestStatus["COMPLETED"] = "COMPLETED";
59
+ VpnRequestStatus["APPROVED"] = "APPROVED";
60
+ VpnRequestStatus["REJECTED"] = "REJECTED";
61
+ })(VpnRequestStatus || (exports.VpnRequestStatus = VpnRequestStatus = {}));
62
+ let VpnRequest = class VpnRequest extends BaseModel_1.BaseModel {
63
+ };
64
+ exports.VpnRequest = VpnRequest;
65
+ __decorate([
66
+ (0, typeorm_1.Column)({ type: "varchar", length: 255, nullable: false }),
67
+ __metadata("design:type", String)
68
+ ], VpnRequest.prototype, "job_title", void 0);
69
+ __decorate([
70
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
71
+ __metadata("design:type", Object)
72
+ ], VpnRequest.prototype, "req_user_department_id", void 0);
73
+ __decorate([
74
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
75
+ __metadata("design:type", Object)
76
+ ], VpnRequest.prototype, "req_user_section_id", void 0);
77
+ __decorate([
78
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
79
+ __metadata("design:type", Object)
80
+ ], VpnRequest.prototype, "req_user_position_id", void 0);
81
+ __decorate([
82
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
83
+ __metadata("design:type", Object)
84
+ ], VpnRequest.prototype, "service_id", void 0);
85
+ __decorate([
86
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
87
+ __metadata("design:type", Object)
88
+ ], VpnRequest.prototype, "sub_service_id", void 0);
89
+ __decorate([
90
+ (0, typeorm_1.Column)({ type: "integer", nullable: false }),
91
+ __metadata("design:type", Number)
92
+ ], VpnRequest.prototype, "user_id", void 0);
93
+ __decorate([
94
+ (0, typeorm_1.Column)({ type: "enum", enum: VpnRequestType, nullable: false }),
95
+ __metadata("design:type", String)
96
+ ], VpnRequest.prototype, "request_for", void 0);
97
+ __decorate([
98
+ (0, typeorm_1.Column)({ type: "varchar", length: 255, nullable: false }),
99
+ __metadata("design:type", String)
100
+ ], VpnRequest.prototype, "employee_identifier", void 0);
101
+ __decorate([
102
+ (0, typeorm_1.Column)({ type: "varchar", length: 255, nullable: false }),
103
+ __metadata("design:type", String)
104
+ ], VpnRequest.prototype, "employee_email", void 0);
105
+ __decorate([
106
+ (0, typeorm_1.Column)({ type: "varchar", length: 50, nullable: false }),
107
+ __metadata("design:type", String)
108
+ ], VpnRequest.prototype, "phone_number", void 0);
109
+ __decorate([
110
+ (0, typeorm_1.Column)({ type: "text", array: true, nullable: false }),
111
+ __metadata("design:type", Array)
112
+ ], VpnRequest.prototype, "reason_for_request", void 0);
113
+ __decorate([
114
+ (0, typeorm_1.Column)({ type: "text", nullable: true }),
115
+ __metadata("design:type", Object)
116
+ ], VpnRequest.prototype, "description", void 0);
117
+ __decorate([
118
+ (0, typeorm_1.Column)({ type: "text", array: true, nullable: false }),
119
+ __metadata("design:type", Array)
120
+ ], VpnRequest.prototype, "systems_to_access", void 0);
121
+ __decorate([
122
+ (0, typeorm_1.Column)({ type: "enum", enum: VpnSourceIpType, nullable: true }),
123
+ __metadata("design:type", Object)
124
+ ], VpnRequest.prototype, "source_ip_type", void 0);
125
+ __decorate([
126
+ (0, typeorm_1.Column)({ type: "varchar", length: 255, nullable: true }),
127
+ __metadata("design:type", Object)
128
+ ], VpnRequest.prototype, "source_ip_address", void 0);
129
+ __decorate([
130
+ (0, typeorm_1.Column)({ type: "varchar", length: 150, nullable: false }),
131
+ __metadata("design:type", String)
132
+ ], VpnRequest.prototype, "country", void 0);
133
+ __decorate([
134
+ (0, typeorm_1.Column)({ type: "date", nullable: false }),
135
+ __metadata("design:type", Date)
136
+ ], VpnRequest.prototype, "start_date", void 0);
137
+ __decorate([
138
+ (0, typeorm_1.Column)({ type: "date", nullable: true }),
139
+ __metadata("design:type", Object)
140
+ ], VpnRequest.prototype, "end_date", void 0);
141
+ __decorate([
142
+ (0, typeorm_1.Column)({ type: "enum", enum: VpnAccessType, nullable: false }),
143
+ __metadata("design:type", String)
144
+ ], VpnRequest.prototype, "access_type", void 0);
145
+ __decorate([
146
+ (0, typeorm_1.Column)({ type: "text", array: true, nullable: false }),
147
+ __metadata("design:type", Array)
148
+ ], VpnRequest.prototype, "device_type", void 0);
149
+ __decorate([
150
+ (0, typeorm_1.Column)({ type: "boolean", default: false, nullable: false }),
151
+ __metadata("design:type", Boolean)
152
+ ], VpnRequest.prototype, "acknowledgement", void 0);
153
+ __decorate([
154
+ (0, typeorm_1.Column)({ type: "enum", enum: VpnRequestStatus, default: VpnRequestStatus.PENDING, nullable: false }),
155
+ __metadata("design:type", String)
156
+ ], VpnRequest.prototype, "status", void 0);
157
+ __decorate([
158
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
159
+ __metadata("design:type", Object)
160
+ ], VpnRequest.prototype, "reviewer_user_id", void 0);
161
+ __decorate([
162
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
163
+ __metadata("design:type", Object)
164
+ ], VpnRequest.prototype, "assigned_to_user_id", void 0);
165
+ __decorate([
166
+ (0, typeorm_1.Column)({ type: "timestamp", nullable: true }),
167
+ __metadata("design:type", Object)
168
+ ], VpnRequest.prototype, "assigned_at", void 0);
169
+ __decorate([
170
+ (0, typeorm_1.Column)({ type: "varchar", length: 255, nullable: true }),
171
+ __metadata("design:type", Object)
172
+ ], VpnRequest.prototype, "workflow_execution_id", void 0);
173
+ exports.VpnRequest = VpnRequest = __decorate([
174
+ (0, typeorm_1.Entity)({ name: "vpn_requests" })
175
+ ], VpnRequest);
@@ -0,0 +1,13 @@
1
+ import { BaseModel } from "./BaseModel";
2
+ export declare enum VpnWorkFlowStatus {
3
+ COMPLETED = "Completed",
4
+ NOT_YET_STARTED = "Not Yet Started",
5
+ PENDING = "Pending"
6
+ }
7
+ export declare class VpnWorkFlow extends BaseModel {
8
+ request_id: number;
9
+ order: number | null;
10
+ content: string;
11
+ status: VpnWorkFlowStatus;
12
+ constructor(request_id: number, content: string, status: VpnWorkFlowStatus, order?: number);
13
+ }
@@ -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
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ exports.VpnWorkFlow = exports.VpnWorkFlowStatus = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ var VpnWorkFlowStatus;
16
+ (function (VpnWorkFlowStatus) {
17
+ VpnWorkFlowStatus["COMPLETED"] = "Completed";
18
+ VpnWorkFlowStatus["NOT_YET_STARTED"] = "Not Yet Started";
19
+ VpnWorkFlowStatus["PENDING"] = "Pending";
20
+ })(VpnWorkFlowStatus || (exports.VpnWorkFlowStatus = VpnWorkFlowStatus = {}));
21
+ let VpnWorkFlow = class VpnWorkFlow extends BaseModel_1.BaseModel {
22
+ constructor(request_id, content, status, order) {
23
+ super();
24
+ this.request_id = request_id;
25
+ this.content = content;
26
+ this.status = status;
27
+ this.order = order || null;
28
+ }
29
+ };
30
+ exports.VpnWorkFlow = VpnWorkFlow;
31
+ __decorate([
32
+ (0, typeorm_1.Column)({ type: "int", nullable: false }),
33
+ __metadata("design:type", Number)
34
+ ], VpnWorkFlow.prototype, "request_id", void 0);
35
+ __decorate([
36
+ (0, typeorm_1.Column)({ type: "int", nullable: true }),
37
+ __metadata("design:type", Object)
38
+ ], VpnWorkFlow.prototype, "order", void 0);
39
+ __decorate([
40
+ (0, typeorm_1.Column)({ type: "varchar", length: 255, nullable: false }),
41
+ __metadata("design:type", String)
42
+ ], VpnWorkFlow.prototype, "content", void 0);
43
+ __decorate([
44
+ (0, typeorm_1.Column)({
45
+ type: "enum",
46
+ enum: VpnWorkFlowStatus,
47
+ default: VpnWorkFlowStatus.NOT_YET_STARTED,
48
+ nullable: false
49
+ }),
50
+ __metadata("design:type", String)
51
+ ], VpnWorkFlow.prototype, "status", void 0);
52
+ exports.VpnWorkFlow = VpnWorkFlow = __decorate([
53
+ (0, typeorm_1.Entity)({ name: "vpn_work_flows" }),
54
+ __metadata("design:paramtypes", [Number, String, String, Number])
55
+ ], VpnWorkFlow);
@@ -0,0 +1,16 @@
1
+ import { BaseModel } from './BaseModel';
2
+ import { CAAServices } from './CAAServices';
3
+ import { CAASubServices } from './CAASubServices';
4
+ export declare class WorkflowDefinitions extends BaseModel {
5
+ name: string;
6
+ description: string;
7
+ version: number;
8
+ is_active: boolean;
9
+ service_type: 'internal' | 'external' | 'none';
10
+ service_id: number | null;
11
+ service: CAAServices;
12
+ sub_service_id: number | null;
13
+ sub_service: CAASubServices;
14
+ status: 'draft' | 'published';
15
+ constructor(name: string, description?: string, version?: number, is_active?: boolean, service_id?: number | null, sub_service_id?: number | null, status?: 'draft' | 'published', service_type?: 'internal' | 'external' | 'none');
16
+ }