@platform-modules/civil-aviation-authority 2.3.71 → 2.3.72

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 (59) hide show
  1. package/.env +9 -17
  2. package/dist/data-source.js +6 -12
  3. package/dist/index.d.ts +196 -113
  4. package/dist/index.js +271 -211
  5. package/dist/models/AirportEntryPermitModel.js +1 -1
  6. package/dist/models/FinancialGradeModel.d.ts +12 -0
  7. package/dist/models/FinancialGradeModel.js +52 -0
  8. package/dist/models/ITApprovalSettings.d.ts +7 -0
  9. package/dist/models/ITApprovalSettings.js +40 -0
  10. package/dist/models/ITServicesTypesMuscatModel.d.ts +6 -0
  11. package/dist/models/{DocumentTypeModel.js → ITServicesTypesMuscatModel.js} +16 -19
  12. package/dist/models/ITServicesTypesSalalahModel.d.ts +6 -0
  13. package/dist/models/ITServicesTypesSalalahModel.js +34 -0
  14. package/dist/models/ShiftAllowanceRequestModel.d.ts +3 -1
  15. package/dist/models/ShiftAllowanceRequestModel.js +12 -2
  16. package/dist/models/Workflows.d.ts +9 -0
  17. package/dist/models/Workflows.js +31 -0
  18. package/package.json +1 -1
  19. package/src/data-source.ts +261 -267
  20. package/src/index.ts +234 -122
  21. package/src/models/AirportEntryPermitModel.ts +1 -1
  22. package/src/models/DepartmentsModel.ts +25 -25
  23. package/src/models/FinancialGradeModel.ts +39 -0
  24. package/src/models/HrServiceRequestModel.ts +167 -167
  25. package/src/models/ITRequestChatModel.ts +62 -62
  26. package/src/models/ItApprovalsModel.ts +84 -84
  27. package/src/models/ItWorkflowModel.ts +55 -55
  28. package/src/models/MissionTravelPassportExpiryNotificationConfigModel.ts +36 -36
  29. package/src/models/RequestForCoverageRequestModel.ts +174 -174
  30. package/src/models/ServicesNotificationConfigModel.ts +55 -55
  31. package/src/models/ShiftAllowanceRequestModel.ts +10 -0
  32. package/src/models/TrainingRoomNotificationConfigModel.ts +30 -30
  33. package/dist/models/DepartmentDocumentOwnerModel.d.ts +0 -10
  34. package/dist/models/DepartmentDocumentOwnerModel.js +0 -44
  35. package/dist/models/DocumentAuditLogModel.d.ts +0 -13
  36. package/dist/models/DocumentAuditLogModel.js +0 -60
  37. package/dist/models/DocumentFolderModel.d.ts +0 -14
  38. package/dist/models/DocumentFolderModel.js +0 -60
  39. package/dist/models/DocumentMetadataModel.d.ts +0 -45
  40. package/dist/models/DocumentMetadataModel.js +0 -171
  41. package/dist/models/DocumentModel.d.ts +0 -25
  42. package/dist/models/DocumentModel.js +0 -96
  43. package/dist/models/DocumentPermissionModel.d.ts +0 -11
  44. package/dist/models/DocumentPermissionModel.js +0 -52
  45. package/dist/models/DocumentTypeModel.d.ts +0 -8
  46. package/dist/models/DocumentationDepartmentsModel.d.ts +0 -13
  47. package/dist/models/DocumentationDepartmentsModel.js +0 -53
  48. package/dist/models/FolderModel.d.ts +0 -16
  49. package/dist/models/FolderModel.js +0 -85
  50. package/dist/models/PermissionModel.d.ts +0 -18
  51. package/dist/models/PermissionModel.js +0 -68
  52. package/dist/models/UUIDBaseModel.d.ts +0 -14
  53. package/dist/models/UUIDBaseModel.js +0 -66
  54. package/src/models/DepartmentDocumentOwnerModel.ts +0 -25
  55. package/src/models/DocumentAuditLogModel.ts +0 -38
  56. package/src/models/DocumentFolderModel.ts +0 -37
  57. package/src/models/DocumentModel.ts +0 -65
  58. package/src/models/DocumentPermissionModel.ts +0 -32
  59. package/src/models/DocumentTypeModel.ts +0 -19
