@platform-modules/foreign-ministry 1.1.42 → 1.1.44
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 +3 -11
- package/dist/data-source.js +3 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/models/GroupNamesModel.js +1 -1
- package/dist/models/JobsModel.d.ts +17 -0
- package/dist/models/{questionTagsModel.js → JobsModel.js} +29 -14
- package/dist/models/LeaveApprovalDetailsModel.d.ts +13 -0
- package/dist/models/LeaveApprovalDetailsModel.js +51 -0
- package/dist/models/LeaveApprovalMatrixModel.d.ts +7 -0
- package/dist/models/LeaveApprovalMatrixModel.js +40 -0
- package/dist/models/LeaveChatModel.d.ts +3 -0
- package/dist/models/LeaveChatModel.js +12 -0
- package/dist/models/LeaveWorkFlowModel.d.ts +5 -1
- package/dist/models/LeaveWorkFlowModel.js +22 -2
- package/dist/models/UpdateAttendenceRequestModel.d.ts +28 -0
- package/dist/models/UpdateAttendenceRequestModel.js +86 -0
- package/package.json +1 -1
- package/src/data-source.ts +3 -1
- package/src/index.ts +1 -0
- package/src/models/GroupNamesModel.ts +1 -1
- package/src/models/JobsModel.ts +37 -0
- package/src/models/LeaveChatModel.ts +10 -0
- package/src/models/LeaveWorkFlowModel.ts +17 -1
- package/dist/models/HelpContentMappedCategoriesModel.d.ts +0 -6
- package/dist/models/HelpContentMappedCategoriesModel.js +0 -34
- package/dist/models/HelpContentMappedTagsModel.d.ts +0 -6
- package/dist/models/HelpContentMappedTagsModel.js +0 -34
- package/dist/models/HelpContentTagsModel.d.ts +0 -5
- package/dist/models/HelpContentTagsModel.js +0 -29
- package/dist/models/questionTagsModel.d.ts +0 -6
package/.env
CHANGED
|
@@ -1,13 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
# DB_PORT=5433
|
|
3
|
-
# DB_USER=postgres
|
|
4
|
-
# DB_PASS=123
|
|
5
|
-
# DB_NAME=FM
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
DB_HOST=164.52.222.169
|
|
1
|
+
DB_HOST=localhost
|
|
10
2
|
DB_PORT=5432
|
|
11
|
-
DB_USER=
|
|
12
|
-
DB_PASS=
|
|
3
|
+
DB_USER=postgres
|
|
4
|
+
DB_PASS=Fa@123
|
|
13
5
|
DB_NAME=FM
|
package/dist/data-source.js
CHANGED
|
@@ -99,6 +99,7 @@ const TransferMissionWorkflowModel_1 = require("./models/TransferMissionWorkflow
|
|
|
99
99
|
const GroupNamesModel_1 = require("./models/GroupNamesModel");
|
|
100
100
|
const GroupModel_1 = require("./models/GroupModel");
|
|
101
101
|
const WorkScheduleModel_1 = require("./models/WorkScheduleModel");
|
|
102
|
+
const JobsModel_1 = require("./models/JobsModel");
|
|
102
103
|
exports.AppDataSource = new typeorm_1.DataSource({
|
|
103
104
|
type: 'postgres',
|
|
104
105
|
host: process.env.DB_HOST || 'localhost',
|
|
@@ -202,6 +203,7 @@ exports.AppDataSource = new typeorm_1.DataSource({
|
|
|
202
203
|
TransferMissionWorkflowModel_1.TransferMissionWorkFlow,
|
|
203
204
|
GroupNamesModel_1.GroupNames,
|
|
204
205
|
GroupModel_1.Group,
|
|
205
|
-
WorkScheduleModel_1.WorkSchedule
|
|
206
|
+
WorkScheduleModel_1.WorkSchedule,
|
|
207
|
+
JobsModel_1.Jobs
|
|
206
208
|
],
|
|
207
209
|
});
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -115,3 +115,4 @@ __exportStar(require("./models/TransferMissionWorkflowModel"), exports);
|
|
|
115
115
|
__exportStar(require("./models/GroupNamesModel"), exports);
|
|
116
116
|
__exportStar(require("./models/GroupModel"), exports);
|
|
117
117
|
__exportStar(require("./models/WorkScheduleModel"), exports);
|
|
118
|
+
__exportStar(require("./models/JobsModel"), exports);
|
|
@@ -25,7 +25,7 @@ __decorate([
|
|
|
25
25
|
__metadata("design:type", String)
|
|
26
26
|
], GroupNames.prototype, "name", void 0);
|
|
27
27
|
__decorate([
|
|
28
|
-
(0, typeorm_1.Column)({ nullable:
|
|
28
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
29
29
|
__metadata("design:type", String)
|
|
30
30
|
], GroupNames.prototype, "description", void 0);
|
|
31
31
|
exports.GroupNames = GroupNames = __decorate([
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author
|
|
3
|
+
* Amnet Digital
|
|
4
|
+
* @date
|
|
5
|
+
* 2024-12-20
|
|
6
|
+
* @Model
|
|
7
|
+
* Jobs
|
|
8
|
+
* @usage
|
|
9
|
+
* Jobs Information will store
|
|
10
|
+
*/
|
|
11
|
+
import { BaseModel } from './BaseModel';
|
|
12
|
+
export declare class Jobs extends BaseModel {
|
|
13
|
+
title: string;
|
|
14
|
+
grade: number;
|
|
15
|
+
description: string;
|
|
16
|
+
constructor(title: string, grade: number, description: string);
|
|
17
|
+
}
|
|
@@ -1,4 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* @author
|
|
4
|
+
* Amnet Digital
|
|
5
|
+
* @date
|
|
6
|
+
* 2024-12-20
|
|
7
|
+
* @Model
|
|
8
|
+
* Jobs
|
|
9
|
+
* @usage
|
|
10
|
+
* Jobs Information will store
|
|
11
|
+
*/
|
|
2
12
|
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
13
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
14
|
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
@@ -9,26 +19,31 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
9
19
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
20
|
};
|
|
11
21
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.
|
|
22
|
+
exports.Jobs = void 0;
|
|
13
23
|
const typeorm_1 = require("typeorm");
|
|
14
24
|
const BaseModel_1 = require("./BaseModel");
|
|
15
|
-
let
|
|
16
|
-
constructor(
|
|
25
|
+
let Jobs = class Jobs extends BaseModel_1.BaseModel {
|
|
26
|
+
constructor(title, grade, description) {
|
|
17
27
|
super();
|
|
18
|
-
this.
|
|
19
|
-
|
|
28
|
+
this.title = title;
|
|
29
|
+
this.grade = grade;
|
|
30
|
+
this.description = description;
|
|
20
31
|
}
|
|
21
32
|
};
|
|
22
|
-
exports.
|
|
33
|
+
exports.Jobs = Jobs;
|
|
23
34
|
__decorate([
|
|
24
|
-
(0, typeorm_1.Column)({ nullable:
|
|
35
|
+
(0, typeorm_1.Column)({ type: 'varchar', nullable: false }),
|
|
25
36
|
__metadata("design:type", String)
|
|
26
|
-
],
|
|
37
|
+
], Jobs.prototype, "title", void 0);
|
|
27
38
|
__decorate([
|
|
28
|
-
(0, typeorm_1.Column)({ nullable:
|
|
39
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: false }),
|
|
29
40
|
__metadata("design:type", Number)
|
|
30
|
-
],
|
|
31
|
-
|
|
32
|
-
(0, typeorm_1.
|
|
33
|
-
__metadata("design:
|
|
34
|
-
],
|
|
41
|
+
], Jobs.prototype, "grade", void 0);
|
|
42
|
+
__decorate([
|
|
43
|
+
(0, typeorm_1.Column)({ type: 'text', nullable: false }),
|
|
44
|
+
__metadata("design:type", String)
|
|
45
|
+
], Jobs.prototype, "description", void 0);
|
|
46
|
+
exports.Jobs = Jobs = __decorate([
|
|
47
|
+
(0, typeorm_1.Entity)({ name: 'jobs' }),
|
|
48
|
+
__metadata("design:paramtypes", [String, Number, String])
|
|
49
|
+
], Jobs);
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { BaseModel } from './BaseModel';
|
|
2
|
+
export declare enum ApprovalStatus {
|
|
3
|
+
PENDING = "Pending",
|
|
4
|
+
APPROVED = "Approved",
|
|
5
|
+
REJECTED = "Rejected"
|
|
6
|
+
}
|
|
7
|
+
export declare class LeaveApprovalDetails extends BaseModel {
|
|
8
|
+
leave_request_id: number;
|
|
9
|
+
level: number;
|
|
10
|
+
approver_id: number;
|
|
11
|
+
approval_status: ApprovalStatus;
|
|
12
|
+
constructor(leave_request_id: number, approver_id: number, approval_status: ApprovalStatus, level: number);
|
|
13
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
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.LeaveApprovalDetails = exports.ApprovalStatus = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
const BaseModel_1 = require("./BaseModel");
|
|
15
|
+
var ApprovalStatus;
|
|
16
|
+
(function (ApprovalStatus) {
|
|
17
|
+
ApprovalStatus["PENDING"] = "Pending";
|
|
18
|
+
ApprovalStatus["APPROVED"] = "Approved";
|
|
19
|
+
ApprovalStatus["REJECTED"] = "Rejected";
|
|
20
|
+
})(ApprovalStatus || (exports.ApprovalStatus = ApprovalStatus = {}));
|
|
21
|
+
//This model is used to store the store the leave apporval details of the user for the leave request
|
|
22
|
+
let LeaveApprovalDetails = class LeaveApprovalDetails extends BaseModel_1.BaseModel {
|
|
23
|
+
constructor(leave_request_id, approver_id, approval_status, level) {
|
|
24
|
+
super();
|
|
25
|
+
this.leave_request_id = leave_request_id;
|
|
26
|
+
this.approver_id = approver_id;
|
|
27
|
+
this.approval_status = approval_status;
|
|
28
|
+
this.level = level;
|
|
29
|
+
}
|
|
30
|
+
};
|
|
31
|
+
exports.LeaveApprovalDetails = LeaveApprovalDetails;
|
|
32
|
+
__decorate([
|
|
33
|
+
(0, typeorm_1.Column)({ type: 'int', nullable: false }),
|
|
34
|
+
__metadata("design:type", Number)
|
|
35
|
+
], LeaveApprovalDetails.prototype, "leave_request_id", void 0);
|
|
36
|
+
__decorate([
|
|
37
|
+
(0, typeorm_1.Column)({ type: 'int', nullable: false }),
|
|
38
|
+
__metadata("design:type", Number)
|
|
39
|
+
], LeaveApprovalDetails.prototype, "level", void 0);
|
|
40
|
+
__decorate([
|
|
41
|
+
(0, typeorm_1.Column)({ type: 'int', nullable: false }),
|
|
42
|
+
__metadata("design:type", Number)
|
|
43
|
+
], LeaveApprovalDetails.prototype, "approver_id", void 0);
|
|
44
|
+
__decorate([
|
|
45
|
+
(0, typeorm_1.Column)({ type: 'enum', enum: ApprovalStatus, default: ApprovalStatus.PENDING, nullable: false }),
|
|
46
|
+
__metadata("design:type", String)
|
|
47
|
+
], LeaveApprovalDetails.prototype, "approval_status", void 0);
|
|
48
|
+
exports.LeaveApprovalDetails = LeaveApprovalDetails = __decorate([
|
|
49
|
+
(0, typeorm_1.Entity)({ name: 'leave_approval_details' }),
|
|
50
|
+
__metadata("design:paramtypes", [Number, Number, String, Number])
|
|
51
|
+
], LeaveApprovalDetails);
|
|
@@ -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.LeaveApprovalMatrix = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
const BaseModel_1 = require("./BaseModel");
|
|
15
|
+
//This model is used to store the store the leave apporval matrix(HOD, Manager, HR, Director) based on leave type along with the levels
|
|
16
|
+
let LeaveApprovalMatrix = class LeaveApprovalMatrix extends BaseModel_1.BaseModel {
|
|
17
|
+
constructor(leave_type, level, approval_matrix) {
|
|
18
|
+
super();
|
|
19
|
+
this.leave_type = leave_type;
|
|
20
|
+
this.level = level;
|
|
21
|
+
this.approval_matrix = approval_matrix;
|
|
22
|
+
}
|
|
23
|
+
};
|
|
24
|
+
exports.LeaveApprovalMatrix = LeaveApprovalMatrix;
|
|
25
|
+
__decorate([
|
|
26
|
+
(0, typeorm_1.Column)({ type: 'int', nullable: false }),
|
|
27
|
+
__metadata("design:type", Number)
|
|
28
|
+
], LeaveApprovalMatrix.prototype, "leave_type", void 0);
|
|
29
|
+
__decorate([
|
|
30
|
+
(0, typeorm_1.Column)({ type: 'int', nullable: false }),
|
|
31
|
+
__metadata("design:type", Number)
|
|
32
|
+
], LeaveApprovalMatrix.prototype, "level", void 0);
|
|
33
|
+
__decorate([
|
|
34
|
+
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: false }),
|
|
35
|
+
__metadata("design:type", String)
|
|
36
|
+
], LeaveApprovalMatrix.prototype, "approval_matrix", void 0);
|
|
37
|
+
exports.LeaveApprovalMatrix = LeaveApprovalMatrix = __decorate([
|
|
38
|
+
(0, typeorm_1.Entity)({ name: 'leave_approval_matrix' }),
|
|
39
|
+
__metadata("design:paramtypes", [Number, Number, String])
|
|
40
|
+
], LeaveApprovalMatrix);
|
|
@@ -3,5 +3,8 @@ export declare class LeaveChat extends BaseModel {
|
|
|
3
3
|
leave_request_id: number;
|
|
4
4
|
content: string;
|
|
5
5
|
sender_user_id: number;
|
|
6
|
+
service_id: number | null;
|
|
7
|
+
sub_service_id: number | null;
|
|
8
|
+
role_id: number;
|
|
6
9
|
constructor(leave_request_id: number, content: string, sender_user_id: number);
|
|
7
10
|
}
|
|
@@ -34,6 +34,18 @@ __decorate([
|
|
|
34
34
|
(0, typeorm_1.Column)({ type: 'int', nullable: false }),
|
|
35
35
|
__metadata("design:type", Number)
|
|
36
36
|
], LeaveChat.prototype, "sender_user_id", void 0);
|
|
37
|
+
__decorate([
|
|
38
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
39
|
+
__metadata("design:type", Object)
|
|
40
|
+
], LeaveChat.prototype, "service_id", void 0);
|
|
41
|
+
__decorate([
|
|
42
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
43
|
+
__metadata("design:type", Object)
|
|
44
|
+
], LeaveChat.prototype, "sub_service_id", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
47
|
+
__metadata("design:type", Number)
|
|
48
|
+
], LeaveChat.prototype, "role_id", void 0);
|
|
37
49
|
exports.LeaveChat = LeaveChat = __decorate([
|
|
38
50
|
(0, typeorm_1.Entity)({ name: 'leave_chats' }),
|
|
39
51
|
__metadata("design:paramtypes", [Number, String, Number])
|
|
@@ -9,5 +9,9 @@ export declare class LeaveWorkFlow extends BaseModel {
|
|
|
9
9
|
leave_approval_details_id: number;
|
|
10
10
|
content: string;
|
|
11
11
|
status: workFlowStatus;
|
|
12
|
-
|
|
12
|
+
user_id: number | null;
|
|
13
|
+
role_id: number | null;
|
|
14
|
+
department_id: number | null;
|
|
15
|
+
section_id: number | null;
|
|
16
|
+
constructor(leave_request_id: number, leave_approval_details_id: number, content: string, status: workFlowStatus, user_id: number, role_id: number, department_id: number, section_id: number);
|
|
13
17
|
}
|
|
@@ -20,12 +20,16 @@ var workFlowStatus;
|
|
|
20
20
|
})(workFlowStatus || (exports.workFlowStatus = workFlowStatus = {}));
|
|
21
21
|
//This model is used to store the store the leave apporval matrix(HOD, Manager, HR, Director) based on leave type along with the levels
|
|
22
22
|
let LeaveWorkFlow = class LeaveWorkFlow extends BaseModel_1.BaseModel {
|
|
23
|
-
constructor(leave_request_id, leave_approval_details_id, content, status) {
|
|
23
|
+
constructor(leave_request_id, leave_approval_details_id, content, status, user_id, role_id, department_id, section_id) {
|
|
24
24
|
super();
|
|
25
25
|
this.leave_request_id = leave_request_id;
|
|
26
26
|
this.leave_approval_details_id = leave_approval_details_id;
|
|
27
27
|
this.content = content;
|
|
28
28
|
this.status = status;
|
|
29
|
+
this.user_id = user_id;
|
|
30
|
+
this.role_id = role_id;
|
|
31
|
+
this.department_id = department_id;
|
|
32
|
+
this.section_id = section_id;
|
|
29
33
|
}
|
|
30
34
|
};
|
|
31
35
|
exports.LeaveWorkFlow = LeaveWorkFlow;
|
|
@@ -45,7 +49,23 @@ __decorate([
|
|
|
45
49
|
(0, typeorm_1.Column)({ type: 'enum', enum: workFlowStatus, default: workFlowStatus.NOT_YET_STARTED, nullable: false }),
|
|
46
50
|
__metadata("design:type", String)
|
|
47
51
|
], LeaveWorkFlow.prototype, "status", void 0);
|
|
52
|
+
__decorate([
|
|
53
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
54
|
+
__metadata("design:type", Object)
|
|
55
|
+
], LeaveWorkFlow.prototype, "user_id", void 0);
|
|
56
|
+
__decorate([
|
|
57
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
58
|
+
__metadata("design:type", Object)
|
|
59
|
+
], LeaveWorkFlow.prototype, "role_id", void 0);
|
|
60
|
+
__decorate([
|
|
61
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
62
|
+
__metadata("design:type", Object)
|
|
63
|
+
], LeaveWorkFlow.prototype, "department_id", void 0);
|
|
64
|
+
__decorate([
|
|
65
|
+
(0, typeorm_1.Column)({ type: 'integer', nullable: true }),
|
|
66
|
+
__metadata("design:type", Object)
|
|
67
|
+
], LeaveWorkFlow.prototype, "section_id", void 0);
|
|
48
68
|
exports.LeaveWorkFlow = LeaveWorkFlow = __decorate([
|
|
49
69
|
(0, typeorm_1.Entity)({ name: 'leave_work_flows' }),
|
|
50
|
-
__metadata("design:paramtypes", [Number, Number, String, String])
|
|
70
|
+
__metadata("design:paramtypes", [Number, Number, String, String, Number, Number, Number, Number])
|
|
51
71
|
], LeaveWorkFlow);
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { BaseModel } from './BaseModel';
|
|
2
|
+
export declare enum UpdateAttendenceStatus {
|
|
3
|
+
PENDING = "Pending",
|
|
4
|
+
ASSIGNED = "Assigned",
|
|
5
|
+
IN_PROGRESS = "In Progress",
|
|
6
|
+
APPROVED = "Approved",
|
|
7
|
+
REJECTED = "Rejected"
|
|
8
|
+
}
|
|
9
|
+
export declare enum UpdateAttendenceReason {
|
|
10
|
+
MEETING = "Meeting",
|
|
11
|
+
EARLY_CHECKOUT = "Early Checkout",
|
|
12
|
+
SPECIAL_REASON = "Special Reason"
|
|
13
|
+
}
|
|
14
|
+
export declare class UpdateAttendenceRequests extends BaseModel {
|
|
15
|
+
req_user_department_id: number | null;
|
|
16
|
+
req_user_section_id: number | null;
|
|
17
|
+
service_id: number | null;
|
|
18
|
+
sub_service_id: number | null;
|
|
19
|
+
user_id: number;
|
|
20
|
+
from_date: string | null;
|
|
21
|
+
to_date: string | null;
|
|
22
|
+
from_time: string | null;
|
|
23
|
+
to_time: string | null;
|
|
24
|
+
reason: UpdateAttendenceReason;
|
|
25
|
+
comments: string | null;
|
|
26
|
+
status: UpdateAttendenceStatus;
|
|
27
|
+
workflow_execution_id: string | null;
|
|
28
|
+
}
|
|
@@ -0,0 +1,86 @@
|
|
|
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.UpdateAttendenceRequests = exports.UpdateAttendenceReason = exports.UpdateAttendenceStatus = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
const BaseModel_1 = require("./BaseModel");
|
|
15
|
+
var UpdateAttendenceStatus;
|
|
16
|
+
(function (UpdateAttendenceStatus) {
|
|
17
|
+
UpdateAttendenceStatus["PENDING"] = "Pending";
|
|
18
|
+
UpdateAttendenceStatus["ASSIGNED"] = "Assigned";
|
|
19
|
+
UpdateAttendenceStatus["IN_PROGRESS"] = "In Progress";
|
|
20
|
+
UpdateAttendenceStatus["APPROVED"] = "Approved";
|
|
21
|
+
UpdateAttendenceStatus["REJECTED"] = "Rejected";
|
|
22
|
+
})(UpdateAttendenceStatus || (exports.UpdateAttendenceStatus = UpdateAttendenceStatus = {}));
|
|
23
|
+
var UpdateAttendenceReason;
|
|
24
|
+
(function (UpdateAttendenceReason) {
|
|
25
|
+
UpdateAttendenceReason["MEETING"] = "Meeting";
|
|
26
|
+
UpdateAttendenceReason["EARLY_CHECKOUT"] = "Early Checkout";
|
|
27
|
+
UpdateAttendenceReason["SPECIAL_REASON"] = "Special Reason";
|
|
28
|
+
})(UpdateAttendenceReason || (exports.UpdateAttendenceReason = UpdateAttendenceReason = {}));
|
|
29
|
+
let UpdateAttendenceRequests = class UpdateAttendenceRequests extends BaseModel_1.BaseModel {
|
|
30
|
+
};
|
|
31
|
+
exports.UpdateAttendenceRequests = UpdateAttendenceRequests;
|
|
32
|
+
__decorate([
|
|
33
|
+
(0, typeorm_1.Column)({ type: 'int', nullable: true }),
|
|
34
|
+
__metadata("design:type", Object)
|
|
35
|
+
], UpdateAttendenceRequests.prototype, "req_user_department_id", void 0);
|
|
36
|
+
__decorate([
|
|
37
|
+
(0, typeorm_1.Column)({ type: 'int', nullable: true }),
|
|
38
|
+
__metadata("design:type", Object)
|
|
39
|
+
], UpdateAttendenceRequests.prototype, "req_user_section_id", void 0);
|
|
40
|
+
__decorate([
|
|
41
|
+
(0, typeorm_1.Column)({ type: 'int', nullable: true }),
|
|
42
|
+
__metadata("design:type", Object)
|
|
43
|
+
], UpdateAttendenceRequests.prototype, "service_id", void 0);
|
|
44
|
+
__decorate([
|
|
45
|
+
(0, typeorm_1.Column)({ type: 'int', nullable: true }),
|
|
46
|
+
__metadata("design:type", Object)
|
|
47
|
+
], UpdateAttendenceRequests.prototype, "sub_service_id", void 0);
|
|
48
|
+
__decorate([
|
|
49
|
+
(0, typeorm_1.Column)({ type: 'int', nullable: false }),
|
|
50
|
+
__metadata("design:type", Number)
|
|
51
|
+
], UpdateAttendenceRequests.prototype, "user_id", void 0);
|
|
52
|
+
__decorate([
|
|
53
|
+
(0, typeorm_1.Column)({ type: 'date', nullable: true }),
|
|
54
|
+
__metadata("design:type", Object)
|
|
55
|
+
], UpdateAttendenceRequests.prototype, "from_date", void 0);
|
|
56
|
+
__decorate([
|
|
57
|
+
(0, typeorm_1.Column)({ type: 'date', nullable: true }),
|
|
58
|
+
__metadata("design:type", Object)
|
|
59
|
+
], UpdateAttendenceRequests.prototype, "to_date", void 0);
|
|
60
|
+
__decorate([
|
|
61
|
+
(0, typeorm_1.Column)({ type: 'time', nullable: true }),
|
|
62
|
+
__metadata("design:type", Object)
|
|
63
|
+
], UpdateAttendenceRequests.prototype, "from_time", void 0);
|
|
64
|
+
__decorate([
|
|
65
|
+
(0, typeorm_1.Column)({ type: 'time', nullable: true }),
|
|
66
|
+
__metadata("design:type", Object)
|
|
67
|
+
], UpdateAttendenceRequests.prototype, "to_time", void 0);
|
|
68
|
+
__decorate([
|
|
69
|
+
(0, typeorm_1.Column)({ type: 'enum', enum: UpdateAttendenceReason, nullable: false }),
|
|
70
|
+
__metadata("design:type", String)
|
|
71
|
+
], UpdateAttendenceRequests.prototype, "reason", void 0);
|
|
72
|
+
__decorate([
|
|
73
|
+
(0, typeorm_1.Column)({ type: 'varchar', length: 500, nullable: true }),
|
|
74
|
+
__metadata("design:type", Object)
|
|
75
|
+
], UpdateAttendenceRequests.prototype, "comments", void 0);
|
|
76
|
+
__decorate([
|
|
77
|
+
(0, typeorm_1.Column)({ type: 'enum', enum: UpdateAttendenceStatus, default: UpdateAttendenceStatus.PENDING, nullable: false }),
|
|
78
|
+
__metadata("design:type", String)
|
|
79
|
+
], UpdateAttendenceRequests.prototype, "status", void 0);
|
|
80
|
+
__decorate([
|
|
81
|
+
(0, typeorm_1.Column)({ type: 'varchar', nullable: true }),
|
|
82
|
+
__metadata("design:type", Object)
|
|
83
|
+
], UpdateAttendenceRequests.prototype, "workflow_execution_id", void 0);
|
|
84
|
+
exports.UpdateAttendenceRequests = UpdateAttendenceRequests = __decorate([
|
|
85
|
+
(0, typeorm_1.Entity)({ name: 'update_attendence_requests' })
|
|
86
|
+
], UpdateAttendenceRequests);
|
package/package.json
CHANGED
package/src/data-source.ts
CHANGED
|
@@ -104,6 +104,7 @@ import { TransferMissionWorkFlow } from './models/TransferMissionWorkflowModel';
|
|
|
104
104
|
import { GroupNames } from './models/GroupNamesModel';
|
|
105
105
|
import { Group } from './models/GroupModel';
|
|
106
106
|
import { WorkSchedule } from './models/WorkScheduleModel';
|
|
107
|
+
import { Jobs } from './models/JobsModel';
|
|
107
108
|
export const AppDataSource = new DataSource({
|
|
108
109
|
type: 'postgres',
|
|
109
110
|
host: process.env.DB_HOST || 'localhost',
|
|
@@ -207,6 +208,7 @@ export const AppDataSource = new DataSource({
|
|
|
207
208
|
TransferMissionWorkFlow,
|
|
208
209
|
GroupNames,
|
|
209
210
|
Group,
|
|
210
|
-
WorkSchedule
|
|
211
|
+
WorkSchedule,
|
|
212
|
+
Jobs
|
|
211
213
|
],
|
|
212
214
|
});
|
package/src/index.ts
CHANGED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author
|
|
3
|
+
* Amnet Digital
|
|
4
|
+
* @date
|
|
5
|
+
* 2024-12-20
|
|
6
|
+
* @Model
|
|
7
|
+
* Jobs
|
|
8
|
+
* @usage
|
|
9
|
+
* Jobs Information will store
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
import { Column, Entity } from "typeorm";
|
|
13
|
+
import { BaseModel } from './BaseModel';
|
|
14
|
+
|
|
15
|
+
@Entity({ name: 'jobs' })
|
|
16
|
+
export class Jobs extends BaseModel {
|
|
17
|
+
@Column({ type: 'varchar', nullable: false })
|
|
18
|
+
title: string;
|
|
19
|
+
|
|
20
|
+
@Column({ type: 'integer', nullable: false })
|
|
21
|
+
grade: number;
|
|
22
|
+
|
|
23
|
+
@Column({ type: 'text', nullable: false })
|
|
24
|
+
description: string;
|
|
25
|
+
|
|
26
|
+
constructor(
|
|
27
|
+
title: string,
|
|
28
|
+
grade: number,
|
|
29
|
+
description: string
|
|
30
|
+
) {
|
|
31
|
+
super();
|
|
32
|
+
this.title = title;
|
|
33
|
+
this.grade = grade;
|
|
34
|
+
this.description = description;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
@@ -12,6 +12,16 @@ export class LeaveChat extends BaseModel {
|
|
|
12
12
|
@Column({ type: 'int', nullable: false })
|
|
13
13
|
sender_user_id: number;
|
|
14
14
|
|
|
15
|
+
@Column({ type: 'integer', nullable: true })
|
|
16
|
+
service_id: number | null;
|
|
17
|
+
|
|
18
|
+
@Column({ type: 'integer', nullable: true })
|
|
19
|
+
sub_service_id: number | null;
|
|
20
|
+
|
|
21
|
+
@Column({ type: 'integer', nullable: true })
|
|
22
|
+
role_id: number;
|
|
23
|
+
|
|
24
|
+
|
|
15
25
|
constructor(leave_request_id: number, content: string, sender_user_id: number) {
|
|
16
26
|
super();
|
|
17
27
|
this.leave_request_id = leave_request_id;
|
|
@@ -22,11 +22,27 @@ export class LeaveWorkFlow extends BaseModel {
|
|
|
22
22
|
@Column({ type: 'enum', enum: workFlowStatus, default: workFlowStatus.NOT_YET_STARTED, nullable: false })
|
|
23
23
|
status: workFlowStatus;
|
|
24
24
|
|
|
25
|
-
|
|
25
|
+
@Column({ type: 'integer', nullable: true })
|
|
26
|
+
user_id: number | null;
|
|
27
|
+
|
|
28
|
+
@Column({ type: 'integer', nullable: true })
|
|
29
|
+
role_id: number | null;
|
|
30
|
+
|
|
31
|
+
@Column({ type: 'integer', nullable: true })
|
|
32
|
+
department_id: number | null;
|
|
33
|
+
|
|
34
|
+
@Column({ type: 'integer', nullable: true })
|
|
35
|
+
section_id: number | null;
|
|
36
|
+
|
|
37
|
+
constructor(leave_request_id: number, leave_approval_details_id: number, content: string, status: workFlowStatus, user_id: number, role_id: number, department_id: number, section_id: number) {
|
|
26
38
|
super();
|
|
27
39
|
this.leave_request_id = leave_request_id;
|
|
28
40
|
this.leave_approval_details_id = leave_approval_details_id;
|
|
29
41
|
this.content = content;
|
|
30
42
|
this.status = status;
|
|
43
|
+
this.user_id = user_id;
|
|
44
|
+
this.role_id = role_id;
|
|
45
|
+
this.department_id = department_id;
|
|
46
|
+
this.section_id = section_id;
|
|
31
47
|
}
|
|
32
48
|
}
|
|
@@ -1,34 +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.HelpContentMappedCategories = void 0;
|
|
13
|
-
const typeorm_1 = require("typeorm");
|
|
14
|
-
const BaseModel_1 = require("./BaseModel");
|
|
15
|
-
let HelpContentMappedCategories = class HelpContentMappedCategories extends BaseModel_1.BaseModel {
|
|
16
|
-
constructor(help_content_category_Id, help_content_Id) {
|
|
17
|
-
super();
|
|
18
|
-
this.help_content_category_Id = help_content_category_Id,
|
|
19
|
-
this.help_content_Id = help_content_Id;
|
|
20
|
-
}
|
|
21
|
-
};
|
|
22
|
-
exports.HelpContentMappedCategories = HelpContentMappedCategories;
|
|
23
|
-
__decorate([
|
|
24
|
-
(0, typeorm_1.Column)({ nullable: true }),
|
|
25
|
-
__metadata("design:type", Number)
|
|
26
|
-
], HelpContentMappedCategories.prototype, "help_content_category_Id", void 0);
|
|
27
|
-
__decorate([
|
|
28
|
-
(0, typeorm_1.Column)({ nullable: true }),
|
|
29
|
-
__metadata("design:type", Number)
|
|
30
|
-
], HelpContentMappedCategories.prototype, "help_content_Id", void 0);
|
|
31
|
-
exports.HelpContentMappedCategories = HelpContentMappedCategories = __decorate([
|
|
32
|
-
(0, typeorm_1.Entity)({ name: 'help_content_mapped_categories' }),
|
|
33
|
-
__metadata("design:paramtypes", [Number, Number])
|
|
34
|
-
], HelpContentMappedCategories);
|
|
@@ -1,34 +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.HelpContentMappedTags = void 0;
|
|
13
|
-
const typeorm_1 = require("typeorm");
|
|
14
|
-
const BaseModel_1 = require("./BaseModel");
|
|
15
|
-
let HelpContentMappedTags = class HelpContentMappedTags extends BaseModel_1.BaseModel {
|
|
16
|
-
constructor(help_content_tag_Id, help_content_Id) {
|
|
17
|
-
super();
|
|
18
|
-
this.help_content_tag_Id = help_content_tag_Id,
|
|
19
|
-
this.help_content_Id = help_content_Id;
|
|
20
|
-
}
|
|
21
|
-
};
|
|
22
|
-
exports.HelpContentMappedTags = HelpContentMappedTags;
|
|
23
|
-
__decorate([
|
|
24
|
-
(0, typeorm_1.Column)({ nullable: true }),
|
|
25
|
-
__metadata("design:type", Number)
|
|
26
|
-
], HelpContentMappedTags.prototype, "help_content_tag_Id", void 0);
|
|
27
|
-
__decorate([
|
|
28
|
-
(0, typeorm_1.Column)({ nullable: true }),
|
|
29
|
-
__metadata("design:type", Number)
|
|
30
|
-
], HelpContentMappedTags.prototype, "help_content_Id", void 0);
|
|
31
|
-
exports.HelpContentMappedTags = HelpContentMappedTags = __decorate([
|
|
32
|
-
(0, typeorm_1.Entity)({ name: 'help_content_mapped_tags' }),
|
|
33
|
-
__metadata("design:paramtypes", [Number, Number])
|
|
34
|
-
], HelpContentMappedTags);
|
|
@@ -1,29 +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.HelpContentTags = void 0;
|
|
13
|
-
const typeorm_1 = require("typeorm");
|
|
14
|
-
const BaseModel_1 = require("./BaseModel");
|
|
15
|
-
let HelpContentTags = class HelpContentTags extends BaseModel_1.BaseModel {
|
|
16
|
-
constructor(name) {
|
|
17
|
-
super();
|
|
18
|
-
this.name = name;
|
|
19
|
-
}
|
|
20
|
-
};
|
|
21
|
-
exports.HelpContentTags = HelpContentTags;
|
|
22
|
-
__decorate([
|
|
23
|
-
(0, typeorm_1.Column)({ nullable: true }),
|
|
24
|
-
__metadata("design:type", String)
|
|
25
|
-
], HelpContentTags.prototype, "name", void 0);
|
|
26
|
-
exports.HelpContentTags = HelpContentTags = __decorate([
|
|
27
|
-
(0, typeorm_1.Entity)({ name: 'help_content_tags' }),
|
|
28
|
-
__metadata("design:paramtypes", [String])
|
|
29
|
-
], HelpContentTags);
|