@platform-modules/foreign-ministry 1.0.93 → 1.0.94
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 +10 -2
- package/dist/data-source.js +2 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/models/HelpContentMappedCategoriesModel.d.ts +6 -0
- package/dist/models/HelpContentMappedCategoriesModel.js +34 -0
- package/dist/models/HelpContentMappedTagsModel.d.ts +6 -0
- package/dist/models/HelpContentMappedTagsModel.js +34 -0
- package/dist/models/HelpContentTagsModel.d.ts +5 -0
- package/dist/models/HelpContentTagsModel.js +29 -0
- package/dist/models/LeaveApprovalsModel.d.ts +1 -3
- package/dist/models/LeaveApprovalsModel.js +3 -13
- package/dist/models/LeaveRequestModel.d.ts +1 -4
- package/dist/models/LeaveRequestModel.js +2 -17
- package/dist/models/importantLinksModel.d.ts +6 -0
- package/dist/models/importantLinksModel.js +34 -0
- package/dist/models/questionTagsModel.d.ts +6 -0
- package/dist/models/questionTagsModel.js +34 -0
- package/package.json +1 -1
- package/src/data-source.ts +2 -0
- package/src/index.ts +1 -0
- package/src/models/LeaveApprovalsModel.ts +2 -10
- package/src/models/LeaveRequestModel.ts +1 -13
- package/src/models/importantLinksModel.ts +22 -0
- package/dist/models/LeaveApprovalDetailsModel.d.ts +0 -13
- package/dist/models/LeaveApprovalDetailsModel.js +0 -51
- package/dist/models/LeaveApprovalMatrixModel.d.ts +0 -7
- package/dist/models/LeaveApprovalMatrixModel.js +0 -40
package/.env
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
DB_HOST=localhost
|
|
2
|
-
DB_PORT=
|
|
2
|
+
DB_PORT=5433
|
|
3
3
|
DB_USER=postgres
|
|
4
|
-
DB_PASS=
|
|
4
|
+
DB_PASS=123
|
|
5
5
|
DB_NAME=FM
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
# DB_HOST=164.52.222.169
|
|
10
|
+
# DB_PORT=5432
|
|
11
|
+
# DB_USER=postgres_admin_user
|
|
12
|
+
# DB_PASS=pg_admin_user_pwd_caa_fa_$%^&OIukhjgcvbn
|
|
13
|
+
# DB_NAME=FM
|
package/dist/data-source.js
CHANGED
|
@@ -70,6 +70,7 @@ const WorkflowTask_1 = require("./models/WorkflowTask");
|
|
|
70
70
|
const WorkflowTaskNames_1 = require("./models/WorkflowTaskNames");
|
|
71
71
|
const WorkflowDefinitions_1 = require("./models/WorkflowDefinitions");
|
|
72
72
|
const WorkflowHierarchy_1 = require("./models/WorkflowHierarchy");
|
|
73
|
+
const importantLinksModel_1 = require("./models/importantLinksModel");
|
|
73
74
|
exports.AppDataSource = new typeorm_1.DataSource({
|
|
74
75
|
type: 'postgres',
|
|
75
76
|
host: process.env.DB_HOST || 'localhost',
|
|
@@ -145,5 +146,6 @@ exports.AppDataSource = new typeorm_1.DataSource({
|
|
|
145
146
|
WorkflowTaskNames_1.WorkflowTaskNames,
|
|
146
147
|
WorkflowDefinitions_1.WorkflowDefinitions,
|
|
147
148
|
WorkflowHierarchy_1.WorkflowHierarchy,
|
|
149
|
+
importantLinksModel_1.ImportantLinks,
|
|
148
150
|
],
|
|
149
151
|
});
|
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -79,3 +79,4 @@ __exportStar(require("./models/WorkflowTask"), exports);
|
|
|
79
79
|
__exportStar(require("./models/WorkflowTaskNames"), exports);
|
|
80
80
|
__exportStar(require("./models/WorkflowDefinitions"), exports);
|
|
81
81
|
__exportStar(require("./models/WorkflowHierarchy"), exports);
|
|
82
|
+
__exportStar(require("./models/importantLinksModel"), exports);
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.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);
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.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);
|
|
@@ -0,0 +1,29 @@
|
|
|
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);
|
|
@@ -9,9 +9,7 @@ export declare class LeaveApprovalDetails extends BaseModel {
|
|
|
9
9
|
level: number;
|
|
10
10
|
approver_user_id: number;
|
|
11
11
|
approver_role_id: number;
|
|
12
|
-
department_id: number;
|
|
13
|
-
section_id: number;
|
|
14
12
|
comment: string;
|
|
15
13
|
approval_status: ApprovalStatus;
|
|
16
|
-
constructor(leave_request_id: number, approver_user_id: number, approver_role_id: number, comment: string, approval_status: ApprovalStatus, level: number
|
|
14
|
+
constructor(leave_request_id: number, approver_user_id: number, approver_role_id: number, comment: string, approval_status: ApprovalStatus, level: number);
|
|
17
15
|
}
|
|
@@ -20,13 +20,11 @@ var ApprovalStatus;
|
|
|
20
20
|
})(ApprovalStatus || (exports.ApprovalStatus = ApprovalStatus = {}));
|
|
21
21
|
//This model is used to store the store the leave apporval details of the user for the leave request
|
|
22
22
|
let LeaveApprovalDetails = class LeaveApprovalDetails extends BaseModel_1.BaseModel {
|
|
23
|
-
constructor(leave_request_id, approver_user_id, approver_role_id, comment, approval_status, level
|
|
23
|
+
constructor(leave_request_id, approver_user_id, approver_role_id, comment, approval_status, level) {
|
|
24
24
|
super();
|
|
25
25
|
this.leave_request_id = leave_request_id;
|
|
26
26
|
this.approver_user_id = approver_user_id;
|
|
27
27
|
this.approver_role_id = approver_role_id;
|
|
28
|
-
this.department_id = department_id;
|
|
29
|
-
this.section_id = section_id;
|
|
30
28
|
this.comment = comment;
|
|
31
29
|
this.approval_status = approval_status;
|
|
32
30
|
this.level = level;
|
|
@@ -46,17 +44,9 @@ __decorate([
|
|
|
46
44
|
__metadata("design:type", Number)
|
|
47
45
|
], LeaveApprovalDetails.prototype, "approver_user_id", void 0);
|
|
48
46
|
__decorate([
|
|
49
|
-
(0, typeorm_1.Column)({ type: 'int', nullable:
|
|
47
|
+
(0, typeorm_1.Column)({ type: 'int', nullable: false }),
|
|
50
48
|
__metadata("design:type", Number)
|
|
51
49
|
], LeaveApprovalDetails.prototype, "approver_role_id", void 0);
|
|
52
|
-
__decorate([
|
|
53
|
-
(0, typeorm_1.Column)({ type: 'int', nullable: true }),
|
|
54
|
-
__metadata("design:type", Number)
|
|
55
|
-
], LeaveApprovalDetails.prototype, "department_id", void 0);
|
|
56
|
-
__decorate([
|
|
57
|
-
(0, typeorm_1.Column)({ type: 'int', nullable: true }),
|
|
58
|
-
__metadata("design:type", Number)
|
|
59
|
-
], LeaveApprovalDetails.prototype, "section_id", void 0);
|
|
60
50
|
__decorate([
|
|
61
51
|
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: false }),
|
|
62
52
|
__metadata("design:type", String)
|
|
@@ -67,5 +57,5 @@ __decorate([
|
|
|
67
57
|
], LeaveApprovalDetails.prototype, "approval_status", void 0);
|
|
68
58
|
exports.LeaveApprovalDetails = LeaveApprovalDetails = __decorate([
|
|
69
59
|
(0, typeorm_1.Entity)({ name: 'leave_approvals' }),
|
|
70
|
-
__metadata("design:paramtypes", [Number, Number, Number, String, String, Number
|
|
60
|
+
__metadata("design:paramtypes", [Number, Number, Number, String, String, Number])
|
|
71
61
|
], LeaveApprovalDetails);
|
|
@@ -33,8 +33,5 @@ export declare class LeaveRequests extends BaseModel {
|
|
|
33
33
|
activity_title: string;
|
|
34
34
|
relationship: string;
|
|
35
35
|
mounring_leave_relation: number;
|
|
36
|
-
|
|
37
|
-
sub_service_id: number | null;
|
|
38
|
-
workflow_execution_id: string | null;
|
|
39
|
-
constructor(user_id: string, leave_for: Leave_For, leave_type: number, department: string, status: status, leave_start_date: Date, leave_end_date: Date, leave_duration: number, remaining_leave_balance: number, contact_number_during_leave: string, address_during_leave: string, notes: string, delegated_to: string, number_of_escort_instances_per_year: number, accompanying_the_patient: boolean, treatment_place: string, emergency_leaves_available: number, unpaid_leave_type: string, country_or_state_being_visited: string, leave_balance_summary: string, representation: string, activity_title: string, relationship: string, mounring_leave_relation: number, service_id: number, sub_service_id: number, workflow_execution_id: string);
|
|
36
|
+
constructor(user_id: string, leave_for: Leave_For, leave_type: number, department: string, status: status, leave_start_date: Date, leave_end_date: Date, leave_duration: number, remaining_leave_balance: number, contact_number_during_leave: string, address_during_leave: string, notes: string, delegated_to: string, number_of_escort_instances_per_year: number, accompanying_the_patient: boolean, treatment_place: string, emergency_leaves_available: number, unpaid_leave_type: string, country_or_state_being_visited: string, leave_balance_summary: string, representation: string, activity_title: string, relationship: string, mounring_leave_relation: number);
|
|
40
37
|
}
|
|
@@ -25,7 +25,7 @@ var status;
|
|
|
25
25
|
status["REJECTED"] = "Rejected";
|
|
26
26
|
})(status || (exports.status = status = {}));
|
|
27
27
|
let LeaveRequests = class LeaveRequests extends BaseModel_1.BaseModel {
|
|
28
|
-
constructor(user_id, leave_for, leave_type, department, status, leave_start_date, leave_end_date, leave_duration, remaining_leave_balance, contact_number_during_leave, address_during_leave, notes, delegated_to, number_of_escort_instances_per_year, accompanying_the_patient, treatment_place, emergency_leaves_available, unpaid_leave_type, country_or_state_being_visited, leave_balance_summary, representation, activity_title, relationship, mounring_leave_relation
|
|
28
|
+
constructor(user_id, leave_for, leave_type, department, status, leave_start_date, leave_end_date, leave_duration, remaining_leave_balance, contact_number_during_leave, address_during_leave, notes, delegated_to, number_of_escort_instances_per_year, accompanying_the_patient, treatment_place, emergency_leaves_available, unpaid_leave_type, country_or_state_being_visited, leave_balance_summary, representation, activity_title, relationship, mounring_leave_relation) {
|
|
29
29
|
super();
|
|
30
30
|
this.user_id = user_id;
|
|
31
31
|
this.leave_for = leave_for;
|
|
@@ -51,9 +51,6 @@ let LeaveRequests = class LeaveRequests extends BaseModel_1.BaseModel {
|
|
|
51
51
|
this.activity_title = activity_title;
|
|
52
52
|
this.relationship = relationship;
|
|
53
53
|
this.mounring_leave_relation = mounring_leave_relation;
|
|
54
|
-
this.service_id = service_id;
|
|
55
|
-
this.sub_service_id = sub_service_id;
|
|
56
|
-
this.workflow_execution_id = workflow_execution_id;
|
|
57
54
|
}
|
|
58
55
|
};
|
|
59
56
|
exports.LeaveRequests = LeaveRequests;
|
|
@@ -153,19 +150,7 @@ __decorate([
|
|
|
153
150
|
(0, typeorm_1.Column)({ type: 'int', nullable: true }),
|
|
154
151
|
__metadata("design:type", Number)
|
|
155
152
|
], LeaveRequests.prototype, "mounring_leave_relation", void 0);
|
|
156
|
-
__decorate([
|
|
157
|
-
(0, typeorm_1.Column)({ type: 'int', nullable: true }),
|
|
158
|
-
__metadata("design:type", Object)
|
|
159
|
-
], LeaveRequests.prototype, "service_id", void 0);
|
|
160
|
-
__decorate([
|
|
161
|
-
(0, typeorm_1.Column)({ type: 'int', nullable: true }),
|
|
162
|
-
__metadata("design:type", Object)
|
|
163
|
-
], LeaveRequests.prototype, "sub_service_id", void 0);
|
|
164
|
-
__decorate([
|
|
165
|
-
(0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
|
|
166
|
-
__metadata("design:type", Object)
|
|
167
|
-
], LeaveRequests.prototype, "workflow_execution_id", void 0);
|
|
168
153
|
exports.LeaveRequests = LeaveRequests = __decorate([
|
|
169
154
|
(0, typeorm_1.Entity)({ name: 'leave_requests' }),
|
|
170
|
-
__metadata("design:paramtypes", [String, String, Number, String, String, Date, Date, Number, Number, String, String, String, String, Number, Boolean, String, Number, String, String, String, String, String, String, Number
|
|
155
|
+
__metadata("design:paramtypes", [String, String, Number, String, String, Date, Date, Number, Number, String, String, String, String, Number, Boolean, String, Number, String, String, String, String, String, String, Number])
|
|
171
156
|
], LeaveRequests);
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.ImportantLinks = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
const BaseModel_1 = require("./BaseModel");
|
|
15
|
+
let ImportantLinks = class ImportantLinks extends BaseModel_1.BaseModel {
|
|
16
|
+
constructor(title, url) {
|
|
17
|
+
super();
|
|
18
|
+
this.title = title;
|
|
19
|
+
this.url = url;
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
exports.ImportantLinks = ImportantLinks;
|
|
23
|
+
__decorate([
|
|
24
|
+
(0, typeorm_1.Column)({ type: 'varchar', nullable: false }),
|
|
25
|
+
__metadata("design:type", String)
|
|
26
|
+
], ImportantLinks.prototype, "title", void 0);
|
|
27
|
+
__decorate([
|
|
28
|
+
(0, typeorm_1.Column)({ type: 'varchar', nullable: false }),
|
|
29
|
+
__metadata("design:type", String)
|
|
30
|
+
], ImportantLinks.prototype, "url", void 0);
|
|
31
|
+
exports.ImportantLinks = ImportantLinks = __decorate([
|
|
32
|
+
(0, typeorm_1.Entity)({ name: 'important_links' }),
|
|
33
|
+
__metadata("design:paramtypes", [String, String])
|
|
34
|
+
], ImportantLinks);
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.QuestionTags = void 0;
|
|
13
|
+
const typeorm_1 = require("typeorm");
|
|
14
|
+
const BaseModel_1 = require("./BaseModel");
|
|
15
|
+
let QuestionTags = class QuestionTags extends BaseModel_1.BaseModel {
|
|
16
|
+
constructor(name, question_Id) {
|
|
17
|
+
super();
|
|
18
|
+
this.name = name,
|
|
19
|
+
this.question_Id = question_Id;
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
exports.QuestionTags = QuestionTags;
|
|
23
|
+
__decorate([
|
|
24
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
25
|
+
__metadata("design:type", String)
|
|
26
|
+
], QuestionTags.prototype, "name", void 0);
|
|
27
|
+
__decorate([
|
|
28
|
+
(0, typeorm_1.Column)({ nullable: true }),
|
|
29
|
+
__metadata("design:type", Number)
|
|
30
|
+
], QuestionTags.prototype, "question_Id", void 0);
|
|
31
|
+
exports.QuestionTags = QuestionTags = __decorate([
|
|
32
|
+
(0, typeorm_1.Entity)({ name: 'question_tags' }),
|
|
33
|
+
__metadata("design:paramtypes", [String, Number])
|
|
34
|
+
], QuestionTags);
|
package/package.json
CHANGED
package/src/data-source.ts
CHANGED
|
@@ -74,6 +74,7 @@ import { WorkflowTask } from './models/WorkflowTask';
|
|
|
74
74
|
import { WorkflowTaskNames } from './models/WorkflowTaskNames';
|
|
75
75
|
import { WorkflowDefinitions } from './models/WorkflowDefinitions';
|
|
76
76
|
import { WorkflowHierarchy } from './models/WorkflowHierarchy';
|
|
77
|
+
import { ImportantLinks } from './models/importantLinksModel';
|
|
77
78
|
|
|
78
79
|
|
|
79
80
|
|
|
@@ -152,5 +153,6 @@ export const AppDataSource = new DataSource({
|
|
|
152
153
|
WorkflowTaskNames,
|
|
153
154
|
WorkflowDefinitions,
|
|
154
155
|
WorkflowHierarchy,
|
|
156
|
+
ImportantLinks,
|
|
155
157
|
],
|
|
156
158
|
});
|
package/src/index.ts
CHANGED
|
@@ -20,28 +20,20 @@ export class LeaveApprovalDetails extends BaseModel {
|
|
|
20
20
|
@Column({ type: 'int', nullable: true })
|
|
21
21
|
approver_user_id: number;
|
|
22
22
|
|
|
23
|
-
@Column({ type: 'int', nullable:
|
|
23
|
+
@Column({ type: 'int', nullable: false })
|
|
24
24
|
approver_role_id: number;
|
|
25
25
|
|
|
26
|
-
@Column({ type: 'int', nullable: true })
|
|
27
|
-
department_id: number;
|
|
28
|
-
|
|
29
|
-
@Column({ type: 'int', nullable: true })
|
|
30
|
-
section_id: number;
|
|
31
|
-
|
|
32
26
|
@Column({ type: 'varchar', length: 255, nullable: false })
|
|
33
27
|
comment: string;
|
|
34
28
|
|
|
35
29
|
@Column({ type: 'enum', enum: ApprovalStatus,default: ApprovalStatus.PENDING, nullable: false })
|
|
36
30
|
approval_status: ApprovalStatus;
|
|
37
31
|
|
|
38
|
-
constructor(leave_request_id: number, approver_user_id: number, approver_role_id: number, comment: string, approval_status: ApprovalStatus, level: number
|
|
32
|
+
constructor(leave_request_id: number, approver_user_id: number, approver_role_id: number, comment: string, approval_status: ApprovalStatus, level: number) {
|
|
39
33
|
super();
|
|
40
34
|
this.leave_request_id = leave_request_id;
|
|
41
35
|
this.approver_user_id = approver_user_id;
|
|
42
36
|
this.approver_role_id = approver_role_id;
|
|
43
|
-
this.department_id = department_id;
|
|
44
|
-
this.section_id = section_id;
|
|
45
37
|
this.comment = comment;
|
|
46
38
|
this.approval_status = approval_status;
|
|
47
39
|
this.level = level;
|
|
@@ -85,17 +85,8 @@ export class LeaveRequests extends BaseModel {
|
|
|
85
85
|
@Column({ type: 'int', nullable: true })
|
|
86
86
|
mounring_leave_relation: number;
|
|
87
87
|
|
|
88
|
-
@Column({ type: 'int', nullable: true })
|
|
89
|
-
service_id: number | null;
|
|
90
|
-
|
|
91
|
-
@Column({ type: 'int', nullable: true })
|
|
92
|
-
sub_service_id: number | null;
|
|
93
|
-
|
|
94
|
-
@Column({ type: 'varchar', length: 255, nullable: true })
|
|
95
|
-
workflow_execution_id: string | null;
|
|
96
|
-
|
|
97
88
|
|
|
98
|
-
constructor(user_id: string, leave_for: Leave_For, leave_type: number, department: string, status: status, leave_start_date: Date, leave_end_date: Date, leave_duration: number, remaining_leave_balance: number, contact_number_during_leave: string, address_during_leave: string, notes: string, delegated_to: string, number_of_escort_instances_per_year: number, accompanying_the_patient: boolean, treatment_place: string, emergency_leaves_available: number, unpaid_leave_type: string, country_or_state_being_visited: string, leave_balance_summary: string, representation: string, activity_title: string, relationship: string, mounring_leave_relation: number
|
|
89
|
+
constructor(user_id: string, leave_for: Leave_For, leave_type: number, department: string, status: status, leave_start_date: Date, leave_end_date: Date, leave_duration: number, remaining_leave_balance: number, contact_number_during_leave: string, address_during_leave: string, notes: string, delegated_to: string, number_of_escort_instances_per_year: number, accompanying_the_patient: boolean, treatment_place: string, emergency_leaves_available: number, unpaid_leave_type: string, country_or_state_being_visited: string, leave_balance_summary: string, representation: string, activity_title: string, relationship: string, mounring_leave_relation: number) {
|
|
99
90
|
super();
|
|
100
91
|
this.user_id = user_id;
|
|
101
92
|
this.leave_for = leave_for;
|
|
@@ -121,8 +112,5 @@ export class LeaveRequests extends BaseModel {
|
|
|
121
112
|
this.activity_title = activity_title;
|
|
122
113
|
this.relationship = relationship;
|
|
123
114
|
this.mounring_leave_relation = mounring_leave_relation;
|
|
124
|
-
this.service_id = service_id;
|
|
125
|
-
this.sub_service_id = sub_service_id;
|
|
126
|
-
this.workflow_execution_id = workflow_execution_id;
|
|
127
115
|
}
|
|
128
116
|
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { Column, Entity } from "typeorm";
|
|
2
|
+
import { BaseModel } from './BaseModel';
|
|
3
|
+
|
|
4
|
+
@Entity({ name: 'important_links' })
|
|
5
|
+
export class ImportantLinks extends BaseModel {
|
|
6
|
+
|
|
7
|
+
@Column({ type: 'varchar', nullable: false })
|
|
8
|
+
title: string;
|
|
9
|
+
|
|
10
|
+
@Column({ type: 'varchar', nullable: false })
|
|
11
|
+
url: string;
|
|
12
|
+
|
|
13
|
+
constructor(
|
|
14
|
+
title: string,
|
|
15
|
+
url: string
|
|
16
|
+
) {
|
|
17
|
+
super();
|
|
18
|
+
this.title = title;
|
|
19
|
+
this.url = url;
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
|
|
@@ -1,13 +0,0 @@
|
|
|
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
|
-
}
|
|
@@ -1,51 +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.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);
|
|
@@ -1,40 +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.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);
|