@@ -0,0 +1,12 @@
1
+ import { BaseModel } from './BaseModel';
2
+ /**
3
+ * This model is used to store the Financial Grade master data on the Admin Side
4
+ */
5
+ export declare class FinancialGrade extends BaseModel {
6
+ arabic_title: string | null;
7
+ financial_grade: number | null;
8
+ leave_count: number | null;
9
+ daily_allowance: number | null;
10
+ travel_class: string | null;
11
+ constructor(arabic_title?: string | null, financial_grade?: number | null, leave_count?: number | null, daily_allowance?: number | null, travel_class?: string | null);
12
+ }
@@ -0,0 +1,52 @@
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.FinancialGrade = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ /**
16
+ * This model is used to store the Financial Grade master data on the Admin Side
17
+ */
18
+ let FinancialGrade = class FinancialGrade extends BaseModel_1.BaseModel {
19
+ constructor(arabic_title, financial_grade, leave_count, daily_allowance, travel_class) {
20
+ super();
21
+ this.arabic_title = arabic_title || null;
22
+ this.financial_grade = financial_grade || null;
23
+ this.leave_count = leave_count || null;
24
+ this.daily_allowance = daily_allowance || null;
25
+ this.travel_class = travel_class || null;
26
+ }
27
+ };
28
+ exports.FinancialGrade = FinancialGrade;
29
+ __decorate([
30
+ (0, typeorm_1.Column)({ type: 'varchar', nullable: true }),
31
+ __metadata("design:type", Object)
32
+ ], FinancialGrade.prototype, "arabic_title", void 0);
33
+ __decorate([
34
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
35
+ __metadata("design:type", Object)
36
+ ], FinancialGrade.prototype, "financial_grade", void 0);
37
+ __decorate([
38
+ (0, typeorm_1.Column)({ type: "integer", nullable: true }),
39
+ __metadata("design:type", Object)
40
+ ], FinancialGrade.prototype, "leave_count", void 0);
41
+ __decorate([
42
+ (0, typeorm_1.Column)({ type: "decimal", precision: 10, scale: 2, nullable: true }),
43
+ __metadata("design:type", Object)
44
+ ], FinancialGrade.prototype, "daily_allowance", void 0);
45
+ __decorate([
46
+ (0, typeorm_1.Column)({ type: 'varchar', nullable: true }),
47
+ __metadata("design:type", Object)
48
+ ], FinancialGrade.prototype, "travel_class", void 0);
49
+ exports.FinancialGrade = FinancialGrade = __decorate([
50
+ (0, typeorm_1.Entity)({ name: 'financial_grade' }),
51
+ __metadata("design:paramtypes", [Object, Object, Object, Object, Object])
52
+ ], FinancialGrade);
@@ -0,0 +1,7 @@
1
+ import { BaseModel } from './BaseModel';
2
+ export declare class ITApprovalSettings extends BaseModel {
3
+ level: number;
4
+ approval_role_id: number;
5
+ workflow_id: number;
6
+ constructor(level: number, approval_role_id: number, workflow_id: number);
7
+ }
@@ -0,0 +1,40 @@
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.ITApprovalSettings = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ let ITApprovalSettings = class ITApprovalSettings extends BaseModel_1.BaseModel {
16
+ constructor(level, approval_role_id, workflow_id) {
17
+ super();
18
+ this.level = level;
19
+ this.approval_role_id = approval_role_id;
20
+ this.workflow_id = workflow_id;
21
+ }
22
+ };
23
+ exports.ITApprovalSettings = ITApprovalSettings;
24
+ __decorate([
25
+ (0, typeorm_1.Column)({ type: 'int', nullable: false }),
26
+ __metadata("design:type", Number)
27
+ ], ITApprovalSettings.prototype, "level", void 0);
28
+ __decorate([
29
+ (0, typeorm_1.Column)({ type: 'int', nullable: false }),
30
+ __metadata("design:type", Number)
31
+ ], ITApprovalSettings.prototype, "approval_role_id", void 0);
32
+ __decorate([
33
+ (0, typeorm_1.Column)({ type: 'int', nullable: false }),
34
+ __metadata("design:type", Number)
35
+ ], ITApprovalSettings.prototype, "workflow_id", void 0);
36
+ exports.ITApprovalSettings = ITApprovalSettings = __decorate([
37
+ (0, typeorm_1.Entity)({ name: 'it_approval_settings' }),
38
+ (0, typeorm_1.Unique)(['workflow_id', 'level']),
39
+ __metadata("design:paramtypes", [Number, Number, Number])
40
+ ], ITApprovalSettings);
@@ -0,0 +1,6 @@
1
+ import { BaseModel } from './BaseModel';
2
+ export declare class ITServicesTypesMuscat extends BaseModel {
3
+ name: string;
4
+ name_in_arabic: string;
5
+ constructor(name: string, name_in_arabic: string);
6
+ }
@@ -9,29 +9,26 @@ 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.DocumentType = void 0;
12
+ exports.ITServicesTypesMuscat = void 0;
13
13
  const typeorm_1 = require("typeorm");
