@platform-modules/civil-aviation-authority 2.3.77 → 2.3.79
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 +9 -14
- package/dist/data-source.js +2 -2
- package/dist/index.d.ts +2 -1
- package/dist/index.js +4 -3
- package/dist/models/DutyMissionRequestModel.d.ts +1 -2
- package/dist/models/DutyMissionRequestModel.js +2 -7
- package/dist/models/FinancialGradeModel.d.ts +2 -3
- package/dist/models/FinancialGradeModel.js +7 -12
- package/dist/models/SkillsEnhancementRequestModel.d.ts +39 -0
- package/dist/models/SkillsEnhancementRequestModel.js +133 -0
- package/dist/models/Workflows.d.ts +9 -0
- package/package.json +1 -1
- package/src/data-source.ts +2 -2
- package/src/index.ts +4 -4
- package/src/models/DutyMissionRequestModel.ts +0 -5
- package/src/models/FinancialGradeModel.ts +5 -10
- package/src/models/HrServiceRequestModel.ts +193 -193
- package/src/models/SkillsEnhancementRequestModel.ts +120 -0
- package/dist/models/CityMasterModel.d.ts +0 -8
- package/dist/models/CityMasterModel.js +0 -41
- package/src/models/CityMasterModel.ts +0 -22
package/.env
CHANGED
|
@@ -1,17 +1,12 @@
|
|
|
1
|
-
# DB_HOST=
|
|
2
|
-
# DB_PORT=
|
|
3
|
-
# DB_USER=
|
|
4
|
-
# DB_PASS=
|
|
1
|
+
# DB_HOST=164.52.222.169
|
|
2
|
+
# DB_PORT=5432
|
|
3
|
+
# DB_USER=postgres_admin_user
|
|
4
|
+
# DB_PASS=pg_admin_user_pwd_caa_fa_$%^&OIukhjgcvbn
|
|
5
5
|
# DB_NAME=CAA
|
|
6
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
|
|
11
|
-
DB_NAME=CAA
|
|
12
7
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
8
|
+
DB_HOST=localhost
|
|
9
|
+
DB_PORT=5432
|
|
10
|
+
DB_USER=postgres
|
|
11
|
+
DB_PASS=stevejobs
|
|
12
|
+
DB_NAME=CAA
|
package/dist/data-source.js
CHANGED
|
@@ -127,7 +127,7 @@ const RequestForCoverageAttachmentModel_1 = require("./models/RequestForCoverage
|
|
|
127
127
|
const CashAllowanceLeaveRequestModel_1 = require("./models/CashAllowanceLeaveRequestModel");
|
|
128
128
|
const PromotionRequestModel_1 = require("./models/PromotionRequestModel");
|
|
129
129
|
const AnnualIncrementRequestModel_1 = require("./models/AnnualIncrementRequestModel");
|
|
130
|
-
const
|
|
130
|
+
const SkillsEnhancementRequestModel_1 = require("./models/SkillsEnhancementRequestModel");
|
|
131
131
|
exports.AppDataSource = new typeorm_1.DataSource({
|
|
132
132
|
type: 'postgres',
|
|
133
133
|
host: process.env.DB_HOST || 'localhost',
|
|
@@ -259,6 +259,6 @@ exports.AppDataSource = new typeorm_1.DataSource({
|
|
|
259
259
|
CashAllowanceLeaveRequestModel_1.CashAllowanceLeaveRequest,
|
|
260
260
|
PromotionRequestModel_1.PromotionRequest,
|
|
261
261
|
AnnualIncrementRequestModel_1.AnnualIncrementRequest,
|
|
262
|
-
|
|
262
|
+
SkillsEnhancementRequestModel_1.SkillsEnhancementRequest
|
|
263
263
|
],
|
|
264
264
|
});
|
package/dist/index.d.ts
CHANGED
|
@@ -188,7 +188,6 @@ export { JobTransferRequestStatus } from './models/JobTransferRequestModel';
|
|
|
188
188
|
export * from './models/NewResourceRequestModel';
|
|
189
189
|
export { NewResourceRequestStatus } from './models/NewResourceRequestModel';
|
|
190
190
|
export * from './models/CountryMasterModel';
|
|
191
|
-
export * from './models/CityMasterModel';
|
|
192
191
|
export * from './models/LocationModel';
|
|
193
192
|
export * from './models/FinancialGradeModel';
|
|
194
193
|
export * from './models/NationalityMasterModel';
|
|
@@ -203,3 +202,5 @@ export * from './models/PromotionRequestModel';
|
|
|
203
202
|
export { PromotionRequestStatus } from './models/PromotionRequestModel';
|
|
204
203
|
export * from './models/AnnualIncrementRequestModel';
|
|
205
204
|
export { AnnualIncrementRequestStatus } from './models/AnnualIncrementRequestModel';
|
|
205
|
+
export * from './models/SkillsEnhancementRequestModel';
|
|
206
|
+
export { SkillsEnhancementRequestStatus } from './models/SkillsEnhancementRequestModel';
|
package/dist/index.js
CHANGED
|
@@ -15,7 +15,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
17
|
exports.RequestForCoverageWorkFlowStatus = exports.RequestForCoverageNewsSize = exports.RequestForCoverageRequestStatus = exports.ServiceTransferRequestType = exports.SalaryDetailsType = exports.ServiceTransferRequestStatus = exports.TemporaryAssignmentRequestType = exports.TemporaryAssignmentRequestStatus = exports.SecondmentRequestStatus = exports.TrainingRoomBookingChatStatus = exports.TrainingRoomBookingMessageType = exports.TrainingRoomBookingRequestChat = exports.TrainingRoomBookingRequestAttachment = exports.TrainingRoomBookingWorkFlowStatus = exports.TrainingRoomBookingApprovalStatus = exports.TrainingRoomBookingRoomType = exports.TrainingRoomBookingRequestStatus = exports.AnnualTrainingPlanChatStatus = exports.AnnualTrainingPlanMessageType = exports.AnnualTrainingPlanRequestChat = exports.AnnualTrainingPlanRequestAttachment = exports.AnnualTrainingPlanWorkFlowStatus = exports.AnnualTrainingPlanApprovalStatus = exports.AnnualTrainingPlanPlace = exports.AnnualTrainingPlanRequestStatus = exports.StudyLeaveChatStatus = exports.StudyLeaveMessageType = exports.StudyLeaveRequestChat = exports.StudyLeaveRequestAttachment = exports.StudyLeaveWorkFlowStatus = exports.StudyLeaveApprovalStatus = exports.StudyLeaveRequestStatus = exports.TrainingMessageType = exports.TrainingRequestChat = exports.TrainingRequestAttachment = exports.TrainingWorkFlowStatus = exports.TrainingApprovalStatus = exports.TrainingRequestStatus = exports.HrServiceChatStatus = exports.HrServiceMessageType = exports.HrServiceRequestChat = exports.HrServiceRequestAttachment = exports.HrServiceWorkFlowStatus = exports.HrServiceApprovalStatus = exports.HrServiceRequestStatus = exports.LogisticsVehicleMaintenanceWorkFlowStatus = exports.LogisticsVehicleMaintenanceMessageType = exports.LogisticsVehicleMaintenanceApprovalStatus = exports.VehicleMaintenanceStatus = exports.VehicleMaintenanceType = void 0;
|
|
18
|
-
exports.AnnualIncrementRequestStatus = exports.PromotionRequestStatus = exports.CashAllowanceLeaveRequestStatus = exports.NotificationFrequency = exports.ServicesNotificationTriggerType = exports.NewResourceRequestStatus = exports.JobTransferRequestStatus = exports.ShiftAllowanceValue = exports.ShiftAllowanceRequestStatus = exports.AssignTasksEmpMessageType = exports.AssignTasksEmpRequestChat = exports.AssignTasksEmpRequestAttachment = exports.AssignTasksEmpWorkFlowStatus = exports.AssignTasksEmpApprovalStatus = exports.AssignTasksEmpPriority = exports.AssignTasksEmpStatus = exports.RequestForCoverageRequestAttachment = exports.RequestForCoverageChatStatus = exports.RequestForCoverageMessageType = exports.RequestForCoverageRequestChat = exports.RequestForCoverageApprovalStatus = void 0;
|
|
18
|
+
exports.SkillsEnhancementRequestStatus = exports.AnnualIncrementRequestStatus = exports.PromotionRequestStatus = exports.CashAllowanceLeaveRequestStatus = exports.NotificationFrequency = exports.ServicesNotificationTriggerType = exports.NewResourceRequestStatus = exports.JobTransferRequestStatus = exports.ShiftAllowanceValue = exports.ShiftAllowanceRequestStatus = exports.AssignTasksEmpMessageType = exports.AssignTasksEmpRequestChat = exports.AssignTasksEmpRequestAttachment = exports.AssignTasksEmpWorkFlowStatus = exports.AssignTasksEmpApprovalStatus = exports.AssignTasksEmpPriority = exports.AssignTasksEmpStatus = exports.RequestForCoverageRequestAttachment = exports.RequestForCoverageChatStatus = exports.RequestForCoverageMessageType = exports.RequestForCoverageRequestChat = exports.RequestForCoverageApprovalStatus = void 0;
|
|
19
19
|
__exportStar(require("./models/user"), exports);
|
|
20
20
|
__exportStar(require("./models/role"), exports);
|
|
21
21
|
__exportStar(require("./models/user-sessions"), exports);
|
|
@@ -279,8 +279,6 @@ var NewResourceRequestModel_1 = require("./models/NewResourceRequestModel");
|
|
|
279
279
|
Object.defineProperty(exports, "NewResourceRequestStatus", { enumerable: true, get: function () { return NewResourceRequestModel_1.NewResourceRequestStatus; } });
|
|
280
280
|
// Country Master
|
|
281
281
|
__exportStar(require("./models/CountryMasterModel"), exports);
|
|
282
|
-
// City Master
|
|
283
|
-
__exportStar(require("./models/CityMasterModel"), exports);
|
|
284
282
|
// Location Master
|
|
285
283
|
__exportStar(require("./models/LocationModel"), exports);
|
|
286
284
|
// Financial Grade Master
|
|
@@ -308,3 +306,6 @@ Object.defineProperty(exports, "PromotionRequestStatus", { enumerable: true, get
|
|
|
308
306
|
__exportStar(require("./models/AnnualIncrementRequestModel"), exports);
|
|
309
307
|
var AnnualIncrementRequestModel_1 = require("./models/AnnualIncrementRequestModel");
|
|
310
308
|
Object.defineProperty(exports, "AnnualIncrementRequestStatus", { enumerable: true, get: function () { return AnnualIncrementRequestModel_1.AnnualIncrementRequestStatus; } });
|
|
309
|
+
__exportStar(require("./models/SkillsEnhancementRequestModel"), exports);
|
|
310
|
+
var SkillsEnhancementRequestModel_1 = require("./models/SkillsEnhancementRequestModel");
|
|
311
|
+
Object.defineProperty(exports, "SkillsEnhancementRequestStatus", { enumerable: true, get: function () { return SkillsEnhancementRequestModel_1.SkillsEnhancementRequestStatus; } });
|
|
@@ -61,6 +61,5 @@ export declare class DutyMissionRequests extends BaseModel {
|
|
|
61
61
|
vehicle_required: VehicleRequired | null;
|
|
62
62
|
remarks: string | null;
|
|
63
63
|
decision_number: string | null;
|
|
64
|
-
|
|
65
|
-
constructor(req_user_department_id: number | null, req_user_section_id: number | null, service_id: number, sub_service_id: number, user_id: number, trip_type: TripType, choose_type: ChooseType, mission_sponsored_by: MissionSponsoredBy, mission_purpose: string, mission_number: string, mission_start_date: Date, mission_end_date: Date, travelling_area_from: string, travelling_area_to: string, from_country: string, to_country: string, travel_place: string, travel_start_date: Date, travel_return_date: Date, status: DutyMissionStatus, request_id?: string | null, mission_id?: string | null, mission_days?: number | null, distance?: string | null, if_sponsored?: string | null, allowance_percentage?: string | null, air_ticket_required?: AirTicketRequired | null, vehicle_required?: VehicleRequired | null, remarks?: string | null, decision_number?: string | null, decision_date?: Date | null, workflow_execution_id?: string | null);
|
|
64
|
+
constructor(req_user_department_id: number | null, req_user_section_id: number | null, service_id: number, sub_service_id: number, user_id: number, trip_type: TripType, choose_type: ChooseType, mission_sponsored_by: MissionSponsoredBy, mission_purpose: string, mission_number: string, mission_start_date: Date, mission_end_date: Date, travelling_area_from: string, travelling_area_to: string, from_country: string, to_country: string, travel_place: string, travel_start_date: Date, travel_return_date: Date, status: DutyMissionStatus, request_id?: string | null, mission_id?: string | null, mission_days?: number | null, distance?: string | null, if_sponsored?: string | null, allowance_percentage?: string | null, air_ticket_required?: AirTicketRequired | null, vehicle_required?: VehicleRequired | null, remarks?: string | null, decision_number?: string | null, workflow_execution_id?: string | null);
|
|
66
65
|
}
|
|
@@ -49,7 +49,7 @@ var DutyMissionStatus;
|
|
|
49
49
|
DutyMissionStatus["REJECTED"] = "Rejected";
|
|
50
50
|
})(DutyMissionStatus || (exports.DutyMissionStatus = DutyMissionStatus = {}));
|
|
51
51
|
let DutyMissionRequests = class DutyMissionRequests extends BaseModel_1.BaseModel {
|
|
52
|
-
constructor(req_user_department_id, req_user_section_id, service_id, sub_service_id, user_id, trip_type, choose_type, mission_sponsored_by, mission_purpose, mission_number, mission_start_date, mission_end_date, travelling_area_from, travelling_area_to, from_country, to_country, travel_place, travel_start_date, travel_return_date, status, request_id, mission_id, mission_days, distance, if_sponsored, allowance_percentage, air_ticket_required, vehicle_required, remarks, decision_number,
|
|
52
|
+
constructor(req_user_department_id, req_user_section_id, service_id, sub_service_id, user_id, trip_type, choose_type, mission_sponsored_by, mission_purpose, mission_number, mission_start_date, mission_end_date, travelling_area_from, travelling_area_to, from_country, to_country, travel_place, travel_start_date, travel_return_date, status, request_id, mission_id, mission_days, distance, if_sponsored, allowance_percentage, air_ticket_required, vehicle_required, remarks, decision_number, workflow_execution_id) {
|
|
53
53
|
super();
|
|
54
54
|
this.req_user_department_id = req_user_department_id ?? null;
|
|
55
55
|
this.req_user_section_id = req_user_section_id ?? null;
|
|
@@ -81,7 +81,6 @@ let DutyMissionRequests = class DutyMissionRequests extends BaseModel_1.BaseMode
|
|
|
81
81
|
this.vehicle_required = vehicle_required ?? null;
|
|
82
82
|
this.remarks = remarks ?? null;
|
|
83
83
|
this.decision_number = decision_number ?? null;
|
|
84
|
-
this.decision_date = decision_date ?? null;
|
|
85
84
|
this.workflow_execution_id = workflow_execution_id ?? null;
|
|
86
85
|
}
|
|
87
86
|
};
|
|
@@ -235,13 +234,9 @@ __decorate([
|
|
|
235
234
|
(0, typeorm_1.Column)({ type: 'varchar', length: 100, nullable: true }),
|
|
236
235
|
__metadata("design:type", Object)
|
|
237
236
|
], DutyMissionRequests.prototype, "decision_number", void 0);
|
|
238
|
-
__decorate([
|
|
239
|
-
(0, typeorm_1.Column)({ type: 'timestamp', nullable: true }),
|
|
240
|
-
__metadata("design:type", Object)
|
|
241
|
-
], DutyMissionRequests.prototype, "decision_date", void 0);
|
|
242
237
|
exports.DutyMissionRequests = DutyMissionRequests = __decorate([
|
|
243
238
|
(0, typeorm_1.Entity)({ name: 'duty_mission_requests' }),
|
|
244
239
|
__metadata("design:paramtypes", [Object, Object, Number, Number, Number, String, String, String, String, String, Date,
|
|
245
240
|
Date, String, String, String, String, String, Date,
|
|
246
|
-
Date, String, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object
|
|
241
|
+
Date, String, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object])
|
|
247
242
|
], DutyMissionRequests);
|
|
@@ -3,11 +3,10 @@ import { BaseModel } from './BaseModel';
|
|
|
3
3
|
* This model is used to store the Financial Grade master data on the Admin Side
|
|
4
4
|
*/
|
|
5
5
|
export declare class FinancialGrade extends BaseModel {
|
|
6
|
-
arabic_title: string | null;
|
|
7
6
|
financial_grade: number | null;
|
|
8
|
-
leave_count: number | null;
|
|
9
7
|
daily_allowance: number | null;
|
|
10
8
|
travel_class: string | null;
|
|
9
|
+
currency: string | null;
|
|
11
10
|
is_active: boolean;
|
|
12
|
-
constructor(
|
|
11
|
+
constructor(financial_grade?: number | null, daily_allowance?: number | null, travel_class?: string | null, currency?: string | null, is_active?: boolean);
|
|
13
12
|
}
|
|
@@ -16,29 +16,20 @@ const BaseModel_1 = require("./BaseModel");
|
|
|
16
16
|
* This model is used to store the Financial Grade master data on the Admin Side
|
|
17
17
|
*/
|
|
18
18
|
let FinancialGrade = class FinancialGrade extends BaseModel_1.BaseModel {
|
|
19
|
-
constructor(
|
|
19
|
+
constructor(financial_grade, daily_allowance, travel_class, currency, is_active) {
|
|
20
20
|
super();
|
|
21
|
-
this.arabic_title = arabic_title || null;
|
|
22
21
|
this.financial_grade = financial_grade || null;
|
|
23
|
-
this.leave_count = leave_count || null;
|
|
24
22
|
this.daily_allowance = daily_allowance || null;
|
|
25
23
|
this.travel_class = travel_class || null;
|
|
24
|
+
this.currency = currency || null;
|
|
26
25
|
this.is_active = is_active !== undefined ? is_active : true;
|
|
27
26
|
}
|
|
28
27
|
};
|
|
29
28
|
exports.FinancialGrade = FinancialGrade;
|
|
30
|
-
__decorate([
|
|
31
|
-
(0, typeorm_1.Column)({ type: 'varchar', nullable: true }),
|
|
32
|
-
__metadata("design:type", Object)
|
|
33
|
-
], FinancialGrade.prototype, "arabic_title", void 0);
|
|
34
29
|
__decorate([
|
|
35
30
|
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
36
31
|
__metadata("design:type", Object)
|
|
37
32
|
], FinancialGrade.prototype, "financial_grade", void 0);
|
|
38
|
-
__decorate([
|
|
39
|
-
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
40
|
-
__metadata("design:type", Object)
|
|
41
|
-
], FinancialGrade.prototype, "leave_count", void 0);
|
|
42
33
|
__decorate([
|
|
43
34
|
(0, typeorm_1.Column)({ type: "decimal", precision: 10, scale: 2, nullable: true }),
|
|
44
35
|
__metadata("design:type", Object)
|
|
@@ -47,11 +38,15 @@ __decorate([
|
|
|
47
38
|
(0, typeorm_1.Column)({ type: 'varchar', nullable: true }),
|
|
48
39
|
__metadata("design:type", Object)
|
|
49
40
|
], FinancialGrade.prototype, "travel_class", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
(0, typeorm_1.Column)({ type: 'varchar', length: 10, nullable: true }),
|
|
43
|
+
__metadata("design:type", Object)
|
|
44
|
+
], FinancialGrade.prototype, "currency", void 0);
|
|
50
45
|
__decorate([
|
|
51
46
|
(0, typeorm_1.Column)({ type: 'boolean', default: true }),
|
|
52
47
|
__metadata("design:type", Boolean)
|
|
53
48
|
], FinancialGrade.prototype, "is_active", void 0);
|
|
54
49
|
exports.FinancialGrade = FinancialGrade = __decorate([
|
|
55
50
|
(0, typeorm_1.Entity)({ name: 'financial_grade' }),
|
|
56
|
-
__metadata("design:paramtypes", [Object, Object, Object, Object,
|
|
51
|
+
__metadata("design:paramtypes", [Object, Object, Object, Object, Boolean])
|
|
57
52
|
], FinancialGrade);
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { BaseModel } from "./BaseModel";
|
|
2
|
+
export declare enum SkillsEnhancementRequestStatus {
|
|
3
|
+
PENDING = "Pending",
|
|
4
|
+
ASSIGNED = "Assigned",
|
|
5
|
+
IN_PROGRESS = "In Progress",
|
|
6
|
+
COMPLETED = "Completed",
|
|
7
|
+
APPROVED = "Approved",
|
|
8
|
+
REJECTED = "Rejected",
|
|
9
|
+
INFORMATION_REQUESTED = "Information Requested"
|
|
10
|
+
}
|
|
11
|
+
export declare enum SkillCategory {
|
|
12
|
+
TECHNICAL = "Technical",
|
|
13
|
+
COMPLIANCE = "Compliance",
|
|
14
|
+
MANAGEMENT = "Management",
|
|
15
|
+
SAFETY = "Safety",
|
|
16
|
+
SOFT_SKILLS = "Soft Skills",
|
|
17
|
+
OTHER = "Other"
|
|
18
|
+
}
|
|
19
|
+
export declare class SkillsEnhancementRequest extends BaseModel {
|
|
20
|
+
req_user_department_id: number | null;
|
|
21
|
+
req_user_section_id: number | null;
|
|
22
|
+
req_user_position_id: number | null;
|
|
23
|
+
user_id: number;
|
|
24
|
+
service_id: number | null;
|
|
25
|
+
sub_service_id: number | null;
|
|
26
|
+
status: SkillsEnhancementRequestStatus;
|
|
27
|
+
reviewer_user_id: number | null;
|
|
28
|
+
assigned_to_user_id: number | null;
|
|
29
|
+
assigned_at: Date | null;
|
|
30
|
+
workflow_execution_id: string | null;
|
|
31
|
+
description: string | null;
|
|
32
|
+
certification_title: string;
|
|
33
|
+
skill_category: SkillCategory;
|
|
34
|
+
issuing_authority: string;
|
|
35
|
+
completion_date: Date;
|
|
36
|
+
skill_summary: string | null;
|
|
37
|
+
additional_info_requested: string | null;
|
|
38
|
+
constructor(user_id: number, status?: SkillsEnhancementRequestStatus, 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, certification_title?: string, skill_category?: SkillCategory, issuing_authority?: string, completion_date?: Date, skill_summary?: string | null, additional_info_requested?: string | null);
|
|
39
|
+
}
|
|
@@ -0,0 +1,133 @@
|
|
|
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.SkillsEnhancementRequest = exports.SkillCategory = exports.SkillsEnhancementRequestStatus = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
const BaseModel_1 = require("./BaseModel");
|
|
15
|
+
var SkillsEnhancementRequestStatus;
|
|
16
|
+
(function (SkillsEnhancementRequestStatus) {
|
|
17
|
+
SkillsEnhancementRequestStatus["PENDING"] = "Pending";
|
|
18
|
+
SkillsEnhancementRequestStatus["ASSIGNED"] = "Assigned";
|
|
19
|
+
SkillsEnhancementRequestStatus["IN_PROGRESS"] = "In Progress";
|
|
20
|
+
SkillsEnhancementRequestStatus["COMPLETED"] = "Completed";
|
|
21
|
+
SkillsEnhancementRequestStatus["APPROVED"] = "Approved";
|
|
22
|
+
SkillsEnhancementRequestStatus["REJECTED"] = "Rejected";
|
|
23
|
+
SkillsEnhancementRequestStatus["INFORMATION_REQUESTED"] = "Information Requested";
|
|
24
|
+
})(SkillsEnhancementRequestStatus || (exports.SkillsEnhancementRequestStatus = SkillsEnhancementRequestStatus = {}));
|
|
25
|
+
var SkillCategory;
|
|
26
|
+
(function (SkillCategory) {
|
|
27
|
+
SkillCategory["TECHNICAL"] = "Technical";
|
|
28
|
+
SkillCategory["COMPLIANCE"] = "Compliance";
|
|
29
|
+
SkillCategory["MANAGEMENT"] = "Management";
|
|
30
|
+
SkillCategory["SAFETY"] = "Safety";
|
|
31
|
+
SkillCategory["SOFT_SKILLS"] = "Soft Skills";
|
|
32
|
+
SkillCategory["OTHER"] = "Other";
|
|
33
|
+
})(SkillCategory || (exports.SkillCategory = SkillCategory = {}));
|
|
34
|
+
let SkillsEnhancementRequest = class SkillsEnhancementRequest extends BaseModel_1.BaseModel {
|
|
35
|
+
constructor(user_id, status = SkillsEnhancementRequestStatus.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, certification_title, skill_category, issuing_authority, completion_date, skill_summary, additional_info_requested) {
|
|
36
|
+
super();
|
|
37
|
+
this.user_id = user_id;
|
|
38
|
+
this.status = status;
|
|
39
|
+
this.service_id = service_id || null;
|
|
40
|
+
this.sub_service_id = sub_service_id || null;
|
|
41
|
+
this.req_user_department_id = req_user_department_id || null;
|
|
42
|
+
this.req_user_section_id = req_user_section_id || null;
|
|
43
|
+
this.req_user_position_id = req_user_position_id || null;
|
|
44
|
+
this.description = description || null;
|
|
45
|
+
this.reviewer_user_id = reviewer_user_id || null;
|
|
46
|
+
this.assigned_to_user_id = assigned_to_user_id || null;
|
|
47
|
+
this.assigned_at = assigned_at || null;
|
|
48
|
+
this.workflow_execution_id = workflow_execution_id || null;
|
|
49
|
+
this.certification_title = certification_title || "";
|
|
50
|
+
this.skill_category = skill_category || SkillCategory.TECHNICAL;
|
|
51
|
+
this.issuing_authority = issuing_authority || "";
|
|
52
|
+
this.completion_date = completion_date || new Date();
|
|
53
|
+
this.skill_summary = skill_summary || null;
|
|
54
|
+
this.additional_info_requested = additional_info_requested || null;
|
|
55
|
+
}
|
|
56
|
+
};
|
|
57
|
+
exports.SkillsEnhancementRequest = SkillsEnhancementRequest;
|
|
58
|
+
__decorate([
|
|
59
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
60
|
+
__metadata("design:type", Object)
|
|
61
|
+
], SkillsEnhancementRequest.prototype, "req_user_department_id", void 0);
|
|
62
|
+
__decorate([
|
|
63
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
64
|
+
__metadata("design:type", Object)
|
|
65
|
+
], SkillsEnhancementRequest.prototype, "req_user_section_id", void 0);
|
|
66
|
+
__decorate([
|
|
67
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
68
|
+
__metadata("design:type", Object)
|
|
69
|
+
], SkillsEnhancementRequest.prototype, "req_user_position_id", void 0);
|
|
70
|
+
__decorate([
|
|
71
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: false }),
|
|
72
|
+
__metadata("design:type", Number)
|
|
73
|
+
], SkillsEnhancementRequest.prototype, "user_id", void 0);
|
|
74
|
+
__decorate([
|
|
75
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
76
|
+
__metadata("design:type", Object)
|
|
77
|
+
], SkillsEnhancementRequest.prototype, "service_id", void 0);
|
|
78
|
+
__decorate([
|
|
79
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
80
|
+
__metadata("design:type", Object)
|
|
81
|
+
], SkillsEnhancementRequest.prototype, "sub_service_id", void 0);
|
|
82
|
+
__decorate([
|
|
83
|
+
(0, typeorm_1.Column)({ type: "enum", enum: SkillsEnhancementRequestStatus, default: SkillsEnhancementRequestStatus.PENDING, nullable: false }),
|
|
84
|
+
__metadata("design:type", String)
|
|
85
|
+
], SkillsEnhancementRequest.prototype, "status", void 0);
|
|
86
|
+
__decorate([
|
|
87
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
88
|
+
__metadata("design:type", Object)
|
|
89
|
+
], SkillsEnhancementRequest.prototype, "reviewer_user_id", void 0);
|
|
90
|
+
__decorate([
|
|
91
|
+
(0, typeorm_1.Column)({ type: "integer", nullable: true }),
|
|
92
|
+
__metadata("design:type", Object)
|
|
93
|
+
], SkillsEnhancementRequest.prototype, "assigned_to_user_id", void 0);
|
|
94
|
+
__decorate([
|
|
95
|
+
(0, typeorm_1.Column)({ type: "timestamp", nullable: true }),
|
|
96
|
+
__metadata("design:type", Object)
|
|
97
|
+
], SkillsEnhancementRequest.prototype, "assigned_at", void 0);
|
|
98
|
+
__decorate([
|
|
99
|
+
(0, typeorm_1.Column)({ type: "varchar", length: 255, nullable: true }),
|
|
100
|
+
__metadata("design:type", Object)
|
|
101
|
+
], SkillsEnhancementRequest.prototype, "workflow_execution_id", void 0);
|
|
102
|
+
__decorate([
|
|
103
|
+
(0, typeorm_1.Column)({ type: "text", nullable: true }),
|
|
104
|
+
__metadata("design:type", Object)
|
|
105
|
+
], SkillsEnhancementRequest.prototype, "description", void 0);
|
|
106
|
+
__decorate([
|
|
107
|
+
(0, typeorm_1.Column)({ type: "varchar", length: 255, nullable: false }),
|
|
108
|
+
__metadata("design:type", String)
|
|
109
|
+
], SkillsEnhancementRequest.prototype, "certification_title", void 0);
|
|
110
|
+
__decorate([
|
|
111
|
+
(0, typeorm_1.Column)({ type: "enum", enum: SkillCategory, nullable: false }),
|
|
112
|
+
__metadata("design:type", String)
|
|
113
|
+
], SkillsEnhancementRequest.prototype, "skill_category", void 0);
|
|
114
|
+
__decorate([
|
|
115
|
+
(0, typeorm_1.Column)({ type: "varchar", length: 255, nullable: false }),
|
|
116
|
+
__metadata("design:type", String)
|
|
117
|
+
], SkillsEnhancementRequest.prototype, "issuing_authority", void 0);
|
|
118
|
+
__decorate([
|
|
119
|
+
(0, typeorm_1.Column)({ type: "date", nullable: false }),
|
|
120
|
+
__metadata("design:type", Date)
|
|
121
|
+
], SkillsEnhancementRequest.prototype, "completion_date", void 0);
|
|
122
|
+
__decorate([
|
|
123
|
+
(0, typeorm_1.Column)({ type: "text", nullable: true }),
|
|
124
|
+
__metadata("design:type", Object)
|
|
125
|
+
], SkillsEnhancementRequest.prototype, "skill_summary", void 0);
|
|
126
|
+
__decorate([
|
|
127
|
+
(0, typeorm_1.Column)({ type: "text", nullable: true }),
|
|
128
|
+
__metadata("design:type", Object)
|
|
129
|
+
], SkillsEnhancementRequest.prototype, "additional_info_requested", void 0);
|
|
130
|
+
exports.SkillsEnhancementRequest = SkillsEnhancementRequest = __decorate([
|
|
131
|
+
(0, typeorm_1.Entity)({ name: "skills_enhancement_requests" }),
|
|
132
|
+
__metadata("design:paramtypes", [Number, String, Object, Object, Object, Object, Object, Object, Object, Object, Object, Object, String, String, String, Date, Object, Object])
|
|
133
|
+
], SkillsEnhancementRequest);
|
|
@@ -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
|
+
}
|
package/package.json
CHANGED
package/src/data-source.ts
CHANGED
|
@@ -125,7 +125,7 @@ import { RequestForCoverageRequestAttachment } from './models/RequestForCoverage
|
|
|
125
125
|
import { CashAllowanceLeaveRequest } from './models/CashAllowanceLeaveRequestModel';
|
|
126
126
|
import { PromotionRequest } from './models/PromotionRequestModel';
|
|
127
127
|
import { AnnualIncrementRequest } from './models/AnnualIncrementRequestModel';
|
|
128
|
-
import {
|
|
128
|
+
import { SkillsEnhancementRequest } from './models/SkillsEnhancementRequestModel';
|
|
129
129
|
|
|
130
130
|
export const AppDataSource = new DataSource({
|
|
131
131
|
type: 'postgres',
|
|
@@ -258,6 +258,6 @@ export const AppDataSource = new DataSource({
|
|
|
258
258
|
CashAllowanceLeaveRequest,
|
|
259
259
|
PromotionRequest,
|
|
260
260
|
AnnualIncrementRequest,
|
|
261
|
-
|
|
261
|
+
SkillsEnhancementRequest
|
|
262
262
|
],
|
|
263
263
|
});
|
package/src/index.ts
CHANGED
|
@@ -202,9 +202,6 @@ export {NewResourceRequestStatus} from './models/NewResourceRequestModel';
|
|
|
202
202
|
// Country Master
|
|
203
203
|
export * from './models/CountryMasterModel';
|
|
204
204
|
|
|
205
|
-
// City Master
|
|
206
|
-
export * from './models/CityMasterModel';
|
|
207
|
-
|
|
208
205
|
// Location Master
|
|
209
206
|
export * from './models/LocationModel';
|
|
210
207
|
|
|
@@ -234,4 +231,7 @@ export { PromotionRequestStatus } from './models/PromotionRequestModel';
|
|
|
234
231
|
|
|
235
232
|
// Annual Increment (Periodic Allowance) Request Service
|
|
236
233
|
export * from './models/AnnualIncrementRequestModel';
|
|
237
|
-
export { AnnualIncrementRequestStatus } from './models/AnnualIncrementRequestModel';
|
|
234
|
+
export { AnnualIncrementRequestStatus } from './models/AnnualIncrementRequestModel';
|
|
235
|
+
|
|
236
|
+
export * from './models/SkillsEnhancementRequestModel';
|
|
237
|
+
export { SkillsEnhancementRequestStatus } from './models/SkillsEnhancementRequestModel';
|
|
@@ -160,9 +160,6 @@ export class DutyMissionRequests extends BaseModel {
|
|
|
160
160
|
@Column({ type: 'varchar', length: 100, nullable: true })
|
|
161
161
|
decision_number: string | null;
|
|
162
162
|
|
|
163
|
-
@Column({ type: 'timestamp', nullable: true })
|
|
164
|
-
decision_date: Date | null;
|
|
165
|
-
|
|
166
163
|
constructor(
|
|
167
164
|
req_user_department_id: number | null,
|
|
168
165
|
req_user_section_id: number | null,
|
|
@@ -194,7 +191,6 @@ export class DutyMissionRequests extends BaseModel {
|
|
|
194
191
|
vehicle_required?: VehicleRequired | null,
|
|
195
192
|
remarks?: string | null,
|
|
196
193
|
decision_number?: string | null,
|
|
197
|
-
decision_date?: Date | null,
|
|
198
194
|
workflow_execution_id?: string | null,
|
|
199
195
|
) {
|
|
200
196
|
super();
|
|
@@ -228,7 +224,6 @@ export class DutyMissionRequests extends BaseModel {
|
|
|
228
224
|
this.vehicle_required = vehicle_required ?? null;
|
|
229
225
|
this.remarks = remarks ?? null;
|
|
230
226
|
this.decision_number = decision_number ?? null;
|
|
231
|
-
this.decision_date = decision_date ?? null;
|
|
232
227
|
this.workflow_execution_id = workflow_execution_id ?? null;
|
|
233
228
|
}
|
|
234
229
|
}
|
|
@@ -7,38 +7,33 @@ import { BaseModel } from './BaseModel';
|
|
|
7
7
|
@Entity({ name: 'financial_grade' })
|
|
8
8
|
export class FinancialGrade extends BaseModel {
|
|
9
9
|
|
|
10
|
-
@Column({ type: 'varchar', nullable: true })
|
|
11
|
-
arabic_title: string | null;
|
|
12
|
-
|
|
13
10
|
@Column({ type: "integer", nullable: true })
|
|
14
11
|
financial_grade: number | null;
|
|
15
12
|
|
|
16
|
-
@Column({ type: "integer", nullable: true })
|
|
17
|
-
leave_count: number | null;
|
|
18
|
-
|
|
19
13
|
@Column({ type: "decimal", precision: 10, scale: 2, nullable: true })
|
|
20
14
|
daily_allowance: number | null;
|
|
21
15
|
|
|
22
16
|
@Column({ type: 'varchar', nullable: true })
|
|
23
17
|
travel_class: string | null;
|
|
24
18
|
|
|
19
|
+
@Column({ type: 'varchar', length: 10, nullable: true})
|
|
20
|
+
currency: string | null;
|
|
21
|
+
|
|
25
22
|
@Column({ type: 'boolean', default: true })
|
|
26
23
|
is_active: boolean;
|
|
27
24
|
|
|
28
25
|
constructor(
|
|
29
|
-
arabic_title?: string | null,
|
|
30
26
|
financial_grade?: number | null,
|
|
31
|
-
leave_count?: number | null,
|
|
32
27
|
daily_allowance?: number | null,
|
|
33
28
|
travel_class?: string | null,
|
|
29
|
+
currency?: string | null,
|
|
34
30
|
is_active?: boolean
|
|
35
31
|
) {
|
|
36
32
|
super();
|
|
37
|
-
this.arabic_title = arabic_title || null;
|
|
38
33
|
this.financial_grade = financial_grade || null;
|
|
39
|
-
this.leave_count = leave_count || null;
|
|
40
34
|
this.daily_allowance = daily_allowance || null;
|
|
41
35
|
this.travel_class = travel_class || null;
|
|
36
|
+
this.currency = currency || null;
|
|
42
37
|
this.is_active = is_active !== undefined ? is_active : true;
|
|
43
38
|
}
|
|
44
39
|
}
|
|
@@ -1,193 +1,193 @@
|
|
|
1
|
-
import { Column, Entity } from "typeorm";
|
|
2
|
-
import { BaseModel } from "./BaseModel";
|
|
3
|
-
|
|
4
|
-
export enum HrServiceRequestStatus {
|
|
5
|
-
PENDING = "Pending",
|
|
6
|
-
ASSIGNED = "Assigned",
|
|
7
|
-
IN_PROGRESS = "In Progress",
|
|
8
|
-
COMPLETED = "Completed",
|
|
9
|
-
APPROVED = "Approved",
|
|
10
|
-
REJECTED = "Rejected"
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
@Entity({ name: "hr_service_requests" })
|
|
14
|
-
export class HrServiceRequest extends BaseModel {
|
|
15
|
-
@Column({ type: "integer", nullable: true })
|
|
16
|
-
req_user_department_id: number | null;
|
|
17
|
-
|
|
18
|
-
@Column({ type: "integer", nullable: true })
|
|
19
|
-
req_user_section_id: number | null;
|
|
20
|
-
|
|
21
|
-
@Column({ type: "integer", nullable: true })
|
|
22
|
-
req_user_position_id: number | null;
|
|
23
|
-
|
|
24
|
-
@Column({ type: "integer", nullable: true })
|
|
25
|
-
service_id: number | null;
|
|
26
|
-
|
|
27
|
-
@Column({ type: "integer", nullable: true })
|
|
28
|
-
sub_service_id: number | null;
|
|
29
|
-
|
|
30
|
-
@Column({ type: "integer", nullable: false })
|
|
31
|
-
user_id: number;
|
|
32
|
-
|
|
33
|
-
@Column({ type: "text", nullable: true })
|
|
34
|
-
description: string | null;
|
|
35
|
-
|
|
36
|
-
@Column({ type: "enum", enum: HrServiceRequestStatus, default: HrServiceRequestStatus.PENDING, nullable: false })
|
|
37
|
-
status: HrServiceRequestStatus;
|
|
38
|
-
|
|
39
|
-
@Column({ type: "integer", nullable: true })
|
|
40
|
-
reviewer_user_id: number | null;
|
|
41
|
-
|
|
42
|
-
@Column({ type: "integer", nullable: true })
|
|
43
|
-
assigned_to_user_id: number | null;
|
|
44
|
-
|
|
45
|
-
@Column({ type: "timestamp", nullable: true })
|
|
46
|
-
assigned_at: Date | null;
|
|
47
|
-
|
|
48
|
-
@Column({ type: "varchar", length: 255, nullable: true })
|
|
49
|
-
workflow_execution_id: string | null;
|
|
50
|
-
|
|
51
|
-
// Assignment Decision specific fields
|
|
52
|
-
@Column({ type: "varchar", length: 255, nullable: false })
|
|
53
|
-
assigned_employee_name: string;
|
|
54
|
-
|
|
55
|
-
@Column({ type: "varchar", length: 50, nullable: true })
|
|
56
|
-
civil_id_card_number: string | null;
|
|
57
|
-
|
|
58
|
-
@Column({ type: "varchar", length: 100, nullable: false })
|
|
59
|
-
employee_id: string;
|
|
60
|
-
|
|
61
|
-
@Column({ type: "varchar", length: 255, nullable: false })
|
|
62
|
-
current_job_position: string;
|
|
63
|
-
|
|
64
|
-
@Column({ type: "varchar", length: 255, nullable: false })
|
|
65
|
-
assigned_job_position: string;
|
|
66
|
-
|
|
67
|
-
@Column({ type: "date", nullable: false })
|
|
68
|
-
start_date: Date;
|
|
69
|
-
|
|
70
|
-
@Column({ type: "date", nullable: false })
|
|
71
|
-
end_date: Date;
|
|
72
|
-
|
|
73
|
-
@Column({ type: "decimal", precision: 5, scale: 2, nullable: true })
|
|
74
|
-
assignment_allowance: number | null; // 0-100 percentage
|
|
75
|
-
|
|
76
|
-
@Column({ type: "varchar", length: 20, nullable: false })
|
|
77
|
-
phone_number: string;
|
|
78
|
-
|
|
79
|
-
@Column({ type: "text", nullable: false })
|
|
80
|
-
reason_for_request: string;
|
|
81
|
-
|
|
82
|
-
// Replacement tracking fields - Store REPLACEMENT details (ORIGINAL details above remain unchanged)
|
|
83
|
-
@Column({ type: "boolean", default: false, nullable: false })
|
|
84
|
-
is_replaced: boolean;
|
|
85
|
-
|
|
86
|
-
@Column({ type: "varchar", length: 255, nullable: true })
|
|
87
|
-
replacement_employee_name: string | null;
|
|
88
|
-
|
|
89
|
-
@Column({ type: "varchar", length: 100, nullable: true })
|
|
90
|
-
replacement_employee_id: string | null;
|
|
91
|
-
|
|
92
|
-
@Column({ type: "varchar", length: 50, nullable: true })
|
|
93
|
-
replacement_civil_id_card_number: string | null;
|
|
94
|
-
|
|
95
|
-
@Column({ type: "varchar", length: 255, nullable: true })
|
|
96
|
-
replacement_current_job_position: string | null;
|
|
97
|
-
|
|
98
|
-
@Column({ type: "varchar", length: 255, nullable: true })
|
|
99
|
-
replacement_assigned_job_position: string | null;
|
|
100
|
-
|
|
101
|
-
@Column({ type: "date", nullable: true })
|
|
102
|
-
replacement_start_date: Date | null;
|
|
103
|
-
|
|
104
|
-
@Column({ type: "date", nullable: true })
|
|
105
|
-
replacement_end_date: Date | null;
|
|
106
|
-
|
|
107
|
-
@Column({ type: "decimal", precision: 5, scale: 2, nullable: true })
|
|
108
|
-
replacement_assignment_allowance: number | null;
|
|
109
|
-
|
|
110
|
-
@Column({ type: "text", nullable: true })
|
|
111
|
-
replacement_reason: string | null;
|
|
112
|
-
|
|
113
|
-
@Column({ type: "integer", nullable: true })
|
|
114
|
-
replaced_by_user_id: number | null;
|
|
115
|
-
|
|
116
|
-
@Column({ type: "timestamp", nullable: true })
|
|
117
|
-
replaced_at: Date | null;
|
|
118
|
-
|
|
119
|
-
constructor(
|
|
120
|
-
user_id: number,
|
|
121
|
-
status: HrServiceRequestStatus = HrServiceRequestStatus.PENDING,
|
|
122
|
-
service_id?: number | null,
|
|
123
|
-
sub_service_id?: number | null,
|
|
124
|
-
req_user_department_id?: number | null,
|
|
125
|
-
req_user_section_id?: number | null,
|
|
126
|
-
req_user_position_id?: number | null,
|
|
127
|
-
description?: string | null,
|
|
128
|
-
reviewer_user_id?: number | null,
|
|
129
|
-
assigned_to_user_id?: number | null,
|
|
130
|
-
assigned_at?: Date | null,
|
|
131
|
-
workflow_execution_id?: string | null,
|
|
132
|
-
assigned_employee_name?: string,
|
|
133
|
-
civil_id_card_number?: string | null,
|
|
134
|
-
employee_id?: string,
|
|
135
|
-
current_job_position?: string,
|
|
136
|
-
assigned_job_position?: string,
|
|
137
|
-
start_date?: Date,
|
|
138
|
-
end_date?: Date,
|
|
139
|
-
assignment_allowance?: number | null,
|
|
140
|
-
phone_number?: string,
|
|
141
|
-
reason_for_request?: string,
|
|
142
|
-
is_replaced?: boolean,
|
|
143
|
-
replacement_employee_name?: string | null,
|
|
144
|
-
replacement_employee_id?: string | null,
|
|
145
|
-
replacement_civil_id_card_number?: string | null,
|
|
146
|
-
replacement_current_job_position?: string | null,
|
|
147
|
-
replacement_assigned_job_position?: string | null,
|
|
148
|
-
replacement_start_date?: Date | null,
|
|
149
|
-
replacement_end_date?: Date | null,
|
|
150
|
-
replacement_assignment_allowance?: number | null,
|
|
151
|
-
replacement_reason?: string | null,
|
|
152
|
-
replaced_by_user_id?: number | null,
|
|
153
|
-
replaced_at?: Date | null
|
|
154
|
-
) {
|
|
155
|
-
super();
|
|
156
|
-
this.user_id = user_id;
|
|
157
|
-
this.status = status;
|
|
158
|
-
this.service_id = service_id || null;
|
|
159
|
-
this.sub_service_id = sub_service_id || null;
|
|
160
|
-
this.req_user_department_id = req_user_department_id || null;
|
|
161
|
-
this.req_user_section_id = req_user_section_id || null;
|
|
162
|
-
this.req_user_position_id = req_user_position_id || null;
|
|
163
|
-
this.description = description || null;
|
|
164
|
-
this.reviewer_user_id = reviewer_user_id || null;
|
|
165
|
-
this.assigned_to_user_id = assigned_to_user_id || null;
|
|
166
|
-
this.assigned_at = assigned_at || null;
|
|
167
|
-
this.workflow_execution_id = workflow_execution_id || null;
|
|
168
|
-
this.assigned_employee_name = assigned_employee_name || "";
|
|
169
|
-
this.civil_id_card_number = civil_id_card_number || null;
|
|
170
|
-
this.employee_id = employee_id || "";
|
|
171
|
-
this.current_job_position = current_job_position || "";
|
|
172
|
-
this.assigned_job_position = assigned_job_position || "";
|
|
173
|
-
this.start_date = start_date || new Date();
|
|
174
|
-
this.end_date = end_date || new Date();
|
|
175
|
-
this.assignment_allowance = assignment_allowance || null;
|
|
176
|
-
this.phone_number = phone_number || "";
|
|
177
|
-
this.reason_for_request = reason_for_request || "";
|
|
178
|
-
// Replacement fields initialization
|
|
179
|
-
this.is_replaced = is_replaced || false;
|
|
180
|
-
this.replacement_employee_name = replacement_employee_name || null;
|
|
181
|
-
this.replacement_employee_id = replacement_employee_id || null;
|
|
182
|
-
this.replacement_civil_id_card_number = replacement_civil_id_card_number || null;
|
|
183
|
-
this.replacement_current_job_position = replacement_current_job_position || null;
|
|
184
|
-
this.replacement_assigned_job_position = replacement_assigned_job_position || null;
|
|
185
|
-
this.replacement_start_date = replacement_start_date || null;
|
|
186
|
-
this.replacement_end_date = replacement_end_date || null;
|
|
187
|
-
this.replacement_assignment_allowance = replacement_assignment_allowance || null;
|
|
188
|
-
this.replacement_reason = replacement_reason || null;
|
|
189
|
-
this.replaced_by_user_id = replaced_by_user_id || null;
|
|
190
|
-
this.replaced_at = replaced_at || null;
|
|
191
|
-
}
|
|
192
|
-
}
|
|
193
|
-
|
|
1
|
+
import { Column, Entity } from "typeorm";
|
|
2
|
+
import { BaseModel } from "./BaseModel";
|
|
3
|
+
|
|
4
|
+
export enum HrServiceRequestStatus {
|
|
5
|
+
PENDING = "Pending",
|
|
6
|
+
ASSIGNED = "Assigned",
|
|
7
|
+
IN_PROGRESS = "In Progress",
|
|
8
|
+
COMPLETED = "Completed",
|
|
9
|
+
APPROVED = "Approved",
|
|
10
|
+
REJECTED = "Rejected"
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
@Entity({ name: "hr_service_requests" })
|
|
14
|
+
export class HrServiceRequest extends BaseModel {
|
|
15
|
+
@Column({ type: "integer", nullable: true })
|
|
16
|
+
req_user_department_id: number | null;
|
|
17
|
+
|
|
18
|
+
@Column({ type: "integer", nullable: true })
|
|
19
|
+
req_user_section_id: number | null;
|
|
20
|
+
|
|
21
|
+
@Column({ type: "integer", nullable: true })
|
|
22
|
+
req_user_position_id: number | null;
|
|
23
|
+
|
|
24
|
+
@Column({ type: "integer", nullable: true })
|
|
25
|
+
service_id: number | null;
|
|
26
|
+
|
|
27
|
+
@Column({ type: "integer", nullable: true })
|
|
28
|
+
sub_service_id: number | null;
|
|
29
|
+
|
|
30
|
+
@Column({ type: "integer", nullable: false })
|
|
31
|
+
user_id: number;
|
|
32
|
+
|
|
33
|
+
@Column({ type: "text", nullable: true })
|
|
34
|
+
description: string | null;
|
|
35
|
+
|
|
36
|
+
@Column({ type: "enum", enum: HrServiceRequestStatus, default: HrServiceRequestStatus.PENDING, nullable: false })
|
|
37
|
+
status: HrServiceRequestStatus;
|
|
38
|
+
|
|
39
|
+
@Column({ type: "integer", nullable: true })
|
|
40
|
+
reviewer_user_id: number | null;
|
|
41
|
+
|
|
42
|
+
@Column({ type: "integer", nullable: true })
|
|
43
|
+
assigned_to_user_id: number | null;
|
|
44
|
+
|
|
45
|
+
@Column({ type: "timestamp", nullable: true })
|
|
46
|
+
assigned_at: Date | null;
|
|
47
|
+
|
|
48
|
+
@Column({ type: "varchar", length: 255, nullable: true })
|
|
49
|
+
workflow_execution_id: string | null;
|
|
50
|
+
|
|
51
|
+
// Assignment Decision specific fields
|
|
52
|
+
@Column({ type: "varchar", length: 255, nullable: false })
|
|
53
|
+
assigned_employee_name: string;
|
|
54
|
+
|
|
55
|
+
@Column({ type: "varchar", length: 50, nullable: true })
|
|
56
|
+
civil_id_card_number: string | null;
|
|
57
|
+
|
|
58
|
+
@Column({ type: "varchar", length: 100, nullable: false })
|
|
59
|
+
employee_id: string;
|
|
60
|
+
|
|
61
|
+
@Column({ type: "varchar", length: 255, nullable: false })
|
|
62
|
+
current_job_position: string;
|
|
63
|
+
|
|
64
|
+
@Column({ type: "varchar", length: 255, nullable: false })
|
|
65
|
+
assigned_job_position: string;
|
|
66
|
+
|
|
67
|
+
@Column({ type: "date", nullable: false })
|
|
68
|
+
start_date: Date;
|
|
69
|
+
|
|
70
|
+
@Column({ type: "date", nullable: false })
|
|
71
|
+
end_date: Date;
|
|
72
|
+
|
|
73
|
+
@Column({ type: "decimal", precision: 5, scale: 2, nullable: true })
|
|
74
|
+
assignment_allowance: number | null; // 0-100 percentage
|
|
75
|
+
|
|
76
|
+
@Column({ type: "varchar", length: 20, nullable: false })
|
|
77
|
+
phone_number: string;
|
|
78
|
+
|
|
79
|
+
@Column({ type: "text", nullable: false })
|
|
80
|
+
reason_for_request: string;
|
|
81
|
+
|
|
82
|
+
// Replacement tracking fields - Store REPLACEMENT details (ORIGINAL details above remain unchanged)
|
|
83
|
+
@Column({ type: "boolean", default: false, nullable: false })
|
|
84
|
+
is_replaced: boolean;
|
|
85
|
+
|
|
86
|
+
@Column({ type: "varchar", length: 255, nullable: true })
|
|
87
|
+
replacement_employee_name: string | null;
|
|
88
|
+
|
|
89
|
+
@Column({ type: "varchar", length: 100, nullable: true })
|
|
90
|
+
replacement_employee_id: string | null;
|
|
91
|
+
|
|
92
|
+
@Column({ type: "varchar", length: 50, nullable: true })
|
|
93
|
+
replacement_civil_id_card_number: string | null;
|
|
94
|
+
|
|
95
|
+
@Column({ type: "varchar", length: 255, nullable: true })
|
|
96
|
+
replacement_current_job_position: string | null;
|
|
97
|
+
|
|
98
|
+
@Column({ type: "varchar", length: 255, nullable: true })
|
|
99
|
+
replacement_assigned_job_position: string | null;
|
|
100
|
+
|
|
101
|
+
@Column({ type: "date", nullable: true })
|
|
102
|
+
replacement_start_date: Date | null;
|
|
103
|
+
|
|
104
|
+
@Column({ type: "date", nullable: true })
|
|
105
|
+
replacement_end_date: Date | null;
|
|
106
|
+
|
|
107
|
+
@Column({ type: "decimal", precision: 5, scale: 2, nullable: true })
|
|
108
|
+
replacement_assignment_allowance: number | null;
|
|
109
|
+
|
|
110
|
+
@Column({ type: "text", nullable: true })
|
|
111
|
+
replacement_reason: string | null;
|
|
112
|
+
|
|
113
|
+
@Column({ type: "integer", nullable: true })
|
|
114
|
+
replaced_by_user_id: number | null;
|
|
115
|
+
|
|
116
|
+
@Column({ type: "timestamp", nullable: true })
|
|
117
|
+
replaced_at: Date | null;
|
|
118
|
+
|
|
119
|
+
constructor(
|
|
120
|
+
user_id: number,
|
|
121
|
+
status: HrServiceRequestStatus = HrServiceRequestStatus.PENDING,
|
|
122
|
+
service_id?: number | null,
|
|
123
|
+
sub_service_id?: number | null,
|
|
124
|
+
req_user_department_id?: number | null,
|
|
125
|
+
req_user_section_id?: number | null,
|
|
126
|
+
req_user_position_id?: number | null,
|
|
127
|
+
description?: string | null,
|
|
128
|
+
reviewer_user_id?: number | null,
|
|
129
|
+
assigned_to_user_id?: number | null,
|
|
130
|
+
assigned_at?: Date | null,
|
|
131
|
+
workflow_execution_id?: string | null,
|
|
132
|
+
assigned_employee_name?: string,
|
|
133
|
+
civil_id_card_number?: string | null,
|
|
134
|
+
employee_id?: string,
|
|
135
|
+
current_job_position?: string,
|
|
136
|
+
assigned_job_position?: string,
|
|
137
|
+
start_date?: Date,
|
|
138
|
+
end_date?: Date,
|
|
139
|
+
assignment_allowance?: number | null,
|
|
140
|
+
phone_number?: string,
|
|
141
|
+
reason_for_request?: string,
|
|
142
|
+
is_replaced?: boolean,
|
|
143
|
+
replacement_employee_name?: string | null,
|
|
144
|
+
replacement_employee_id?: string | null,
|
|
145
|
+
replacement_civil_id_card_number?: string | null,
|
|
146
|
+
replacement_current_job_position?: string | null,
|
|
147
|
+
replacement_assigned_job_position?: string | null,
|
|
148
|
+
replacement_start_date?: Date | null,
|
|
149
|
+
replacement_end_date?: Date | null,
|
|
150
|
+
replacement_assignment_allowance?: number | null,
|
|
151
|
+
replacement_reason?: string | null,
|
|
152
|
+
replaced_by_user_id?: number | null,
|
|
153
|
+
replaced_at?: Date | null
|
|
154
|
+
) {
|
|
155
|
+
super();
|
|
156
|
+
this.user_id = user_id;
|
|
157
|
+
this.status = status;
|
|
158
|
+
this.service_id = service_id || null;
|
|
159
|
+
this.sub_service_id = sub_service_id || null;
|
|
160
|
+
this.req_user_department_id = req_user_department_id || null;
|
|
161
|
+
this.req_user_section_id = req_user_section_id || null;
|
|
162
|
+
this.req_user_position_id = req_user_position_id || null;
|
|
163
|
+
this.description = description || null;
|
|
164
|
+
this.reviewer_user_id = reviewer_user_id || null;
|
|
165
|
+
this.assigned_to_user_id = assigned_to_user_id || null;
|
|
166
|
+
this.assigned_at = assigned_at || null;
|
|
167
|
+
this.workflow_execution_id = workflow_execution_id || null;
|
|
168
|
+
this.assigned_employee_name = assigned_employee_name || "";
|
|
169
|
+
this.civil_id_card_number = civil_id_card_number || null;
|
|
170
|
+
this.employee_id = employee_id || "";
|
|
171
|
+
this.current_job_position = current_job_position || "";
|
|
172
|
+
this.assigned_job_position = assigned_job_position || "";
|
|
173
|
+
this.start_date = start_date || new Date();
|
|
174
|
+
this.end_date = end_date || new Date();
|
|
175
|
+
this.assignment_allowance = assignment_allowance || null;
|
|
176
|
+
this.phone_number = phone_number || "";
|
|
177
|
+
this.reason_for_request = reason_for_request || "";
|
|
178
|
+
// Replacement fields initialization
|
|
179
|
+
this.is_replaced = is_replaced || false;
|
|
180
|
+
this.replacement_employee_name = replacement_employee_name || null;
|
|
181
|
+
this.replacement_employee_id = replacement_employee_id || null;
|
|
182
|
+
this.replacement_civil_id_card_number = replacement_civil_id_card_number || null;
|
|
183
|
+
this.replacement_current_job_position = replacement_current_job_position || null;
|
|
184
|
+
this.replacement_assigned_job_position = replacement_assigned_job_position || null;
|
|
185
|
+
this.replacement_start_date = replacement_start_date || null;
|
|
186
|
+
this.replacement_end_date = replacement_end_date || null;
|
|
187
|
+
this.replacement_assignment_allowance = replacement_assignment_allowance || null;
|
|
188
|
+
this.replacement_reason = replacement_reason || null;
|
|
189
|
+
this.replaced_by_user_id = replaced_by_user_id || null;
|
|
190
|
+
this.replaced_at = replaced_at || null;
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import { Column, Entity } from "typeorm";
|
|
2
|
+
import { BaseModel } from "./BaseModel";
|
|
3
|
+
|
|
4
|
+
export enum SkillsEnhancementRequestStatus {
|
|
5
|
+
PENDING = "Pending",
|
|
6
|
+
ASSIGNED = "Assigned",
|
|
7
|
+
IN_PROGRESS = "In Progress",
|
|
8
|
+
COMPLETED = "Completed",
|
|
9
|
+
APPROVED = "Approved",
|
|
10
|
+
REJECTED = "Rejected",
|
|
11
|
+
INFORMATION_REQUESTED = "Information Requested"
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
export enum SkillCategory {
|
|
15
|
+
TECHNICAL = "Technical",
|
|
16
|
+
COMPLIANCE = "Compliance",
|
|
17
|
+
MANAGEMENT = "Management",
|
|
18
|
+
SAFETY = "Safety",
|
|
19
|
+
SOFT_SKILLS = "Soft Skills",
|
|
20
|
+
OTHER = "Other"
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
@Entity({ name: "skills_enhancement_requests" })
|
|
24
|
+
export class SkillsEnhancementRequest extends BaseModel {
|
|
25
|
+
@Column({ type: "integer", nullable: true })
|
|
26
|
+
req_user_department_id: number | null;
|
|
27
|
+
|
|
28
|
+
@Column({ type: "integer", nullable: true })
|
|
29
|
+
req_user_section_id: number | null;
|
|
30
|
+
|
|
31
|
+
@Column({ type: "integer", nullable: true })
|
|
32
|
+
req_user_position_id: number | null;
|
|
33
|
+
|
|
34
|
+
@Column({ type: "integer", nullable: false })
|
|
35
|
+
user_id: number;
|
|
36
|
+
|
|
37
|
+
@Column({ type: "integer", nullable: true })
|
|
38
|
+
service_id: number | null;
|
|
39
|
+
|
|
40
|
+
@Column({ type: "integer", nullable: true })
|
|
41
|
+
sub_service_id: number | null;
|
|
42
|
+
|
|
43
|
+
@Column({ type: "enum", enum: SkillsEnhancementRequestStatus, default: SkillsEnhancementRequestStatus.PENDING, nullable: false })
|
|
44
|
+
status: SkillsEnhancementRequestStatus;
|
|
45
|
+
|
|
46
|
+
@Column({ type: "integer", nullable: true })
|
|
47
|
+
reviewer_user_id: number | null;
|
|
48
|
+
|
|
49
|
+
@Column({ type: "integer", nullable: true })
|
|
50
|
+
assigned_to_user_id: number | null;
|
|
51
|
+
|
|
52
|
+
@Column({ type: "timestamp", nullable: true })
|
|
53
|
+
assigned_at: Date | null;
|
|
54
|
+
|
|
55
|
+
@Column({ type: "varchar", length: 255, nullable: true })
|
|
56
|
+
workflow_execution_id: string | null;
|
|
57
|
+
|
|
58
|
+
@Column({ type: "text", nullable: true })
|
|
59
|
+
description: string | null;
|
|
60
|
+
|
|
61
|
+
// Skills Enhancement specific fields
|
|
62
|
+
@Column({ type: "varchar", length: 255, nullable: false })
|
|
63
|
+
certification_title: string;
|
|
64
|
+
|
|
65
|
+
@Column({ type: "enum", enum: SkillCategory, nullable: false })
|
|
66
|
+
skill_category: SkillCategory;
|
|
67
|
+
|
|
68
|
+
@Column({ type: "varchar", length: 255, nullable: false })
|
|
69
|
+
issuing_authority: string;
|
|
70
|
+
|
|
71
|
+
@Column({ type: "date", nullable: false })
|
|
72
|
+
completion_date: Date;
|
|
73
|
+
|
|
74
|
+
@Column({ type: "text", nullable: true })
|
|
75
|
+
skill_summary: string | null;
|
|
76
|
+
|
|
77
|
+
@Column({ type: "text", nullable: true })
|
|
78
|
+
additional_info_requested: string | null;
|
|
79
|
+
|
|
80
|
+
constructor(
|
|
81
|
+
user_id: number,
|
|
82
|
+
status: SkillsEnhancementRequestStatus = SkillsEnhancementRequestStatus.PENDING,
|
|
83
|
+
service_id?: number | null,
|
|
84
|
+
sub_service_id?: number | null,
|
|
85
|
+
req_user_department_id?: number | null,
|
|
86
|
+
req_user_section_id?: number | null,
|
|
87
|
+
req_user_position_id?: number | null,
|
|
88
|
+
description?: string | null,
|
|
89
|
+
reviewer_user_id?: number | null,
|
|
90
|
+
assigned_to_user_id?: number | null,
|
|
91
|
+
assigned_at?: Date | null,
|
|
92
|
+
workflow_execution_id?: string | null,
|
|
93
|
+
certification_title?: string,
|
|
94
|
+
skill_category?: SkillCategory,
|
|
95
|
+
issuing_authority?: string,
|
|
96
|
+
completion_date?: Date,
|
|
97
|
+
skill_summary?: string | null,
|
|
98
|
+
additional_info_requested?: string | null
|
|
99
|
+
) {
|
|
100
|
+
super();
|
|
101
|
+
this.user_id = user_id;
|
|
102
|
+
this.status = status;
|
|
103
|
+
this.service_id = service_id || null;
|
|
104
|
+
this.sub_service_id = sub_service_id || null;
|
|
105
|
+
this.req_user_department_id = req_user_department_id || null;
|
|
106
|
+
this.req_user_section_id = req_user_section_id || null;
|
|
107
|
+
this.req_user_position_id = req_user_position_id || null;
|
|
108
|
+
this.description = description || null;
|
|
109
|
+
this.reviewer_user_id = reviewer_user_id || null;
|
|
110
|
+
this.assigned_to_user_id = assigned_to_user_id || null;
|
|
111
|
+
this.assigned_at = assigned_at || null;
|
|
112
|
+
this.workflow_execution_id = workflow_execution_id || null;
|
|
113
|
+
this.certification_title = certification_title || "";
|
|
114
|
+
this.skill_category = skill_category || SkillCategory.TECHNICAL;
|
|
115
|
+
this.issuing_authority = issuing_authority || "";
|
|
116
|
+
this.completion_date = completion_date || new Date();
|
|
117
|
+
this.skill_summary = skill_summary || null;
|
|
118
|
+
this.additional_info_requested = additional_info_requested || null;
|
|
119
|
+
}
|
|
120
|
+
}
|
|
@@ -1,41 +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.CityMaster = void 0;
|
|
13
|
-
const typeorm_1 = require("typeorm");
|
|
14
|
-
const BaseModel_1 = require("./BaseModel");
|
|
15
|
-
let CityMaster = class CityMaster extends BaseModel_1.BaseModel {
|
|
16
|
-
constructor(city_name) {
|
|
17
|
-
super();
|
|
18
|
-
this.city_name = city_name;
|
|
19
|
-
}
|
|
20
|
-
};
|
|
21
|
-
exports.CityMaster = CityMaster;
|
|
22
|
-
__decorate([
|
|
23
|
-
(0, typeorm_1.Column)({ type: 'int', nullable: true }),
|
|
24
|
-
__metadata("design:type", Object)
|
|
25
|
-
], CityMaster.prototype, "country_id", void 0);
|
|
26
|
-
__decorate([
|
|
27
|
-
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: false }),
|
|
28
|
-
__metadata("design:type", String)
|
|
29
|
-
], CityMaster.prototype, "city_name", void 0);
|
|
30
|
-
__decorate([
|
|
31
|
-
(0, typeorm_1.Column)({ type: 'varchar', length: 50, nullable: true }),
|
|
32
|
-
__metadata("design:type", Object)
|
|
33
|
-
], CityMaster.prototype, "city_code", void 0);
|
|
34
|
-
__decorate([
|
|
35
|
-
(0, typeorm_1.Column)({ type: 'text', nullable: true }),
|
|
36
|
-
__metadata("design:type", Object)
|
|
37
|
-
], CityMaster.prototype, "description", void 0);
|
|
38
|
-
exports.CityMaster = CityMaster = __decorate([
|
|
39
|
-
(0, typeorm_1.Entity)({ name: 'city_master' }),
|
|
40
|
-
__metadata("design:paramtypes", [String])
|
|
41
|
-
], CityMaster);
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { Column, Entity } from "typeorm";
|
|
2
|
-
import { BaseModel } from './BaseModel';
|
|
3
|
-
|
|
4
|
-
@Entity({ name: 'city_master' })
|
|
5
|
-
export class CityMaster extends BaseModel {
|
|
6
|
-
@Column({ type: 'int', nullable: true })
|
|
7
|
-
country_id: number | null;
|
|
8
|
-
|
|
9
|
-
@Column({ type: 'varchar', length: 255, nullable: false })
|
|
10
|
-
city_name: string;
|
|
11
|
-
|
|
12
|
-
@Column({ type: 'varchar', length: 50, nullable: true })
|
|
13
|
-
city_code: string | null;
|
|
14
|
-
|
|
15
|
-
@Column({ type: 'text', nullable: true })
|
|
16
|
-
description: string | null;
|
|
17
|
-
|
|
18
|
-
constructor(city_name: string) {
|
|
19
|
-
super();
|
|
20
|
-
this.city_name = city_name;
|
|
21
|
-
}
|
|
22
|
-
}
|