@platform-modules/civil-aviation-authority 2.3.4 → 2.3.5
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 +1 -20
- package/dist/data-source.js +11 -1
- package/dist/index.d.ts +2 -13
- package/dist/index.js +5 -20
- package/dist/models/TemporaryAssignmentRequestModel.d.ts +49 -0
- package/dist/models/TemporaryAssignmentRequestModel.js +204 -0
- package/dist/models/Workflows.d.ts +9 -0
- package/package.json +1 -1
- package/src/data-source.ts +181 -183
- package/src/index.ts +98 -109
- package/src/models/HrServiceRequestModel.ts +167 -167
- package/src/models/TemporaryAssignmentRequestModel.ts +194 -0
- package/dist/models/DutyMissionAirTicketDetailsModel.d.ts +0 -20
- package/dist/models/DutyMissionAirTicketDetailsModel.js +0 -100
- package/dist/models/DutyMissionApprovalModel.d.ts +0 -23
- package/dist/models/DutyMissionApprovalModel.js +0 -96
- package/dist/models/DutyMissionAttachmentModel.d.ts +0 -12
- package/dist/models/DutyMissionAttachmentModel.js +0 -64
- package/dist/models/DutyMissionChatModel.d.ts +0 -19
- package/dist/models/DutyMissionChatModel.js +0 -77
- package/dist/models/DutyMissionEmployeeDetailsModel.d.ts +0 -17
- package/dist/models/DutyMissionEmployeeDetailsModel.js +0 -85
- package/dist/models/DutyMissionRequestModel.d.ts +0 -67
- package/dist/models/DutyMissionRequestModel.js +0 -252
- package/dist/models/DutyMissionWorkflowModel.d.ts +0 -18
- package/dist/models/DutyMissionWorkflowModel.js +0 -76
- package/src/models/DutyMissionAirTicketDetailsModel.ts +0 -87
- package/src/models/DutyMissionApprovalModel.ts +0 -83
- package/src/models/DutyMissionAttachmentModel.ts +0 -51
- package/src/models/DutyMissionChatModel.ts +0 -65
- package/src/models/DutyMissionEmployeeDetailsModel.ts +0 -72
- package/src/models/DutyMissionRequestModel.ts +0 -239
- package/src/models/DutyMissionWorkflowModel.ts +0 -62
|
@@ -1,96 +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.DutyMissionApprovalDetails = exports.DutyMissionApprovalStatus = void 0;
|
|
13
|
-
const typeorm_1 = require("typeorm");
|
|
14
|
-
const BaseModel_1 = require("./BaseModel");
|
|
15
|
-
var DutyMissionApprovalStatus;
|
|
16
|
-
(function (DutyMissionApprovalStatus) {
|
|
17
|
-
DutyMissionApprovalStatus["PENDING"] = "Pending";
|
|
18
|
-
DutyMissionApprovalStatus["IN_PROGRESS"] = "In Progress";
|
|
19
|
-
DutyMissionApprovalStatus["APPROVED"] = "Approved";
|
|
20
|
-
DutyMissionApprovalStatus["REJECTED"] = "Rejected";
|
|
21
|
-
})(DutyMissionApprovalStatus || (exports.DutyMissionApprovalStatus = DutyMissionApprovalStatus = {}));
|
|
22
|
-
let DutyMissionApprovalDetails = class DutyMissionApprovalDetails extends BaseModel_1.BaseModel {
|
|
23
|
-
constructor(request_id, approver_role_id, comment, approval_status, level, department_id, section_id, approver_user_id, delegate_user_id, approved_by, service_id, sub_service_id, is_allowed) {
|
|
24
|
-
super();
|
|
25
|
-
this.request_id = request_id;
|
|
26
|
-
this.service_id = service_id || null;
|
|
27
|
-
this.sub_service_id = sub_service_id || null;
|
|
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.approver_user_id = approver_user_id || null;
|
|
35
|
-
this.delegate_user_id = delegate_user_id || null;
|
|
36
|
-
this.approved_by = approved_by || null;
|
|
37
|
-
this.is_allowed = is_allowed !== undefined ? is_allowed : true;
|
|
38
|
-
}
|
|
39
|
-
};
|
|
40
|
-
exports.DutyMissionApprovalDetails = DutyMissionApprovalDetails;
|
|
41
|
-
__decorate([
|
|
42
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: false }),
|
|
43
|
-
__metadata("design:type", Number)
|
|
44
|
-
], DutyMissionApprovalDetails.prototype, "request_id", void 0);
|
|
45
|
-
__decorate([
|
|
46
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
47
|
-
__metadata("design:type", Object)
|
|
48
|
-
], DutyMissionApprovalDetails.prototype, "service_id", void 0);
|
|
49
|
-
__decorate([
|
|
50
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
51
|
-
__metadata("design:type", Object)
|
|
52
|
-
], DutyMissionApprovalDetails.prototype, "sub_service_id", void 0);
|
|
53
|
-
__decorate([
|
|
54
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: false }),
|
|
55
|
-
__metadata("design:type", Number)
|
|
56
|
-
], DutyMissionApprovalDetails.prototype, "level", void 0);
|
|
57
|
-
__decorate([
|
|
58
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: false }),
|
|
59
|
-
__metadata("design:type", Number)
|
|
60
|
-
], DutyMissionApprovalDetails.prototype, "approver_role_id", void 0);
|
|
61
|
-
__decorate([
|
|
62
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
63
|
-
__metadata("design:type", Object)
|
|
64
|
-
], DutyMissionApprovalDetails.prototype, "department_id", void 0);
|
|
65
|
-
__decorate([
|
|
66
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
67
|
-
__metadata("design:type", Object)
|
|
68
|
-
], DutyMissionApprovalDetails.prototype, "section_id", void 0);
|
|
69
|
-
__decorate([
|
|
70
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
71
|
-
__metadata("design:type", Object)
|
|
72
|
-
], DutyMissionApprovalDetails.prototype, "approver_user_id", void 0);
|
|
73
|
-
__decorate([
|
|
74
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
75
|
-
__metadata("design:type", Object)
|
|
76
|
-
], DutyMissionApprovalDetails.prototype, "delegate_user_id", void 0);
|
|
77
|
-
__decorate([
|
|
78
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
79
|
-
__metadata("design:type", Object)
|
|
80
|
-
], DutyMissionApprovalDetails.prototype, "approved_by", void 0);
|
|
81
|
-
__decorate([
|
|
82
|
-
(0, typeorm_1.Column)({ type: 'varchar', length: 500, nullable: true, default: '' }),
|
|
83
|
-
__metadata("design:type", String)
|
|
84
|
-
], DutyMissionApprovalDetails.prototype, "comment", void 0);
|
|
85
|
-
__decorate([
|
|
86
|
-
(0, typeorm_1.Column)({ type: 'enum', enum: DutyMissionApprovalStatus, default: DutyMissionApprovalStatus.PENDING, nullable: false }),
|
|
87
|
-
__metadata("design:type", String)
|
|
88
|
-
], DutyMissionApprovalDetails.prototype, "approval_status", void 0);
|
|
89
|
-
__decorate([
|
|
90
|
-
(0, typeorm_1.Column)({ type: 'boolean', default: true, nullable: false }),
|
|
91
|
-
__metadata("design:type", Boolean)
|
|
92
|
-
], DutyMissionApprovalDetails.prototype, "is_allowed", void 0);
|
|
93
|
-
exports.DutyMissionApprovalDetails = DutyMissionApprovalDetails = __decorate([
|
|
94
|
-
(0, typeorm_1.Entity)({ name: 'duty_mission_approvals' }),
|
|
95
|
-
__metadata("design:paramtypes", [Number, Number, String, String, Number, Object, Object, Object, Object, Object, Number, Number, Boolean])
|
|
96
|
-
], DutyMissionApprovalDetails);
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { BaseModel } from './BaseModel';
|
|
2
|
-
export declare class DutyMissionRequestAttachment extends BaseModel {
|
|
3
|
-
request_id: number;
|
|
4
|
-
service_id: number | null;
|
|
5
|
-
sub_service_id: number | null;
|
|
6
|
-
file_url: string;
|
|
7
|
-
file_name: string;
|
|
8
|
-
file_type: string;
|
|
9
|
-
file_size: number | null;
|
|
10
|
-
chat_id: number | null;
|
|
11
|
-
constructor(request_id: number, file_url: string, file_name?: string, file_type?: string, file_size?: number, service_id?: number, sub_service_id?: number, chat_id?: number);
|
|
12
|
-
}
|
|
@@ -1,64 +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.DutyMissionRequestAttachment = void 0;
|
|
13
|
-
const typeorm_1 = require("typeorm");
|
|
14
|
-
const BaseModel_1 = require("./BaseModel");
|
|
15
|
-
let DutyMissionRequestAttachment = class DutyMissionRequestAttachment extends BaseModel_1.BaseModel {
|
|
16
|
-
constructor(request_id, file_url, file_name, file_type, file_size, service_id, sub_service_id, chat_id) {
|
|
17
|
-
super();
|
|
18
|
-
this.request_id = request_id;
|
|
19
|
-
this.service_id = service_id || null;
|
|
20
|
-
this.sub_service_id = sub_service_id || null;
|
|
21
|
-
this.file_url = file_url;
|
|
22
|
-
this.file_name = file_name || '';
|
|
23
|
-
this.file_type = file_type || '';
|
|
24
|
-
this.file_size = file_size || null;
|
|
25
|
-
this.chat_id = chat_id || null;
|
|
26
|
-
}
|
|
27
|
-
};
|
|
28
|
-
exports.DutyMissionRequestAttachment = DutyMissionRequestAttachment;
|
|
29
|
-
__decorate([
|
|
30
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: false }),
|
|
31
|
-
__metadata("design:type", Number)
|
|
32
|
-
], DutyMissionRequestAttachment.prototype, "request_id", void 0);
|
|
33
|
-
__decorate([
|
|
34
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
35
|
-
__metadata("design:type", Object)
|
|
36
|
-
], DutyMissionRequestAttachment.prototype, "service_id", void 0);
|
|
37
|
-
__decorate([
|
|
38
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
39
|
-
__metadata("design:type", Object)
|
|
40
|
-
], DutyMissionRequestAttachment.prototype, "sub_service_id", void 0);
|
|
41
|
-
__decorate([
|
|
42
|
-
(0, typeorm_1.Column)({ type: 'varchar', length: 500, nullable: false }),
|
|
43
|
-
__metadata("design:type", String)
|
|
44
|
-
], DutyMissionRequestAttachment.prototype, "file_url", void 0);
|
|
45
|
-
__decorate([
|
|
46
|
-
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
|
|
47
|
-
__metadata("design:type", String)
|
|
48
|
-
], DutyMissionRequestAttachment.prototype, "file_name", void 0);
|
|
49
|
-
__decorate([
|
|
50
|
-
(0, typeorm_1.Column)({ type: 'varchar', length: 100, nullable: true }),
|
|
51
|
-
__metadata("design:type", String)
|
|
52
|
-
], DutyMissionRequestAttachment.prototype, "file_type", void 0);
|
|
53
|
-
__decorate([
|
|
54
|
-
(0, typeorm_1.Column)({ type: 'bigint', nullable: true }),
|
|
55
|
-
__metadata("design:type", Object)
|
|
56
|
-
], DutyMissionRequestAttachment.prototype, "file_size", void 0);
|
|
57
|
-
__decorate([
|
|
58
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
59
|
-
__metadata("design:type", Object)
|
|
60
|
-
], DutyMissionRequestAttachment.prototype, "chat_id", void 0);
|
|
61
|
-
exports.DutyMissionRequestAttachment = DutyMissionRequestAttachment = __decorate([
|
|
62
|
-
(0, typeorm_1.Entity)({ name: 'duty_mission_attachments' }),
|
|
63
|
-
__metadata("design:paramtypes", [Number, String, String, String, Number, Number, Number, Number])
|
|
64
|
-
], DutyMissionRequestAttachment);
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { BaseModel } from './BaseModel';
|
|
2
|
-
export declare enum DutyMissionMessageType {
|
|
3
|
-
TEXT = "text",
|
|
4
|
-
IMAGE = "image",
|
|
5
|
-
VIDEO = "video",
|
|
6
|
-
FILE = "file",
|
|
7
|
-
LINK = "link"
|
|
8
|
-
}
|
|
9
|
-
export declare class DutyMissionRequestChat extends BaseModel {
|
|
10
|
-
request_id: number;
|
|
11
|
-
service_id: number | null;
|
|
12
|
-
sub_service_id: number | null;
|
|
13
|
-
user_id: number;
|
|
14
|
-
role_id: number;
|
|
15
|
-
message: string;
|
|
16
|
-
messageType: DutyMissionMessageType;
|
|
17
|
-
status: string | null;
|
|
18
|
-
constructor(request_id: number, user_id: number, role_id: number, message: string, service_id?: number, sub_service_id?: number, messageType?: DutyMissionMessageType, status?: string | null);
|
|
19
|
-
}
|
|
@@ -1,77 +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.DutyMissionRequestChat = exports.DutyMissionMessageType = void 0;
|
|
13
|
-
const typeorm_1 = require("typeorm");
|
|
14
|
-
const BaseModel_1 = require("./BaseModel");
|
|
15
|
-
var DutyMissionMessageType;
|
|
16
|
-
(function (DutyMissionMessageType) {
|
|
17
|
-
DutyMissionMessageType["TEXT"] = "text";
|
|
18
|
-
DutyMissionMessageType["IMAGE"] = "image";
|
|
19
|
-
DutyMissionMessageType["VIDEO"] = "video";
|
|
20
|
-
DutyMissionMessageType["FILE"] = "file";
|
|
21
|
-
DutyMissionMessageType["LINK"] = "link";
|
|
22
|
-
})(DutyMissionMessageType || (exports.DutyMissionMessageType = DutyMissionMessageType = {}));
|
|
23
|
-
let DutyMissionRequestChat = class DutyMissionRequestChat extends BaseModel_1.BaseModel {
|
|
24
|
-
constructor(request_id, user_id, role_id, message, service_id, sub_service_id, messageType, status) {
|
|
25
|
-
super();
|
|
26
|
-
this.request_id = request_id;
|
|
27
|
-
this.service_id = service_id || null;
|
|
28
|
-
this.sub_service_id = sub_service_id || null;
|
|
29
|
-
this.user_id = user_id;
|
|
30
|
-
this.role_id = role_id;
|
|
31
|
-
this.message = message;
|
|
32
|
-
this.messageType = messageType || DutyMissionMessageType.TEXT;
|
|
33
|
-
this.status = status || null;
|
|
34
|
-
}
|
|
35
|
-
};
|
|
36
|
-
exports.DutyMissionRequestChat = DutyMissionRequestChat;
|
|
37
|
-
__decorate([
|
|
38
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: false }),
|
|
39
|
-
__metadata("design:type", Number)
|
|
40
|
-
], DutyMissionRequestChat.prototype, "request_id", void 0);
|
|
41
|
-
__decorate([
|
|
42
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
43
|
-
__metadata("design:type", Object)
|
|
44
|
-
], DutyMissionRequestChat.prototype, "service_id", void 0);
|
|
45
|
-
__decorate([
|
|
46
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
47
|
-
__metadata("design:type", Object)
|
|
48
|
-
], DutyMissionRequestChat.prototype, "sub_service_id", void 0);
|
|
49
|
-
__decorate([
|
|
50
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: false }),
|
|
51
|
-
__metadata("design:type", Number)
|
|
52
|
-
], DutyMissionRequestChat.prototype, "user_id", void 0);
|
|
53
|
-
__decorate([
|
|
54
|
-
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
55
|
-
__metadata("design:type", Number)
|
|
56
|
-
], DutyMissionRequestChat.prototype, "role_id", void 0);
|
|
57
|
-
__decorate([
|
|
58
|
-
(0, typeorm_1.Column)({ type: 'text', nullable: false }),
|
|
59
|
-
__metadata("design:type", String)
|
|
60
|
-
], DutyMissionRequestChat.prototype, "message", void 0);
|
|
61
|
-
__decorate([
|
|
62
|
-
(0, typeorm_1.Column)({
|
|
63
|
-
type: 'enum',
|
|
64
|
-
enum: DutyMissionMessageType,
|
|
65
|
-
default: DutyMissionMessageType.TEXT,
|
|
66
|
-
nullable: false
|
|
67
|
-
}),
|
|
68
|
-
__metadata("design:type", String)
|
|
69
|
-
], DutyMissionRequestChat.prototype, "messageType", void 0);
|
|
70
|
-
__decorate([
|
|
71
|
-
(0, typeorm_1.Column)({ type: 'text', nullable: true }),
|
|
72
|
-
__metadata("design:type", Object)
|
|
73
|
-
], DutyMissionRequestChat.prototype, "status", void 0);
|
|
74
|
-
exports.DutyMissionRequestChat = DutyMissionRequestChat = __decorate([
|
|
75
|
-
(0, typeorm_1.Entity)({ name: 'duty_mission_chats' }),
|
|
76
|
-
__metadata("design:paramtypes", [Number, Number, Number, String, Number, Number, String, Object])
|
|
77
|
-
], DutyMissionRequestChat);
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { BaseModel } from './BaseModel';
|
|
2
|
-
import { DutyMissionRequests } from './DutyMissionRequestModel';
|
|
3
|
-
export declare class DutyMissionEmployeeDetails extends BaseModel {
|
|
4
|
-
request_id: number;
|
|
5
|
-
service_id: number | null;
|
|
6
|
-
sub_service_id: number | null;
|
|
7
|
-
employee_id: string;
|
|
8
|
-
employee_name: string;
|
|
9
|
-
department: string | null;
|
|
10
|
-
grade: string | null;
|
|
11
|
-
position: string | null;
|
|
12
|
-
percentage: number | null;
|
|
13
|
-
allowance_per_day: number | null;
|
|
14
|
-
total_allowance: number | null;
|
|
15
|
-
request: DutyMissionRequests;
|
|
16
|
-
constructor(request_id: number, employee_id: string, employee_name: string, service_id?: number | null, sub_service_id?: number | null, department?: string | null, grade?: string | null, position?: string | null, percentage?: number | null, allowance_per_day?: number | null, total_allowance?: number | null);
|
|
17
|
-
}
|
|
@@ -1,85 +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.DutyMissionEmployeeDetails = void 0;
|
|
13
|
-
const typeorm_1 = require("typeorm");
|
|
14
|
-
const BaseModel_1 = require("./BaseModel");
|
|
15
|
-
const DutyMissionRequestModel_1 = require("./DutyMissionRequestModel");
|
|
16
|
-
let DutyMissionEmployeeDetails = class DutyMissionEmployeeDetails extends BaseModel_1.BaseModel {
|
|
17
|
-
constructor(request_id, employee_id, employee_name, service_id, sub_service_id, department, grade, position, percentage, allowance_per_day, total_allowance) {
|
|
18
|
-
super();
|
|
19
|
-
this.request_id = request_id;
|
|
20
|
-
this.service_id = service_id ?? null;
|
|
21
|
-
this.sub_service_id = sub_service_id ?? null;
|
|
22
|
-
this.employee_id = employee_id;
|
|
23
|
-
this.employee_name = employee_name;
|
|
24
|
-
this.department = department ?? null;
|
|
25
|
-
this.grade = grade ?? null;
|
|
26
|
-
this.position = position ?? null;
|
|
27
|
-
this.percentage = percentage ?? 100;
|
|
28
|
-
this.allowance_per_day = allowance_per_day ?? null;
|
|
29
|
-
this.total_allowance = total_allowance ?? null;
|
|
30
|
-
}
|
|
31
|
-
};
|
|
32
|
-
exports.DutyMissionEmployeeDetails = DutyMissionEmployeeDetails;
|
|
33
|
-
__decorate([
|
|
34
|
-
(0, typeorm_1.Column)({ type: 'int', nullable: false }),
|
|
35
|
-
__metadata("design:type", Number)
|
|
36
|
-
], DutyMissionEmployeeDetails.prototype, "request_id", void 0);
|
|
37
|
-
__decorate([
|
|
38
|
-
(0, typeorm_1.Column)({ type: 'int', nullable: true }),
|
|
39
|
-
__metadata("design:type", Object)
|
|
40
|
-
], DutyMissionEmployeeDetails.prototype, "service_id", void 0);
|
|
41
|
-
__decorate([
|
|
42
|
-
(0, typeorm_1.Column)({ type: 'int', nullable: true }),
|
|
43
|
-
__metadata("design:type", Object)
|
|
44
|
-
], DutyMissionEmployeeDetails.prototype, "sub_service_id", void 0);
|
|
45
|
-
__decorate([
|
|
46
|
-
(0, typeorm_1.Column)({ type: 'varchar', length: 100, nullable: false }),
|
|
47
|
-
__metadata("design:type", String)
|
|
48
|
-
], DutyMissionEmployeeDetails.prototype, "employee_id", void 0);
|
|
49
|
-
__decorate([
|
|
50
|
-
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: false }),
|
|
51
|
-
__metadata("design:type", String)
|
|
52
|
-
], DutyMissionEmployeeDetails.prototype, "employee_name", void 0);
|
|
53
|
-
__decorate([
|
|
54
|
-
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
|
|
55
|
-
__metadata("design:type", Object)
|
|
56
|
-
], DutyMissionEmployeeDetails.prototype, "department", void 0);
|
|
57
|
-
__decorate([
|
|
58
|
-
(0, typeorm_1.Column)({ type: 'varchar', length: 50, nullable: true }),
|
|
59
|
-
__metadata("design:type", Object)
|
|
60
|
-
], DutyMissionEmployeeDetails.prototype, "grade", void 0);
|
|
61
|
-
__decorate([
|
|
62
|
-
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
|
|
63
|
-
__metadata("design:type", Object)
|
|
64
|
-
], DutyMissionEmployeeDetails.prototype, "position", void 0);
|
|
65
|
-
__decorate([
|
|
66
|
-
(0, typeorm_1.Column)({ type: 'decimal', precision: 5, scale: 2, nullable: true, default: 100 }),
|
|
67
|
-
__metadata("design:type", Object)
|
|
68
|
-
], DutyMissionEmployeeDetails.prototype, "percentage", void 0);
|
|
69
|
-
__decorate([
|
|
70
|
-
(0, typeorm_1.Column)({ type: 'decimal', precision: 10, scale: 2, nullable: true }),
|
|
71
|
-
__metadata("design:type", Object)
|
|
72
|
-
], DutyMissionEmployeeDetails.prototype, "allowance_per_day", void 0);
|
|
73
|
-
__decorate([
|
|
74
|
-
(0, typeorm_1.Column)({ type: 'decimal', precision: 10, scale: 2, nullable: true }),
|
|
75
|
-
__metadata("design:type", Object)
|
|
76
|
-
], DutyMissionEmployeeDetails.prototype, "total_allowance", void 0);
|
|
77
|
-
__decorate([
|
|
78
|
-
(0, typeorm_1.ManyToOne)(() => DutyMissionRequestModel_1.DutyMissionRequests, { onDelete: 'CASCADE' }),
|
|
79
|
-
(0, typeorm_1.JoinColumn)({ name: 'request_id', referencedColumnName: 'id' }),
|
|
80
|
-
__metadata("design:type", DutyMissionRequestModel_1.DutyMissionRequests)
|
|
81
|
-
], DutyMissionEmployeeDetails.prototype, "request", void 0);
|
|
82
|
-
exports.DutyMissionEmployeeDetails = DutyMissionEmployeeDetails = __decorate([
|
|
83
|
-
(0, typeorm_1.Entity)({ name: 'duty_mission_employee_details' }),
|
|
84
|
-
__metadata("design:paramtypes", [Number, String, String, Object, Object, Object, Object, Object, Object, Object, Object])
|
|
85
|
-
], DutyMissionEmployeeDetails);
|
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
import { BaseModel } from './BaseModel';
|
|
2
|
-
export declare enum TripType {
|
|
3
|
-
ANNUAL = "Annual",
|
|
4
|
-
PLANNED = "Planned",
|
|
5
|
-
UNPLANNED = "Unplanned"
|
|
6
|
-
}
|
|
7
|
-
export declare enum ChooseType {
|
|
8
|
-
INSIDE = "Inside",
|
|
9
|
-
OUTSIDE = "Outside"
|
|
10
|
-
}
|
|
11
|
-
export declare enum MissionSponsoredBy {
|
|
12
|
-
CAA = "CAA",
|
|
13
|
-
LISTED = "Listed Companies",
|
|
14
|
-
NON_LISTED = "Non-listed Companies"
|
|
15
|
-
}
|
|
16
|
-
export declare enum AirTicketRequired {
|
|
17
|
-
YES = "Yes",
|
|
18
|
-
NO = "No",
|
|
19
|
-
CASH_COMPONENT = "Cash Component"
|
|
20
|
-
}
|
|
21
|
-
export declare enum VehicleRequired {
|
|
22
|
-
YES = "Yes",
|
|
23
|
-
NO = "No"
|
|
24
|
-
}
|
|
25
|
-
export declare enum DutyMissionStatus {
|
|
26
|
-
PENDING = "Pending",
|
|
27
|
-
ASSIGNED = "Assigned",
|
|
28
|
-
IN_PROGRESS = "In Progress",
|
|
29
|
-
APPROVED = "Approved",
|
|
30
|
-
REJECTED = "Rejected"
|
|
31
|
-
}
|
|
32
|
-
export declare class DutyMissionRequests extends BaseModel {
|
|
33
|
-
req_user_department_id: number | null;
|
|
34
|
-
req_user_section_id: number | null;
|
|
35
|
-
service_id: number;
|
|
36
|
-
sub_service_id: number;
|
|
37
|
-
user_id: number;
|
|
38
|
-
status: DutyMissionStatus;
|
|
39
|
-
workflow_execution_id: string | null;
|
|
40
|
-
request_id: string | null;
|
|
41
|
-
trip_type: TripType;
|
|
42
|
-
mission_id: string | null;
|
|
43
|
-
choose_type: ChooseType;
|
|
44
|
-
mission_sponsored_by: MissionSponsoredBy;
|
|
45
|
-
if_sponsored: string | null;
|
|
46
|
-
mission_purpose: string;
|
|
47
|
-
mission_number: string;
|
|
48
|
-
mission_start_date: Date;
|
|
49
|
-
mission_end_date: Date;
|
|
50
|
-
mission_days: number | null;
|
|
51
|
-
travelling_area_from: string;
|
|
52
|
-
travelling_area_to: string;
|
|
53
|
-
distance: string | null;
|
|
54
|
-
from_country: string;
|
|
55
|
-
to_country: string;
|
|
56
|
-
travel_place: string;
|
|
57
|
-
travel_start_date: Date;
|
|
58
|
-
travel_return_date: Date;
|
|
59
|
-
allowance_percentage: string | null;
|
|
60
|
-
air_ticket_required: AirTicketRequired | null;
|
|
61
|
-
passport_no: string;
|
|
62
|
-
passport_issue_date: Date | null;
|
|
63
|
-
passport_expiry_date: Date | null;
|
|
64
|
-
vehicle_required: VehicleRequired | null;
|
|
65
|
-
remarks: string | null;
|
|
66
|
-
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, passport_no: string, 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, passport_issue_date?: Date | null, passport_expiry_date?: Date | null, vehicle_required?: VehicleRequired | null, remarks?: string | null, workflow_execution_id?: string | null);
|
|
67
|
-
}
|