14
14
  const BaseModel_1 = require("./BaseModel");
15
- const DocumentModel_1 = require("./DocumentModel");
16
- let DocumentType = class DocumentType extends BaseModel_1.BaseModel {
15
+ let ITServicesTypesMuscat = class ITServicesTypesMuscat extends BaseModel_1.BaseModel {
16
+ constructor(name, name_in_arabic) {
17
+ super();
18
+ this.name = name;
19
+ this.name_in_arabic = name_in_arabic;
20
+ }
17
21
  };
18
- exports.DocumentType = DocumentType;
22
+ exports.ITServicesTypesMuscat = ITServicesTypesMuscat;
19
23
  __decorate([
20
- (0, typeorm_1.Column)({ type: 'varchar', length: 100, nullable: false, unique: true }),
24
+ (0, typeorm_1.Column)({ nullable: false }),
21
25
  __metadata("design:type", String)
22
- ], DocumentType.prototype, "name", void 0);
26
+ ], ITServicesTypesMuscat.prototype, "name", void 0);
23
27
  __decorate([
24
- (0, typeorm_1.Column)({ type: 'text', nullable: true }),
28
+ (0, typeorm_1.Column)({ nullable: false }),
25
29
  __metadata("design:type", String)
26
- ], DocumentType.prototype, "description", void 0);
27
- __decorate([
28
- (0, typeorm_1.Column)({ type: 'boolean', nullable: false, default: true }),
29
- __metadata("design:type", Boolean)
30
- ], DocumentType.prototype, "is_active", void 0);
31
- __decorate([
32
- (0, typeorm_1.OneToMany)(() => DocumentModel_1.Document, document => document.documentType),
33
- __metadata("design:type", Array)
34
- ], DocumentType.prototype, "documents", void 0);
35
- exports.DocumentType = DocumentType = __decorate([
36
- (0, typeorm_1.Entity)({ name: 'document_types' })
37
- ], DocumentType);
30
+ ], ITServicesTypesMuscat.prototype, "name_in_arabic", void 0);
31
+ exports.ITServicesTypesMuscat = ITServicesTypesMuscat = __decorate([
32
+ (0, typeorm_1.Entity)({ name: 'it_services_types_muscat' }),
33
+ __metadata("design:paramtypes", [String, String])
34
+ ], ITServicesTypesMuscat);
@@ -0,0 +1,6 @@
1
+ import { BaseModel } from './BaseModel';
2
+ export declare class ITServicesTypesSalalah extends BaseModel {
3
+ name: string;
4
+ name_in_arabic: string;
5
+ constructor(name: string, name_in_arabic: string);
6
+ }
@@ -0,0 +1,34 @@
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.ITServicesTypesSalalah = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ let ITServicesTypesSalalah = class ITServicesTypesSalalah extends BaseModel_1.BaseModel {
16
+ constructor(name, name_in_arabic) {
17
+ super();
18
+ this.name = name;
19
+ this.name_in_arabic = name_in_arabic;
20
+ }
21
+ };
22
+ exports.ITServicesTypesSalalah = ITServicesTypesSalalah;
23
+ __decorate([
24
+ (0, typeorm_1.Column)({ nullable: false }),
25
+ __metadata("design:type", String)
26
+ ], ITServicesTypesSalalah.prototype, "name", void 0);
27
+ __decorate([
28
+ (0, typeorm_1.Column)({ nullable: false }),
29
+ __metadata("design:type", String)
30
+ ], ITServicesTypesSalalah.prototype, "name_in_arabic", void 0);
31
+ exports.ITServicesTypesSalalah = ITServicesTypesSalalah = __decorate([
32
+ (0, typeorm_1.Entity)({ name: 'it_services_types_salalah' }),
33
+ __metadata("design:paramtypes", [String, String])
34
+ ], ITServicesTypesSalalah);
@@ -32,6 +32,8 @@ export declare class ShiftAllowanceRequest extends BaseModel {
32
32
  allowance_value: ShiftAllowanceValue;
33
33
  shift_start_date: Date;
34
34
  shift_end_date: Date;
35
+ start_time: string | null;
36
+ end_time: string | null;
35
37
  reason_for_request: string | null;
36
- constructor(user_id: number, status?: ShiftAllowanceRequestStatus, service_id?: number | null, sub_service_id?: number | null, req_user_department_id?: number | null, req_user_section_id?: number | null, req_user_position_id?: number | null, description?: string | null, reviewer_user_id?: number | null, assigned_to_user_id?: number | null, assigned_at?: Date | null, workflow_execution_id?: string | null, employee_name?: string, employee_id?: string, job_title?: string, financial_grade?: string, allowance_value?: ShiftAllowanceValue, shift_start_date?: Date, shift_end_date?: Date, reason_for_request?: string | null);
38
+ constructor(user_id: number, status?: ShiftAllowanceRequestStatus, service_id?: number | null, sub_service_id?: number | null, req_user_department_id?: number | null, req_user_section_id?: number | null, req_user_position_id?: number | null, description?: string | null, reviewer_user_id?: number | null, assigned_to_user_id?: number | null, assigned_at?: Date | null, workflow_execution_id?: string | null, employee_name?: string, employee_id?: string, job_title?: string, financial_grade?: string, allowance_value?: ShiftAllowanceValue, shift_start_date?: Date, shift_end_date?: Date, start_time?: string | null, end_time?: string | null, reason_for_request?: string | null);
37
39
  }
