@platform-modules/foreign-ministry 1.3.117 → 1.3.118

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.
@@ -113,6 +113,8 @@ const LMSCourseExternalLecturerApprovalModel_1 = require("./models/LMSCourseExte
113
113
  const LMSCourseExternalLecturerAttachmentModel_1 = require("./models/LMSCourseExternalLecturerAttachmentModel");
114
114
  const LMSCourseExternalLecturerChatModel_1 = require("./models/LMSCourseExternalLecturerChatModel");
115
115
  const LMSCourseExternalLecturerWorkflowModel_1 = require("./models/LMSCourseExternalLecturerWorkflowModel");
116
+ const LMSCourseExternalLecturerCostModel_1 = require("./models/LMSCourseExternalLecturerCostModel");
117
+ const LMSCourseExternalLecturerLecturerModel_1 = require("./models/LMSCourseExternalLecturerLecturerModel");
116
118
  const LMSExternalEntityTrainedRequestModel_1 = require("./models/LMSExternalEntityTrainedRequestModel");
117
119
  const LMSExternalEntityTrainedApprovalModel_1 = require("./models/LMSExternalEntityTrainedApprovalModel");
118
120
  const LMSExternalEntityTrainedAttachmentModel_1 = require("./models/LMSExternalEntityTrainedAttachmentModel");
@@ -166,7 +168,7 @@ exports.AppDataSource = new typeorm_1.DataSource({
166
168
  username: process.env.DB_USER || 'postgres',
167
169
  password: process.env.DB_PASS || 'postgres',
168
170
  database: process.env.DB_NAME || 'common_models',
169
- synchronize: false, // auto-create tables (disable in prod)
171
+ synchronize: true, // auto-create tables (disable in prod)
170
172
  logging: false,
171
173
  entities: [
172
174
  user_1.User,
@@ -277,6 +279,8 @@ exports.AppDataSource = new typeorm_1.DataSource({
277
279
  LMSCourseExternalLecturerAttachmentModel_1.LMSCourseExternalLecturerRequestAttachment,
278
280
  LMSCourseExternalLecturerChatModel_1.LMSCourseExternalLecturerRequestChat,
279
281
  LMSCourseExternalLecturerWorkflowModel_1.LMSCourseExternalLecturerWorkFlow,
282
+ LMSCourseExternalLecturerCostModel_1.LMSCourseExternalLecturerCost,
283
+ LMSCourseExternalLecturerLecturerModel_1.LMSCourseExternalLecturerLecturer,
280
284
  LMSExternalEntityTrainedRequestModel_1.LMSExternalEntityTrainedRequests,
281
285
  LMSExternalEntityTrainedApprovalModel_1.LMSExternalEntityTrainedApprovalDetails,
282
286
  LMSExternalEntityTrainedAttachmentModel_1.LMSExternalEntityTrainedRequestAttachment,
package/dist/index.d.ts CHANGED
@@ -115,6 +115,8 @@ export * from './models/LMSCourseExternalLecturerApprovalModel';
115
115
  export * from './models/LMSCourseExternalLecturerAttachmentModel';
116
116
  export * from './models/LMSCourseExternalLecturerChatModel';
117
117
  export * from './models/LMSCourseExternalLecturerWorkflowModel';
118
+ export * from './models/LMSCourseExternalLecturerCostModel';
119
+ export * from './models/LMSCourseExternalLecturerLecturerModel';
118
120
  export * from './models/LMSExternalEntityTrainedRequestModel';
119
121
  export * from './models/LMSExternalEntityTrainedApprovalModel';
120
122
  export * from './models/LMSExternalEntityTrainedAttachmentModel';
package/dist/index.js CHANGED
@@ -133,6 +133,8 @@ __exportStar(require("./models/LMSCourseExternalLecturerApprovalModel"), exports
133
133
  __exportStar(require("./models/LMSCourseExternalLecturerAttachmentModel"), exports);
134
134
  __exportStar(require("./models/LMSCourseExternalLecturerChatModel"), exports);
135
135
  __exportStar(require("./models/LMSCourseExternalLecturerWorkflowModel"), exports);
136
+ __exportStar(require("./models/LMSCourseExternalLecturerCostModel"), exports);
137
+ __exportStar(require("./models/LMSCourseExternalLecturerLecturerModel"), exports);
136
138
  __exportStar(require("./models/LMSExternalEntityTrainedRequestModel"), exports);
137
139
  __exportStar(require("./models/LMSExternalEntityTrainedApprovalModel"), exports);
138
140
  __exportStar(require("./models/LMSExternalEntityTrainedAttachmentModel"), exports);
@@ -0,0 +1,13 @@
1
+ import { BaseModel } from './BaseModel';
2
+ export declare class LMSCourseExternalLecturerCost extends BaseModel {
3
+ request_id: number;
4
+ service_id: number | null;
5
+ sub_service_id: number | null;
6
+ material_price: number | null;
7
+ transportation: number | null;
8
+ accommodation: number | null;
9
+ allowances: number | null;
10
+ food: number | null;
11
+ present: number | null;
12
+ total_cost: number | null;
13
+ }
@@ -0,0 +1,60 @@
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.LMSCourseExternalLecturerCost = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ let LMSCourseExternalLecturerCost = class LMSCourseExternalLecturerCost extends BaseModel_1.BaseModel {
16
+ };
17
+ exports.LMSCourseExternalLecturerCost = LMSCourseExternalLecturerCost;
18
+ __decorate([
19
+ (0, typeorm_1.Column)({ type: 'integer', nullable: false }),
20
+ __metadata("design:type", Number)
21
+ ], LMSCourseExternalLecturerCost.prototype, "request_id", void 0);
22
+ __decorate([
23
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
24
+ __metadata("design:type", Object)
25
+ ], LMSCourseExternalLecturerCost.prototype, "service_id", void 0);
26
+ __decorate([
27
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
28
+ __metadata("design:type", Object)
29
+ ], LMSCourseExternalLecturerCost.prototype, "sub_service_id", void 0);
30
+ __decorate([
31
+ (0, typeorm_1.Column)({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 }),
32
+ __metadata("design:type", Object)
33
+ ], LMSCourseExternalLecturerCost.prototype, "material_price", void 0);
34
+ __decorate([
35
+ (0, typeorm_1.Column)({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 }),
36
+ __metadata("design:type", Object)
37
+ ], LMSCourseExternalLecturerCost.prototype, "transportation", void 0);
38
+ __decorate([
39
+ (0, typeorm_1.Column)({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 }),
40
+ __metadata("design:type", Object)
41
+ ], LMSCourseExternalLecturerCost.prototype, "accommodation", void 0);
42
+ __decorate([
43
+ (0, typeorm_1.Column)({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 }),
44
+ __metadata("design:type", Object)
45
+ ], LMSCourseExternalLecturerCost.prototype, "allowances", void 0);
46
+ __decorate([
47
+ (0, typeorm_1.Column)({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 }),
48
+ __metadata("design:type", Object)
49
+ ], LMSCourseExternalLecturerCost.prototype, "food", void 0);
50
+ __decorate([
51
+ (0, typeorm_1.Column)({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 }),
52
+ __metadata("design:type", Object)
53
+ ], LMSCourseExternalLecturerCost.prototype, "present", void 0);
54
+ __decorate([
55
+ (0, typeorm_1.Column)({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 }),
56
+ __metadata("design:type", Object)
57
+ ], LMSCourseExternalLecturerCost.prototype, "total_cost", void 0);
58
+ exports.LMSCourseExternalLecturerCost = LMSCourseExternalLecturerCost = __decorate([
59
+ (0, typeorm_1.Entity)({ name: 'lms_course_external_lecturer_costs' })
60
+ ], LMSCourseExternalLecturerCost);
@@ -0,0 +1,15 @@
1
+ import { BaseModel } from './BaseModel';
2
+ export declare class LMSCourseExternalLecturerLecturer extends BaseModel {
3
+ request_id: number;
4
+ service_id: number | null;
5
+ sub_service_id: number | null;
6
+ full_name: string;
7
+ passport_or_id: string;
8
+ age: number;
9
+ qualifications: string;
10
+ experience: string;
11
+ cv_file_url: string | null;
12
+ cv_file_name: string | null;
13
+ cv_file_type: string | null;
14
+ cv_file_size: number | null;
15
+ }
@@ -0,0 +1,68 @@
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.LMSCourseExternalLecturerLecturer = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ let LMSCourseExternalLecturerLecturer = class LMSCourseExternalLecturerLecturer extends BaseModel_1.BaseModel {
16
+ };
17
+ exports.LMSCourseExternalLecturerLecturer = LMSCourseExternalLecturerLecturer;
18
+ __decorate([
19
+ (0, typeorm_1.Column)({ type: 'integer', nullable: false }),
20
+ __metadata("design:type", Number)
21
+ ], LMSCourseExternalLecturerLecturer.prototype, "request_id", void 0);
22
+ __decorate([
23
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
24
+ __metadata("design:type", Object)
25
+ ], LMSCourseExternalLecturerLecturer.prototype, "service_id", void 0);
26
+ __decorate([
27
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
28
+ __metadata("design:type", Object)
29
+ ], LMSCourseExternalLecturerLecturer.prototype, "sub_service_id", void 0);
30
+ __decorate([
31
+ (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: false }),
32
+ __metadata("design:type", String)
33
+ ], LMSCourseExternalLecturerLecturer.prototype, "full_name", void 0);
34
+ __decorate([
35
+ (0, typeorm_1.Column)({ type: 'varchar', length: 100, nullable: false }),
36
+ __metadata("design:type", String)
37
+ ], LMSCourseExternalLecturerLecturer.prototype, "passport_or_id", void 0);
38
+ __decorate([
39
+ (0, typeorm_1.Column)({ type: 'integer', nullable: false }),
40
+ __metadata("design:type", Number)
41
+ ], LMSCourseExternalLecturerLecturer.prototype, "age", void 0);
42
+ __decorate([
43
+ (0, typeorm_1.Column)({ type: 'text', nullable: false }),
44
+ __metadata("design:type", String)
45
+ ], LMSCourseExternalLecturerLecturer.prototype, "qualifications", void 0);
46
+ __decorate([
47
+ (0, typeorm_1.Column)({ type: 'text', nullable: false }),
48
+ __metadata("design:type", String)
49
+ ], LMSCourseExternalLecturerLecturer.prototype, "experience", void 0);
50
+ __decorate([
51
+ (0, typeorm_1.Column)({ type: 'varchar', length: 500, nullable: true }),
52
+ __metadata("design:type", Object)
53
+ ], LMSCourseExternalLecturerLecturer.prototype, "cv_file_url", void 0);
54
+ __decorate([
55
+ (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
56
+ __metadata("design:type", Object)
57
+ ], LMSCourseExternalLecturerLecturer.prototype, "cv_file_name", void 0);
58
+ __decorate([
59
+ (0, typeorm_1.Column)({ type: 'varchar', length: 100, nullable: true }),
60
+ __metadata("design:type", Object)
61
+ ], LMSCourseExternalLecturerLecturer.prototype, "cv_file_type", void 0);
62
+ __decorate([
63
+ (0, typeorm_1.Column)({ type: 'bigint', nullable: true }),
64
+ __metadata("design:type", Object)
65
+ ], LMSCourseExternalLecturerLecturer.prototype, "cv_file_size", void 0);
66
+ exports.LMSCourseExternalLecturerLecturer = LMSCourseExternalLecturerLecturer = __decorate([
67
+ (0, typeorm_1.Entity)({ name: 'lms_course_external_lecturer_lecturers' })
68
+ ], LMSCourseExternalLecturerLecturer);
@@ -12,28 +12,15 @@ export declare class LMSCourseExternalLecturerRequests extends BaseModel {
12
12
  service_id: number | null;
13
13
  sub_service_id: number | null;
14
14
  user_id: number;
15
- course_name: string | null;
16
- course_level: string | null;
17
- material_price: string | null;
18
- transportation: string | null;
19
- accommodation: string | null;
20
- allowances: string | null;
21
- food: string | null;
22
- present: string | null;
23
- currency_type: string | null;
24
- reason_of_course: string | null;
25
- estimated_number_of_participants: number | null;
26
- date_from: Date | null;
27
- date_to: Date | null;
28
- time_from: string | null;
29
- time_to: string | null;
30
- lecturer_full_name: string | null;
31
- passport: string | null;
32
- age: number | null;
33
- qualifications: string | null;
34
- experience: string | null;
35
- cv_attachment: string | null;
36
- course_material: string | null;
15
+ course_name: string;
16
+ course_level: string;
17
+ institution: string;
18
+ reason_of_course: string;
19
+ estimated_number_of_participants: number;
20
+ date_from: Date;
21
+ date_to: Date;
22
+ time_from: string;
23
+ time_to: string;
37
24
  status: LMSCourseExternalLecturerStatus;
38
25
  workflow_execution_id: string | null;
39
26
  }
@@ -44,93 +44,41 @@ __decorate([
44
44
  __metadata("design:type", Number)
45
45
  ], LMSCourseExternalLecturerRequests.prototype, "user_id", void 0);
46
46
  __decorate([
47
- (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
48
- __metadata("design:type", Object)
47
+ (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: false }),
48
+ __metadata("design:type", String)
49
49
  ], LMSCourseExternalLecturerRequests.prototype, "course_name", void 0);
50
50
  __decorate([
51
- (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
52
- __metadata("design:type", Object)
51
+ (0, typeorm_1.Column)({ type: 'varchar', length: 100, nullable: false }),
52
+ __metadata("design:type", String)
53
53
  ], LMSCourseExternalLecturerRequests.prototype, "course_level", void 0);
54
54
  __decorate([
55
- (0, typeorm_1.Column)({ type: 'varchar', nullable: true }),
56
- __metadata("design:type", Object)
57
- ], LMSCourseExternalLecturerRequests.prototype, "material_price", void 0);
58
- __decorate([
59
- (0, typeorm_1.Column)({ type: 'varchar', nullable: true }),
60
- __metadata("design:type", Object)
61
- ], LMSCourseExternalLecturerRequests.prototype, "transportation", void 0);
62
- __decorate([
63
- (0, typeorm_1.Column)({ type: 'varchar', nullable: true }),
64
- __metadata("design:type", Object)
65
- ], LMSCourseExternalLecturerRequests.prototype, "accommodation", void 0);
66
- __decorate([
67
- (0, typeorm_1.Column)({ type: 'varchar', nullable: true }),
68
- __metadata("design:type", Object)
69
- ], LMSCourseExternalLecturerRequests.prototype, "allowances", void 0);
70
- __decorate([
71
- (0, typeorm_1.Column)({ type: 'varchar', nullable: true }),
72
- __metadata("design:type", Object)
73
- ], LMSCourseExternalLecturerRequests.prototype, "food", void 0);
74
- __decorate([
75
- (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
76
- __metadata("design:type", Object)
77
- ], LMSCourseExternalLecturerRequests.prototype, "present", void 0);
78
- __decorate([
79
- (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
80
- __metadata("design:type", Object)
81
- ], LMSCourseExternalLecturerRequests.prototype, "currency_type", void 0);
55
+ (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: false }),
56
+ __metadata("design:type", String)
57
+ ], LMSCourseExternalLecturerRequests.prototype, "institution", void 0);
82
58
  __decorate([
83
- (0, typeorm_1.Column)({ type: 'text', nullable: true }),
84
- __metadata("design:type", Object)
59
+ (0, typeorm_1.Column)({ type: 'text', nullable: false }),
60
+ __metadata("design:type", String)
85
61
  ], LMSCourseExternalLecturerRequests.prototype, "reason_of_course", void 0);
86
62
  __decorate([
87
- (0, typeorm_1.Column)({ type: 'int', nullable: true }),
88
- __metadata("design:type", Object)
63
+ (0, typeorm_1.Column)({ type: 'int', nullable: false }),
64
+ __metadata("design:type", Number)
89
65
  ], LMSCourseExternalLecturerRequests.prototype, "estimated_number_of_participants", void 0);
90
66
  __decorate([
91
- (0, typeorm_1.Column)({ type: 'date', nullable: true }),
92
- __metadata("design:type", Object)
67
+ (0, typeorm_1.Column)({ type: 'date', nullable: false }),
68
+ __metadata("design:type", Date)
93
69
  ], LMSCourseExternalLecturerRequests.prototype, "date_from", void 0);
94
70
  __decorate([
95
- (0, typeorm_1.Column)({ type: 'date', nullable: true }),
96
- __metadata("design:type", Object)
71
+ (0, typeorm_1.Column)({ type: 'date', nullable: false }),
72
+ __metadata("design:type", Date)
97
73
  ], LMSCourseExternalLecturerRequests.prototype, "date_to", void 0);
98
74
  __decorate([
99
- (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
100
- __metadata("design:type", Object)
75
+ (0, typeorm_1.Column)({ type: 'time', nullable: false }),
76
+ __metadata("design:type", String)
101
77
  ], LMSCourseExternalLecturerRequests.prototype, "time_from", void 0);
102
78
  __decorate([
103
- (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
104
- __metadata("design:type", Object)
79
+ (0, typeorm_1.Column)({ type: 'time', nullable: false }),
80
+ __metadata("design:type", String)
105
81
  ], LMSCourseExternalLecturerRequests.prototype, "time_to", void 0);
106
- __decorate([
107
- (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
108
- __metadata("design:type", Object)
109
- ], LMSCourseExternalLecturerRequests.prototype, "lecturer_full_name", void 0);
110
- __decorate([
111
- (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
112
- __metadata("design:type", Object)
113
- ], LMSCourseExternalLecturerRequests.prototype, "passport", void 0);
114
- __decorate([
115
- (0, typeorm_1.Column)({ type: 'int', nullable: true }),
116
- __metadata("design:type", Object)
117
- ], LMSCourseExternalLecturerRequests.prototype, "age", void 0);
118
- __decorate([
119
- (0, typeorm_1.Column)({ type: 'text', nullable: true }),
120
- __metadata("design:type", Object)
121
- ], LMSCourseExternalLecturerRequests.prototype, "qualifications", void 0);
122
- __decorate([
123
- (0, typeorm_1.Column)({ type: 'text', nullable: true }),
124
- __metadata("design:type", Object)
125
- ], LMSCourseExternalLecturerRequests.prototype, "experience", void 0);
126
- __decorate([
127
- (0, typeorm_1.Column)({ type: 'varchar', length: 500, nullable: true }),
128
- __metadata("design:type", Object)
129
- ], LMSCourseExternalLecturerRequests.prototype, "cv_attachment", void 0);
130
- __decorate([
131
- (0, typeorm_1.Column)({ type: 'varchar', length: 500, nullable: true }),
132
- __metadata("design:type", Object)
133
- ], LMSCourseExternalLecturerRequests.prototype, "course_material", void 0);
134
82
  __decorate([
135
83
  (0, typeorm_1.Column)({ type: 'enum', enum: LMSCourseExternalLecturerStatus, default: LMSCourseExternalLecturerStatus.PENDING, nullable: false }),
136
84
  __metadata("design:type", String)
@@ -1,7 +1,23 @@
1
1
  import { BaseModel } from './BaseModel';
2
+ export declare enum LMSExternalCourseParticipationCandidateApprovalStatus {
3
+ PENDING = "Pending",
4
+ IN_PROGRESS = "In Progress",
5
+ APPROVED = "Approved",
6
+ REJECTED = "Rejected"
7
+ }
2
8
  export declare class LMSExternalCourseParticipationCandidate extends BaseModel {
3
9
  request_id: number;
4
10
  candidate_id: number;
5
11
  candidate_name: string | null;
6
12
  candidate_profile_url: string | null;
13
+ service_id: number | null;
14
+ sub_service_id: number | null;
15
+ approver_role_id: number;
16
+ department_id: number | null;
17
+ section_id: number | null;
18
+ approver_user_id: number | null;
19
+ delegate_user_id: number | null;
20
+ approved_by: number | null;
21
+ comment: string;
22
+ approval_status: LMSExternalCourseParticipationCandidateApprovalStatus;
7
23
  }
@@ -9,9 +9,16 @@ var __metadata = (this && this.__metadata) || function (k, v) {
9
9
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.LMSExternalCourseParticipationCandidate = void 0;
12
+ exports.LMSExternalCourseParticipationCandidate = exports.LMSExternalCourseParticipationCandidateApprovalStatus = void 0;
13
13
  const typeorm_1 = require("typeorm");
14
14
  const BaseModel_1 = require("./BaseModel");
15
+ var LMSExternalCourseParticipationCandidateApprovalStatus;
16
+ (function (LMSExternalCourseParticipationCandidateApprovalStatus) {
17
+ LMSExternalCourseParticipationCandidateApprovalStatus["PENDING"] = "Pending";
18
+ LMSExternalCourseParticipationCandidateApprovalStatus["IN_PROGRESS"] = "In Progress";
19
+ LMSExternalCourseParticipationCandidateApprovalStatus["APPROVED"] = "Approved";
20
+ LMSExternalCourseParticipationCandidateApprovalStatus["REJECTED"] = "Rejected";
21
+ })(LMSExternalCourseParticipationCandidateApprovalStatus || (exports.LMSExternalCourseParticipationCandidateApprovalStatus = LMSExternalCourseParticipationCandidateApprovalStatus = {}));
15
22
  let LMSExternalCourseParticipationCandidate = class LMSExternalCourseParticipationCandidate extends BaseModel_1.BaseModel {
16
23
  };
17
24
  exports.LMSExternalCourseParticipationCandidate = LMSExternalCourseParticipationCandidate;
@@ -31,6 +38,46 @@ __decorate([
31
38
  (0, typeorm_1.Column)({ type: 'varchar', length: 500, nullable: true }),
32
39
  __metadata("design:type", Object)
33
40
  ], LMSExternalCourseParticipationCandidate.prototype, "candidate_profile_url", void 0);
41
+ __decorate([
42
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
43
+ __metadata("design:type", Object)
44
+ ], LMSExternalCourseParticipationCandidate.prototype, "service_id", void 0);
45
+ __decorate([
46
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
47
+ __metadata("design:type", Object)
48
+ ], LMSExternalCourseParticipationCandidate.prototype, "sub_service_id", void 0);
49
+ __decorate([
50
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
51
+ __metadata("design:type", Number)
52
+ ], LMSExternalCourseParticipationCandidate.prototype, "approver_role_id", void 0);
53
+ __decorate([
54
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
55
+ __metadata("design:type", Object)
56
+ ], LMSExternalCourseParticipationCandidate.prototype, "department_id", void 0);
57
+ __decorate([
58
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
59
+ __metadata("design:type", Object)
60
+ ], LMSExternalCourseParticipationCandidate.prototype, "section_id", void 0);
61
+ __decorate([
62
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
63
+ __metadata("design:type", Object)
64
+ ], LMSExternalCourseParticipationCandidate.prototype, "approver_user_id", void 0);
65
+ __decorate([
66
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
67
+ __metadata("design:type", Object)
68
+ ], LMSExternalCourseParticipationCandidate.prototype, "delegate_user_id", void 0);
69
+ __decorate([
70
+ (0, typeorm_1.Column)({ type: 'integer', nullable: true }),
71
+ __metadata("design:type", Object)
72
+ ], LMSExternalCourseParticipationCandidate.prototype, "approved_by", void 0);
73
+ __decorate([
74
+ (0, typeorm_1.Column)({ type: 'varchar', length: 500, nullable: true, default: '' }),
75
+ __metadata("design:type", String)
76
+ ], LMSExternalCourseParticipationCandidate.prototype, "comment", void 0);
77
+ __decorate([
78
+ (0, typeorm_1.Column)({ type: 'enum', enum: LMSExternalCourseParticipationCandidateApprovalStatus, enumName: 'lms_external_course_participation_candidate_approval_status_enum', default: LMSExternalCourseParticipationCandidateApprovalStatus.PENDING, nullable: false }),
79
+ __metadata("design:type", String)
80
+ ], LMSExternalCourseParticipationCandidate.prototype, "approval_status", void 0);
34
81
  exports.LMSExternalCourseParticipationCandidate = LMSExternalCourseParticipationCandidate = __decorate([
35
82
  (0, typeorm_1.Entity)({ name: 'lms_external_course_participation_candidates' })
36
83
  ], LMSExternalCourseParticipationCandidate);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@platform-modules/foreign-ministry",
3
- "version": "1.3.117",
3
+ "version": "1.3.118",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "scripts": {
@@ -118,6 +118,8 @@ import { LMSCourseExternalLecturerApprovalDetails } from './models/LMSCourseExte
118
118
  import { LMSCourseExternalLecturerRequestAttachment } from './models/LMSCourseExternalLecturerAttachmentModel';
119
119
  import { LMSCourseExternalLecturerRequestChat } from './models/LMSCourseExternalLecturerChatModel';
120
120
  import { LMSCourseExternalLecturerWorkFlow } from './models/LMSCourseExternalLecturerWorkflowModel';
121
+ import { LMSCourseExternalLecturerCost } from './models/LMSCourseExternalLecturerCostModel';
122
+ import { LMSCourseExternalLecturerLecturer } from './models/LMSCourseExternalLecturerLecturerModel';
121
123
  import { LMSExternalEntityTrainedRequests } from './models/LMSExternalEntityTrainedRequestModel';
122
124
  import { LMSExternalEntityTrainedApprovalDetails } from './models/LMSExternalEntityTrainedApprovalModel';
123
125
  import { LMSExternalEntityTrainedRequestAttachment } from './models/LMSExternalEntityTrainedAttachmentModel';
@@ -174,7 +176,7 @@ export const AppDataSource = new DataSource({
174
176
  username: process.env.DB_USER || 'postgres',
175
177
  password: process.env.DB_PASS || 'postgres',
176
178
  database: process.env.DB_NAME || 'common_models',
177
- synchronize: false, // auto-create tables (disable in prod)
179
+ synchronize: true, // auto-create tables (disable in prod)
178
180
  logging: false,
179
181
  entities: [
180
182
  User,
@@ -285,6 +287,8 @@ export const AppDataSource = new DataSource({
285
287
  LMSCourseExternalLecturerRequestAttachment,
286
288
  LMSCourseExternalLecturerRequestChat,
287
289
  LMSCourseExternalLecturerWorkFlow,
290
+ LMSCourseExternalLecturerCost,
291
+ LMSCourseExternalLecturerLecturer,
288
292
  LMSExternalEntityTrainedRequests,
289
293
  LMSExternalEntityTrainedApprovalDetails,
290
294
  LMSExternalEntityTrainedRequestAttachment,
package/src/index.ts CHANGED
@@ -115,6 +115,8 @@ export * from './models/LMSCourseExternalLecturerApprovalModel';
115
115
  export * from './models/LMSCourseExternalLecturerAttachmentModel';
116
116
  export * from './models/LMSCourseExternalLecturerChatModel';
117
117
  export * from './models/LMSCourseExternalLecturerWorkflowModel';
118
+ export * from './models/LMSCourseExternalLecturerCostModel';
119
+ export * from './models/LMSCourseExternalLecturerLecturerModel';
118
120
  export * from './models/LMSExternalEntityTrainedRequestModel';
119
121
  export * from './models/LMSExternalEntityTrainedApprovalModel';
120
122
  export * from './models/LMSExternalEntityTrainedAttachmentModel';
@@ -0,0 +1,36 @@
1
+ import { Column, Entity } from "typeorm";
2
+ import { BaseModel } from './BaseModel';
3
+
4
+ @Entity({ name: 'lms_course_external_lecturer_costs' })
5
+ export class LMSCourseExternalLecturerCost extends BaseModel {
6
+
7
+ @Column({ type: 'integer', nullable: false })
8
+ request_id: number;
9
+
10
+ @Column({ type: 'integer', nullable: true })
11
+ service_id: number | null;
12
+
13
+ @Column({ type: 'integer', nullable: true })
14
+ sub_service_id: number | null;
15
+
16
+ @Column({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 })
17
+ material_price: number | null;
18
+
19
+ @Column({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 })
20
+ transportation: number | null;
21
+
22
+ @Column({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 })
23
+ accommodation: number | null;
24
+
25
+ @Column({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 })
26
+ allowances: number | null;
27
+
28
+ @Column({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 })
29
+ food: number | null;
30
+
31
+ @Column({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 })
32
+ present: number | null;
33
+
34
+ @Column({ type: 'decimal', precision: 10, scale: 2, nullable: true, default: 0 })
35
+ total_cost: number | null;
36
+ }
@@ -0,0 +1,42 @@
1
+ import { Column, Entity } from "typeorm";
2
+ import { BaseModel } from './BaseModel';
3
+
4
+ @Entity({ name: 'lms_course_external_lecturer_lecturers' })
5
+ export class LMSCourseExternalLecturerLecturer extends BaseModel {
6
+
7
+ @Column({ type: 'integer', nullable: false })
8
+ request_id: number;
9
+
10
+ @Column({ type: 'integer', nullable: true })
11
+ service_id: number | null;
12
+
13
+ @Column({ type: 'integer', nullable: true })
14
+ sub_service_id: number | null;
15
+
16
+ @Column({ type: 'varchar', length: 255, nullable: false })
17
+ full_name: string;
18
+
19
+ @Column({ type: 'varchar', length: 100, nullable: false })
20
+ passport_or_id: string;
21
+
22
+ @Column({ type: 'integer', nullable: false })
23
+ age: number;
24
+
25
+ @Column({ type: 'text', nullable: false })
26
+ qualifications: string;
27
+
28
+ @Column({ type: 'text', nullable: false })
29
+ experience: string;
30
+
31
+ @Column({ type: 'varchar', length: 500, nullable: true })
32
+ cv_file_url: string | null;
33
+
34
+ @Column({ type: 'varchar', length: 255, nullable: true })
35
+ cv_file_name: string | null;
36
+
37
+ @Column({ type: 'varchar', length: 100, nullable: true })
38
+ cv_file_type: string | null;
39
+
40
+ @Column({ type: 'bigint', nullable: true })
41
+ cv_file_size: number | null;
42
+ }
@@ -27,78 +27,36 @@ export class LMSCourseExternalLecturerRequests extends BaseModel {
27
27
  @Column({ type: 'int', nullable: false })
28
28
  user_id: number;
29
29
 
30
+ @Column({ type: 'varchar', length: 255, nullable: false })
31
+ course_name: string;
30
32
 
31
- // New columns
32
- @Column({ type: 'varchar', length: 255, nullable: true })
33
- course_name: string | null;
33
+ @Column({ type: 'varchar', length: 100, nullable: false })
34
+ course_level: string;
34
35
 
35
- @Column({ type: 'varchar', length: 255, nullable: true })
36
- course_level: string | null;
36
+ @Column({ type: 'varchar', length: 255, nullable: false })
37
+ institution: string;
37
38
 
38
- @Column({ type: 'varchar', nullable: true })
39
- material_price: string | null;
40
-
41
- @Column({ type: 'varchar', nullable: true })
42
- transportation: string | null;
43
-
44
- @Column({ type: 'varchar', nullable: true })
45
- accommodation: string | null;
46
-
47
- @Column({ type: 'varchar', nullable: true })
48
- allowances: string | null;
49
-
50
- @Column({ type: 'varchar', nullable: true })
51
- food: string | null;
52
-
53
- @Column({ type: 'varchar', length: 255, nullable: true })
54
- present: string | null;
55
-
56
- @Column({ type: 'varchar', length: 255, nullable: true })
57
- currency_type: string | null;
39
+ @Column({ type: 'text', nullable: false })
40
+ reason_of_course: string;
58
41
 
59
- @Column({ type: 'text', nullable: true })
60
- reason_of_course: string | null;
61
-
62
- @Column({ type: 'int', nullable: true })
63
- estimated_number_of_participants: number | null;
64
-
65
- @Column({ type: 'date', nullable: true })
66
- date_from: Date | null;
67
-
68
- @Column({ type: 'date', nullable: true })
69
- date_to: Date | null;
70
-
71
- @Column({ type: 'varchar', length: 255, nullable: true })
72
- time_from: string | null;
73
-
74
- @Column({ type: 'varchar', length: 255, nullable: true })
75
- time_to: string | null;
76
-
77
- @Column({ type: 'varchar', length: 255, nullable: true })
78
- lecturer_full_name: string | null;
79
-
80
- @Column({ type: 'varchar', length: 255, nullable: true })
81
- passport: string | null;
82
-
83
- @Column({ type: 'int', nullable: true })
84
- age: number | null;
42
+ @Column({ type: 'int', nullable: false })
43
+ estimated_number_of_participants: number;
85
44
 
86
- @Column({ type: 'text', nullable: true })
87
- qualifications: string | null;
45
+ @Column({ type: 'date', nullable: false })
46
+ date_from: Date;
88
47
 
89
- @Column({ type: 'text', nullable: true })
90
- experience: string | null;
48
+ @Column({ type: 'date', nullable: false })
49
+ date_to: Date;
91
50
 
92
- @Column({ type: 'varchar', length: 500, nullable: true })
93
- cv_attachment: string | null;
51
+ @Column({ type: 'time', nullable: false })
52
+ time_from: string;
94
53
 
95
- @Column({ type: 'varchar', length: 500, nullable: true })
96
- course_material: string | null;
54
+ @Column({ type: 'time', nullable: false })
55
+ time_to: string;
97
56
 
98
57
  @Column({ type: 'enum', enum: LMSCourseExternalLecturerStatus, default: LMSCourseExternalLecturerStatus.PENDING, nullable: false })
99
58
  status: LMSCourseExternalLecturerStatus;
100
59
 
101
60
  @Column({ type: 'varchar', nullable: true })
102
61
  workflow_execution_id: string | null;
103
-
104
62
  }
@@ -1,6 +1,13 @@
1
1
  import { Column, Entity } from "typeorm";
2
2
  import { BaseModel } from './BaseModel';
3
3
 
4
+ export enum LMSExternalCourseParticipationCandidateApprovalStatus {
5
+ PENDING = "Pending",
6
+ IN_PROGRESS = "In Progress",
7
+ APPROVED = "Approved",
8
+ REJECTED = "Rejected"
9
+ }
10
+
4
11
  @Entity({ name: 'lms_external_course_participation_candidates' })
5
12
  export class LMSExternalCourseParticipationCandidate extends BaseModel {
6
13
  @Column({ type: 'integer', nullable: false })
@@ -14,4 +21,34 @@ export class LMSExternalCourseParticipationCandidate extends BaseModel {
14
21
 
15
22
  @Column({ type: 'varchar', length: 500, nullable: true })
16
23
  candidate_profile_url: string | null;
24
+
25
+ @Column({ type: 'integer', nullable: true })
26
+ service_id: number | null;
27
+
28
+ @Column({ type: 'integer', nullable: true })
29
+ sub_service_id: number | null;
30
+
31
+ @Column({ type: 'integer', nullable: true })
32
+ approver_role_id: number;
33
+
34
+ @Column({ type: 'integer', nullable: true })
35
+ department_id: number | null;
36
+
37
+ @Column({ type: 'integer', nullable: true })
38
+ section_id: number | null;
39
+
40
+ @Column({ type: 'integer', nullable: true })
41
+ approver_user_id: number | null;
42
+
43
+ @Column({ type: 'integer', nullable: true })
44
+ delegate_user_id: number | null;
45
+
46
+ @Column({ type: 'integer', nullable: true })
47
+ approved_by: number | null;
48
+
49
+ @Column({ type: 'varchar', length: 500, nullable: true, default: '' })
50
+ comment: string;
51
+
52
+ @Column({ type: 'enum', enum: LMSExternalCourseParticipationCandidateApprovalStatus, enumName: 'lms_external_course_participation_candidate_approval_status_enum', default: LMSExternalCourseParticipationCandidateApprovalStatus.PENDING, nullable: false })
53
+ approval_status: LMSExternalCourseParticipationCandidateApprovalStatus;
17
54
  }