@@ -28,7 +28,7 @@ var ShiftAllowanceValue;
28
28
  ShiftAllowanceValue["SEVENTY_PERCENT"] = "70%";
29
29
  })(ShiftAllowanceValue || (exports.ShiftAllowanceValue = ShiftAllowanceValue = {}));
30
30
  let ShiftAllowanceRequest = class ShiftAllowanceRequest extends BaseModel_1.BaseModel {
31
- constructor(user_id, status = ShiftAllowanceRequestStatus.PENDING, service_id, sub_service_id, req_user_department_id, req_user_section_id, req_user_position_id, description, reviewer_user_id, assigned_to_user_id, assigned_at, workflow_execution_id, employee_name, employee_id, job_title, financial_grade, allowance_value, shift_start_date, shift_end_date, reason_for_request) {
31
+ constructor(user_id, status = ShiftAllowanceRequestStatus.PENDING, service_id, sub_service_id, req_user_department_id, req_user_section_id, req_user_position_id, description, reviewer_user_id, assigned_to_user_id, assigned_at, workflow_execution_id, employee_name, employee_id, job_title, financial_grade, allowance_value, shift_start_date, shift_end_date, start_time, end_time, reason_for_request) {
32
32
  super();
33
33
  this.user_id = user_id;
34
34
  this.status = status;
@@ -49,6 +49,8 @@ let ShiftAllowanceRequest = class ShiftAllowanceRequest extends BaseModel_1.Base
49
49
  this.allowance_value = allowance_value || ShiftAllowanceValue.TWENTY_TWO_PERCENT;
50
50
  this.shift_start_date = shift_start_date || new Date();
51
51
  this.shift_end_date = shift_end_date || new Date();
52
+ this.start_time = start_time || null;
53
+ this.end_time = end_time || null;
52
54
  this.reason_for_request = reason_for_request || null;
53
55
  }
54
56
  };
@@ -129,6 +131,14 @@ __decorate([
129
131
  (0, typeorm_1.Column)({ type: "date", nullable: false }),
130
132
  __metadata("design:type", Date)
131
133
  ], ShiftAllowanceRequest.prototype, "shift_end_date", void 0);
134
+ __decorate([
135
+ (0, typeorm_1.Column)({ type: "time", nullable: true }),
136
+ __metadata("design:type", Object)
137
+ ], ShiftAllowanceRequest.prototype, "start_time", void 0);
138
+ __decorate([
139
+ (0, typeorm_1.Column)({ type: "time", nullable: true }),
140
+ __metadata("design:type", Object)
141
+ ], ShiftAllowanceRequest.prototype, "end_time", void 0);
132
142
  __decorate([
133
143
  (0, typeorm_1.Column)({ type: "text", nullable: true }),
134
144
  __metadata("design:type", Object)
@@ -136,5 +146,5 @@ __decorate([
136
146
  exports.ShiftAllowanceRequest = ShiftAllowanceRequest = __decorate([
137
147
  (0, typeorm_1.Entity)({ name: "shift_allowance_requests" }),
138
148
  __metadata("design:paramtypes", [Number, String, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, String, String, String, String, String, Date,
139
- Date, Object])
149
+ Date, Object, Object, Object])
140
150
  ], ShiftAllowanceRequest);
@@ -0,0 +1,9 @@
1
+ import { BaseModel } from './BaseModel';
2
+ export declare class Workflows extends BaseModel {
3
+ name: string;
4
+ service_id: number;
5
+ sub_service_id: number;
6
+ request_for: string;
7
+ levels: number;
8
+ constructor(name: string, service_id: number, sub_service_id: number, request_for: string, levels: number);
9
+ }
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ // import { Column, Entity, Unique } from "typeorm";
3
+ // import { BaseModel } from './BaseModel';
4
+ // @Entity({ name: 'workflows' })
5
+ // @Unique(['service_id', 'sub_service_id', 'request_for'])
6
+ // export class Workflows extends BaseModel {
7
+ // @Column({ type: 'varchar', length: 100, nullable: false })
8
+ // name: string;
9
+ // @Column({ type: 'bigint', nullable: false })
10
+ // service_id: number;
11
+ // @Column({ type: 'bigint', nullable: false })
12
+ // sub_service_id: number;
13
+ // @Column({ type: 'varchar', length: 20, nullable: false })
14
+ // request_for: string; // 'Self' | 'Behalf of' | 'Internal'
15
+ // @Column({ type: 'int', nullable: false })
16
+ // levels: number;
17
+ // constructor(
18
+ // name: string,
19
+ // service_id: number,
20
+ // sub_service_id: number,
21
+ // request_for: string,
22
+ // levels: number,
23
+ // ) {
24
+ // super();
25
+ // this.name = name;
26
+ // this.service_id = service_id;
27
+ // this.sub_service_id = sub_service_id;
28
+ // this.request_for = request_for;
29
+ // this.levels = levels;
30
+ // }
31
+ // }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@platform-modules/civil-aviation-authority",
3
- "version": "2.3.71",
3
+ "version": "2.3.72",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "scripts": {