@platform-modules/civil-aviation-authority 2.3.12 → 2.3.13
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/dist/data-source.js +20 -0
- package/dist/index.d.ts +24 -0
- package/dist/index.js +41 -1
- package/dist/models/AnnualTrainingPlanApprovalModel.d.ts +25 -0
- package/dist/models/AnnualTrainingPlanApprovalModel.js +107 -0
- package/dist/models/AnnualTrainingPlanAttachmentModel.d.ts +13 -0
- package/dist/models/AnnualTrainingPlanAttachmentModel.js +69 -0
- package/dist/models/AnnualTrainingPlanChatModel.d.ts +26 -0
- package/dist/models/AnnualTrainingPlanChatModel.js +89 -0
- package/dist/models/AnnualTrainingPlanRequestModel.d.ts +36 -0
- package/dist/models/AnnualTrainingPlanRequestModel.js +151 -0
- package/dist/models/AnnualTrainingPlanWorkflowModel.d.ts +19 -0
- package/dist/models/AnnualTrainingPlanWorkflowModel.js +81 -0
- package/dist/models/TrainingRoomBookingApprovalModel.d.ts +25 -0
- package/dist/models/TrainingRoomBookingApprovalModel.js +107 -0
- package/dist/models/TrainingRoomBookingAttachmentModel.d.ts +13 -0
- package/dist/models/TrainingRoomBookingAttachmentModel.js +69 -0
- package/dist/models/TrainingRoomBookingChatModel.d.ts +26 -0
- package/dist/models/TrainingRoomBookingChatModel.js +89 -0
- package/dist/models/TrainingRoomBookingRequestModel.d.ts +38 -0
- package/dist/models/TrainingRoomBookingRequestModel.js +149 -0
- package/dist/models/TrainingRoomBookingWorkflowModel.d.ts +19 -0
- package/dist/models/TrainingRoomBookingWorkflowModel.js +81 -0
- package/package.json +1 -1
- package/src/data-source.ts +225 -205
- package/src/index.ts +24 -0
- package/src/models/AnnualTrainingPlanApprovalModel.ts +94 -0
- package/src/models/AnnualTrainingPlanAttachmentModel.ts +56 -0
- package/src/models/AnnualTrainingPlanChatModel.ts +76 -0
- package/src/models/AnnualTrainingPlanRequestModel.ts +138 -0
- package/src/models/AnnualTrainingPlanWorkflowModel.ts +68 -0
- package/src/models/HrServiceRequestModel.ts +167 -167
- package/src/models/ITRequestChatModel.ts +62 -62
- package/src/models/ItApprovalsModel.ts +84 -84
- package/src/models/ItWorkflowModel.ts +55 -55
- package/src/models/TrainingRoomBookingApprovalModel.ts +94 -0
- package/src/models/TrainingRoomBookingAttachmentModel.ts +56 -0
- package/src/models/TrainingRoomBookingChatModel.ts +76 -0
- package/src/models/TrainingRoomBookingRequestModel.ts +136 -0
- package/src/models/TrainingRoomBookingWorkflowModel.ts +68 -0
- package/dist/models/ITApprovalSettings.d.ts +0 -7
- package/dist/models/ITApprovalSettings.js +0 -40
- package/dist/models/ITServicesTypesMuscatModel.d.ts +0 -6
- package/dist/models/ITServicesTypesMuscatModel.js +0 -34
- package/dist/models/ITServicesTypesSalalahModel.d.ts +0 -6
- package/dist/models/ITServicesTypesSalalahModel.js +0 -34
- package/dist/models/Workflows.d.ts +0 -9
- package/dist/models/Workflows.js +0 -31
package/src/data-source.ts
CHANGED
|
@@ -1,205 +1,225 @@
|
|
|
1
|
-
// src/data-source.ts
|
|
2
|
-
import 'reflect-metadata';
|
|
3
|
-
import { DataSource } from 'typeorm';
|
|
4
|
-
import 'dotenv/config';
|
|
5
|
-
import { User } from './models/user'; // import all entities here
|
|
6
|
-
import { userSessions } from './models/user-sessions';
|
|
7
|
-
import { Role } from './models/role';
|
|
8
|
-
import { ITHelpDeskRequests } from './models/ITHelpDeskModel';
|
|
9
|
-
// import { ITServicesTypesSalalah } from './models/ITServicesTypesSalalahModel'; // REMOVED - table no longer used
|
|
10
|
-
// import { ITServicesTypesMuscat } from './models/ITServicesTypesMuscatModel'; // REMOVED - table no longer used
|
|
11
|
-
import { ServiceType } from './models/ServiceTypeModel';
|
|
12
|
-
import { CAAServices } from './models/CAAServices';
|
|
13
|
-
import { CAASubServices } from './models/CAASubServices';
|
|
14
|
-
// import { ITApprovalSettings } from './models/ITApprovalSettings'; // REMOVED - table no longer used
|
|
15
|
-
// import { Workflows } from './models/Workflows';
|
|
16
|
-
import { ItApprovalDetails } from './models/ItApprovalsModel';
|
|
17
|
-
import { ItWorkFlow } from './models/ItWorkflowModel';
|
|
18
|
-
import { WorkflowDefinitions } from './models/WorkflowDefinitions';
|
|
19
|
-
import { WorkflowTask } from './models/WorkflowTask';
|
|
20
|
-
import { Departments } from './models/DepartmentsModel';
|
|
21
|
-
import { Sections } from './models/SectionModel';
|
|
22
|
-
import { WorkflowHierarchy } from './models/WorkflowHierarchy';
|
|
23
|
-
import { WorkflowTaskNames } from './models/WorkflowTaskNames';
|
|
24
|
-
import { Directorate } from './models/DirectorateModel';
|
|
25
|
-
import { Position } from './models/PositionModel';
|
|
26
|
-
import { ServiceBookmarks } from './models/serviceBookmarksModel';
|
|
27
|
-
import { ContactInfo } from './models/contactInfoModel';
|
|
28
|
-
import { UserRole } from './models/userRolesModel';
|
|
29
|
-
import { RoleRights } from './models/roleRightsModel';
|
|
30
|
-
import { Notification } from './models/NotificationModel';
|
|
31
|
-
import { ITRequestChat } from './models/ITRequestChatModel';
|
|
32
|
-
import { ITRequestAttachment } from './models/ITRequestAttachmentModel';
|
|
33
|
-
import { LogisticsRequests } from './models/LogisticsModel';
|
|
34
|
-
import { LogisticsForeignVehicleRequests } from './models/LogisticsForeignVehicleModel';
|
|
35
|
-
import { LogisticsForeignVehiclePassengers } from './models/LogisticsForeignVehiclePassengerModel';
|
|
36
|
-
import { LogisticsApprovalDetails } from './models/LogisticsApprovalModel';
|
|
37
|
-
import { LogisticsRequestChat } from './models/LogisticsChatModel';
|
|
38
|
-
import { LogisticsRequestAttachment } from './models/LogisticsAttachmentModel';
|
|
39
|
-
import { LogisticsWorkFlow } from './models/LogisticsWorkflowModel';
|
|
40
|
-
import { ImportantLinks } from './models/importantLinksModel';
|
|
41
|
-
import { DelegateSettings } from './models/DelegateSettingsModel';
|
|
42
|
-
import { Feedback } from './models/feedbackModel';
|
|
43
|
-
import { PortalFeedback } from './models/PortalFeedbackModel';
|
|
44
|
-
import { VpnRequest } from './models/VpnRequestModel';
|
|
45
|
-
import { VpnApprovalDetails } from './models/VpnApprovalModel';
|
|
46
|
-
import { VpnWorkFlow } from './models/VpnWorkflowModel';
|
|
47
|
-
import { VpnRequestAttachment } from './models/VpnRequestAttachmentModel';
|
|
48
|
-
import { VpnRequestChat } from './models/VpnRequestChatModel';
|
|
49
|
-
import { AccessCardRequest } from './models/AccessCardRequestModel';
|
|
50
|
-
import { AccessCardApproval } from './models/AccessCardApprovalModel';
|
|
51
|
-
import { AccessCardAttachment } from './models/AccessCardAttachmentModel';
|
|
52
|
-
import { AccessCardRequestChat } from './models/AccessCardChatModel';
|
|
53
|
-
import { AccessCardWorkflow } from './models/AccessCardWorkflowModel';
|
|
54
|
-
|
|
55
|
-
import { HotelReservation } from './models/HotelreservationModel'
|
|
56
|
-
import { HotelApprovalDetails } from './models/HotelApprovalModel';
|
|
57
|
-
import { HotelWorkFlow } from './models/HotelWorkFlowModel';
|
|
58
|
-
import { HotelRequestChat } from './models/HotelChatModel';
|
|
59
|
-
import { HotelRequestAttachment } from './models/HotelAttachedModel';
|
|
60
|
-
import { SecurityThreatRequest } from './models/SecurityThreatRequestModel';
|
|
61
|
-
import { SecurityThreatApproval } from './models/SecurityThreatApprovalModel';
|
|
62
|
-
import { SecurityThreatAttachment } from './models/SecurityThreatAttachmentModel';
|
|
63
|
-
import { SecurityThreatChat } from './models/SecurityThreatChatModel';
|
|
64
|
-
import { SecurityThreatWorkFlow } from './models/SecurityThreatWorkflowModel';
|
|
65
|
-
import { SecurityAwarenessRequest } from './models/SecurityAwarenessRequestModel';
|
|
66
|
-
import { SecurityAwarenessApproval } from './models/SecurityAwarenessApprovalModel';
|
|
67
|
-
import { SecurityAwarenessAttachment } from './models/SecurityAwarenessAttachmentModel';
|
|
68
|
-
import { SecurityAwarenessChat } from './models/SecurityAwarenessChatModel';
|
|
69
|
-
import { SecurityAwarenessWorkFlow } from './models/SecurityAwarenessWorkflowModel';
|
|
70
|
-
import { AirportEntryPermit } from './models/AirportEntryPermitModel';
|
|
71
|
-
import { AirportEntryPermitApproval } from './models/AirportEntryPermitApprovalModel';
|
|
72
|
-
import { AirportEntryPermitWorkFlow } from './models/AirportEntryPermitWorkflowModel';
|
|
73
|
-
import { AirportEntryPermitChat } from './models/AirportEntryPermitChatModel';
|
|
74
|
-
import { AirportEntryPermitAttachment } from './models/AirportEntryPermitAttachmentModel';
|
|
75
|
-
import { GroupNames } from './models/GroupNamesModel';
|
|
76
|
-
import { Group } from './models/GroupModel';
|
|
77
|
-
import { HrServiceRequest } from './models/HrServiceRequestModel';
|
|
78
|
-
import { HrServiceApprovalDetails } from './models/HrServiceApprovalModel';
|
|
79
|
-
import { HrServiceWorkFlow } from './models/HrServiceWorkflowModel';
|
|
80
|
-
import { HrServiceRequestAttachment } from './models/HrServiceAttachmentModel';
|
|
81
|
-
import { HrServiceRequestChat } from './models/HrServiceChatModel';
|
|
82
|
-
import { TrainingRequest } from './models/TrainingRequestModel';
|
|
83
|
-
import { DutyMissionRequests } from './models/DutyMissionRequestModel';
|
|
84
|
-
import { DutyMissionApprovalDetails } from './models/DutyMissionApprovalModel';
|
|
85
|
-
import { DutyMissionWorkFlow } from './models/DutyMissionWorkflowModel';
|
|
86
|
-
import { DutyMissionRequestAttachment } from './models/DutyMissionAttachmentModel';
|
|
87
|
-
import { DutyMissionRequestChat } from './models/DutyMissionChatModel';
|
|
88
|
-
import { DutyMissionEmployeeDetails } from './models/DutyMissionEmployeeDetailsModel';
|
|
89
|
-
import { DutyMissionAirTicketDetails } from './models/DutyMissionAirTicketDetailsModel';
|
|
90
|
-
import { TrainingWorkFlow } from './models/TrainingWorkflowModel';
|
|
91
|
-
import { TrainingApprovalDetails } from './models/TrainingApprovalModel';
|
|
92
|
-
import { TrainingRequestChat } from './models/TrainingChatModel';
|
|
93
|
-
import { TrainingRequestAttachment } from './models/TrainingAttachmentModel';
|
|
94
|
-
import { StudyLeaveRequest } from './models/StudyLeaveRequestModel';
|
|
95
|
-
import { StudyLeaveWorkFlow } from './models/StudyLeaveWorkflowModel';
|
|
96
|
-
import { StudyLeaveApprovalDetails } from './models/StudyLeaveApprovalModel';
|
|
97
|
-
import { StudyLeaveRequestChat } from './models/StudyLeaveChatModel';
|
|
98
|
-
import { StudyLeaveRequestAttachment } from './models/StudyLeaveAttachmentModel';
|
|
99
|
-
import {
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
1
|
+
// src/data-source.ts
|
|
2
|
+
import 'reflect-metadata';
|
|
3
|
+
import { DataSource } from 'typeorm';
|
|
4
|
+
import 'dotenv/config';
|
|
5
|
+
import { User } from './models/user'; // import all entities here
|
|
6
|
+
import { userSessions } from './models/user-sessions';
|
|
7
|
+
import { Role } from './models/role';
|
|
8
|
+
import { ITHelpDeskRequests } from './models/ITHelpDeskModel';
|
|
9
|
+
// import { ITServicesTypesSalalah } from './models/ITServicesTypesSalalahModel'; // REMOVED - table no longer used
|
|
10
|
+
// import { ITServicesTypesMuscat } from './models/ITServicesTypesMuscatModel'; // REMOVED - table no longer used
|
|
11
|
+
import { ServiceType } from './models/ServiceTypeModel';
|
|
12
|
+
import { CAAServices } from './models/CAAServices';
|
|
13
|
+
import { CAASubServices } from './models/CAASubServices';
|
|
14
|
+
// import { ITApprovalSettings } from './models/ITApprovalSettings'; // REMOVED - table no longer used
|
|
15
|
+
// import { Workflows } from './models/Workflows';
|
|
16
|
+
import { ItApprovalDetails } from './models/ItApprovalsModel';
|
|
17
|
+
import { ItWorkFlow } from './models/ItWorkflowModel';
|
|
18
|
+
import { WorkflowDefinitions } from './models/WorkflowDefinitions';
|
|
19
|
+
import { WorkflowTask } from './models/WorkflowTask';
|
|
20
|
+
import { Departments } from './models/DepartmentsModel';
|
|
21
|
+
import { Sections } from './models/SectionModel';
|
|
22
|
+
import { WorkflowHierarchy } from './models/WorkflowHierarchy';
|
|
23
|
+
import { WorkflowTaskNames } from './models/WorkflowTaskNames';
|
|
24
|
+
import { Directorate } from './models/DirectorateModel';
|
|
25
|
+
import { Position } from './models/PositionModel';
|
|
26
|
+
import { ServiceBookmarks } from './models/serviceBookmarksModel';
|
|
27
|
+
import { ContactInfo } from './models/contactInfoModel';
|
|
28
|
+
import { UserRole } from './models/userRolesModel';
|
|
29
|
+
import { RoleRights } from './models/roleRightsModel';
|
|
30
|
+
import { Notification } from './models/NotificationModel';
|
|
31
|
+
import { ITRequestChat } from './models/ITRequestChatModel';
|
|
32
|
+
import { ITRequestAttachment } from './models/ITRequestAttachmentModel';
|
|
33
|
+
import { LogisticsRequests } from './models/LogisticsModel';
|
|
34
|
+
import { LogisticsForeignVehicleRequests } from './models/LogisticsForeignVehicleModel';
|
|
35
|
+
import { LogisticsForeignVehiclePassengers } from './models/LogisticsForeignVehiclePassengerModel';
|
|
36
|
+
import { LogisticsApprovalDetails } from './models/LogisticsApprovalModel';
|
|
37
|
+
import { LogisticsRequestChat } from './models/LogisticsChatModel';
|
|
38
|
+
import { LogisticsRequestAttachment } from './models/LogisticsAttachmentModel';
|
|
39
|
+
import { LogisticsWorkFlow } from './models/LogisticsWorkflowModel';
|
|
40
|
+
import { ImportantLinks } from './models/importantLinksModel';
|
|
41
|
+
import { DelegateSettings } from './models/DelegateSettingsModel';
|
|
42
|
+
import { Feedback } from './models/feedbackModel';
|
|
43
|
+
import { PortalFeedback } from './models/PortalFeedbackModel';
|
|
44
|
+
import { VpnRequest } from './models/VpnRequestModel';
|
|
45
|
+
import { VpnApprovalDetails } from './models/VpnApprovalModel';
|
|
46
|
+
import { VpnWorkFlow } from './models/VpnWorkflowModel';
|
|
47
|
+
import { VpnRequestAttachment } from './models/VpnRequestAttachmentModel';
|
|
48
|
+
import { VpnRequestChat } from './models/VpnRequestChatModel';
|
|
49
|
+
import { AccessCardRequest } from './models/AccessCardRequestModel';
|
|
50
|
+
import { AccessCardApproval } from './models/AccessCardApprovalModel';
|
|
51
|
+
import { AccessCardAttachment } from './models/AccessCardAttachmentModel';
|
|
52
|
+
import { AccessCardRequestChat } from './models/AccessCardChatModel';
|
|
53
|
+
import { AccessCardWorkflow } from './models/AccessCardWorkflowModel';
|
|
54
|
+
|
|
55
|
+
import { HotelReservation } from './models/HotelreservationModel'
|
|
56
|
+
import { HotelApprovalDetails } from './models/HotelApprovalModel';
|
|
57
|
+
import { HotelWorkFlow } from './models/HotelWorkFlowModel';
|
|
58
|
+
import { HotelRequestChat } from './models/HotelChatModel';
|
|
59
|
+
import { HotelRequestAttachment } from './models/HotelAttachedModel';
|
|
60
|
+
import { SecurityThreatRequest } from './models/SecurityThreatRequestModel';
|
|
61
|
+
import { SecurityThreatApproval } from './models/SecurityThreatApprovalModel';
|
|
62
|
+
import { SecurityThreatAttachment } from './models/SecurityThreatAttachmentModel';
|
|
63
|
+
import { SecurityThreatChat } from './models/SecurityThreatChatModel';
|
|
64
|
+
import { SecurityThreatWorkFlow } from './models/SecurityThreatWorkflowModel';
|
|
65
|
+
import { SecurityAwarenessRequest } from './models/SecurityAwarenessRequestModel';
|
|
66
|
+
import { SecurityAwarenessApproval } from './models/SecurityAwarenessApprovalModel';
|
|
67
|
+
import { SecurityAwarenessAttachment } from './models/SecurityAwarenessAttachmentModel';
|
|
68
|
+
import { SecurityAwarenessChat } from './models/SecurityAwarenessChatModel';
|
|
69
|
+
import { SecurityAwarenessWorkFlow } from './models/SecurityAwarenessWorkflowModel';
|
|
70
|
+
import { AirportEntryPermit } from './models/AirportEntryPermitModel';
|
|
71
|
+
import { AirportEntryPermitApproval } from './models/AirportEntryPermitApprovalModel';
|
|
72
|
+
import { AirportEntryPermitWorkFlow } from './models/AirportEntryPermitWorkflowModel';
|
|
73
|
+
import { AirportEntryPermitChat } from './models/AirportEntryPermitChatModel';
|
|
74
|
+
import { AirportEntryPermitAttachment } from './models/AirportEntryPermitAttachmentModel';
|
|
75
|
+
import { GroupNames } from './models/GroupNamesModel';
|
|
76
|
+
import { Group } from './models/GroupModel';
|
|
77
|
+
import { HrServiceRequest } from './models/HrServiceRequestModel';
|
|
78
|
+
import { HrServiceApprovalDetails } from './models/HrServiceApprovalModel';
|
|
79
|
+
import { HrServiceWorkFlow } from './models/HrServiceWorkflowModel';
|
|
80
|
+
import { HrServiceRequestAttachment } from './models/HrServiceAttachmentModel';
|
|
81
|
+
import { HrServiceRequestChat } from './models/HrServiceChatModel';
|
|
82
|
+
import { TrainingRequest } from './models/TrainingRequestModel';
|
|
83
|
+
import { DutyMissionRequests } from './models/DutyMissionRequestModel';
|
|
84
|
+
import { DutyMissionApprovalDetails } from './models/DutyMissionApprovalModel';
|
|
85
|
+
import { DutyMissionWorkFlow } from './models/DutyMissionWorkflowModel';
|
|
86
|
+
import { DutyMissionRequestAttachment } from './models/DutyMissionAttachmentModel';
|
|
87
|
+
import { DutyMissionRequestChat } from './models/DutyMissionChatModel';
|
|
88
|
+
import { DutyMissionEmployeeDetails } from './models/DutyMissionEmployeeDetailsModel';
|
|
89
|
+
import { DutyMissionAirTicketDetails } from './models/DutyMissionAirTicketDetailsModel';
|
|
90
|
+
import { TrainingWorkFlow } from './models/TrainingWorkflowModel';
|
|
91
|
+
import { TrainingApprovalDetails } from './models/TrainingApprovalModel';
|
|
92
|
+
import { TrainingRequestChat } from './models/TrainingChatModel';
|
|
93
|
+
import { TrainingRequestAttachment } from './models/TrainingAttachmentModel';
|
|
94
|
+
import { StudyLeaveRequest } from './models/StudyLeaveRequestModel';
|
|
95
|
+
import { StudyLeaveWorkFlow } from './models/StudyLeaveWorkflowModel';
|
|
96
|
+
import { StudyLeaveApprovalDetails } from './models/StudyLeaveApprovalModel';
|
|
97
|
+
import { StudyLeaveRequestChat } from './models/StudyLeaveChatModel';
|
|
98
|
+
import { StudyLeaveRequestAttachment } from './models/StudyLeaveAttachmentModel';
|
|
99
|
+
import { AnnualTrainingPlanRequest } from './models/AnnualTrainingPlanRequestModel';
|
|
100
|
+
import { AnnualTrainingPlanWorkFlow } from './models/AnnualTrainingPlanWorkflowModel';
|
|
101
|
+
import { AnnualTrainingPlanApprovalDetails } from './models/AnnualTrainingPlanApprovalModel';
|
|
102
|
+
import { AnnualTrainingPlanRequestChat } from './models/AnnualTrainingPlanChatModel';
|
|
103
|
+
import { AnnualTrainingPlanRequestAttachment } from './models/AnnualTrainingPlanAttachmentModel';
|
|
104
|
+
import { TrainingRoomBookingRequest } from './models/TrainingRoomBookingRequestModel';
|
|
105
|
+
import { TrainingRoomBookingWorkFlow } from './models/TrainingRoomBookingWorkflowModel';
|
|
106
|
+
import { TrainingRoomBookingApprovalDetails } from './models/TrainingRoomBookingApprovalModel';
|
|
107
|
+
import { TrainingRoomBookingRequestChat } from './models/TrainingRoomBookingChatModel';
|
|
108
|
+
import { TrainingRoomBookingRequestAttachment } from './models/TrainingRoomBookingAttachmentModel';
|
|
109
|
+
import { SecondmentRequest } from './models/SecondmentRequestModel';
|
|
110
|
+
|
|
111
|
+
export const AppDataSource = new DataSource({
|
|
112
|
+
type: 'postgres',
|
|
113
|
+
host: process.env.DB_HOST || 'localhost',
|
|
114
|
+
port: +(process.env.DB_PORT || 5432),
|
|
115
|
+
username: process.env.DB_USER || 'postgres',
|
|
116
|
+
password: process.env.DB_PASS || 'postgres',
|
|
117
|
+
database: process.env.DB_NAME || 'common_models',
|
|
118
|
+
synchronize: true, // auto-create tables (disable in prod)
|
|
119
|
+
logging: false,
|
|
120
|
+
entities: [
|
|
121
|
+
User,userSessions,
|
|
122
|
+
Role,
|
|
123
|
+
ITHelpDeskRequests,
|
|
124
|
+
// ITServicesTypesSalalah, // REMOVED - table no longer used
|
|
125
|
+
// ITServicesTypesMuscat, // REMOVED - table no longer used
|
|
126
|
+
ServiceType,
|
|
127
|
+
CAAServices,
|
|
128
|
+
CAASubServices,
|
|
129
|
+
// ITApprovalSettings, // REMOVED - table no longer used
|
|
130
|
+
// Workflows,
|
|
131
|
+
ItApprovalDetails,
|
|
132
|
+
ItWorkFlow,
|
|
133
|
+
WorkflowDefinitions,
|
|
134
|
+
WorkflowTask,
|
|
135
|
+
Departments,
|
|
136
|
+
Sections,
|
|
137
|
+
WorkflowHierarchy,
|
|
138
|
+
WorkflowTaskNames,
|
|
139
|
+
Directorate,
|
|
140
|
+
Position,
|
|
141
|
+
ServiceBookmarks,
|
|
142
|
+
ContactInfo,
|
|
143
|
+
UserRole,
|
|
144
|
+
RoleRights,
|
|
145
|
+
Notification,
|
|
146
|
+
ITRequestChat,
|
|
147
|
+
ITRequestAttachment,
|
|
148
|
+
LogisticsRequests,
|
|
149
|
+
LogisticsForeignVehicleRequests,
|
|
150
|
+
LogisticsForeignVehiclePassengers,
|
|
151
|
+
LogisticsApprovalDetails,
|
|
152
|
+
LogisticsRequestChat,
|
|
153
|
+
LogisticsRequestAttachment,
|
|
154
|
+
LogisticsWorkFlow,
|
|
155
|
+
AccessCardRequest,
|
|
156
|
+
AccessCardApproval,
|
|
157
|
+
AccessCardAttachment,
|
|
158
|
+
AccessCardRequestChat,
|
|
159
|
+
AccessCardWorkflow,
|
|
160
|
+
ImportantLinks,
|
|
161
|
+
DelegateSettings,
|
|
162
|
+
Feedback,
|
|
163
|
+
PortalFeedback,
|
|
164
|
+
VpnRequest,
|
|
165
|
+
VpnApprovalDetails,
|
|
166
|
+
VpnWorkFlow,
|
|
167
|
+
VpnRequestAttachment,
|
|
168
|
+
VpnRequestChat,
|
|
169
|
+
HotelReservation,
|
|
170
|
+
HotelApprovalDetails,
|
|
171
|
+
HotelWorkFlow,
|
|
172
|
+
HotelRequestChat,
|
|
173
|
+
HotelRequestAttachment,
|
|
174
|
+
SecurityThreatRequest,
|
|
175
|
+
SecurityThreatApproval,
|
|
176
|
+
SecurityThreatAttachment,
|
|
177
|
+
SecurityThreatChat,
|
|
178
|
+
SecurityThreatWorkFlow,
|
|
179
|
+
SecurityAwarenessRequest,
|
|
180
|
+
SecurityAwarenessApproval,
|
|
181
|
+
SecurityAwarenessAttachment,
|
|
182
|
+
SecurityAwarenessChat,
|
|
183
|
+
SecurityAwarenessWorkFlow,
|
|
184
|
+
GroupNames,
|
|
185
|
+
Group,
|
|
186
|
+
AirportEntryPermit,
|
|
187
|
+
AirportEntryPermitApproval,
|
|
188
|
+
AirportEntryPermitWorkFlow,
|
|
189
|
+
AirportEntryPermitChat,
|
|
190
|
+
AirportEntryPermitAttachment,
|
|
191
|
+
HrServiceRequest,
|
|
192
|
+
HrServiceApprovalDetails,
|
|
193
|
+
HrServiceWorkFlow,
|
|
194
|
+
HrServiceRequestAttachment,
|
|
195
|
+
HrServiceRequestChat,
|
|
196
|
+
TrainingRequest,
|
|
197
|
+
TrainingWorkFlow,
|
|
198
|
+
TrainingApprovalDetails,
|
|
199
|
+
TrainingRequestChat,
|
|
200
|
+
TrainingRequestAttachment,
|
|
201
|
+
StudyLeaveRequest,
|
|
202
|
+
StudyLeaveWorkFlow,
|
|
203
|
+
StudyLeaveApprovalDetails,
|
|
204
|
+
StudyLeaveRequestChat,
|
|
205
|
+
StudyLeaveRequestAttachment,
|
|
206
|
+
AnnualTrainingPlanRequest,
|
|
207
|
+
AnnualTrainingPlanWorkFlow,
|
|
208
|
+
AnnualTrainingPlanApprovalDetails,
|
|
209
|
+
AnnualTrainingPlanRequestChat,
|
|
210
|
+
AnnualTrainingPlanRequestAttachment,
|
|
211
|
+
TrainingRoomBookingRequest,
|
|
212
|
+
TrainingRoomBookingWorkFlow,
|
|
213
|
+
TrainingRoomBookingApprovalDetails,
|
|
214
|
+
TrainingRoomBookingRequestChat,
|
|
215
|
+
TrainingRoomBookingRequestAttachment,
|
|
216
|
+
SecondmentRequest,
|
|
217
|
+
DutyMissionRequests,
|
|
218
|
+
DutyMissionApprovalDetails,
|
|
219
|
+
DutyMissionWorkFlow,
|
|
220
|
+
DutyMissionRequestAttachment,
|
|
221
|
+
DutyMissionRequestChat,
|
|
222
|
+
DutyMissionEmployeeDetails,
|
|
223
|
+
DutyMissionAirTicketDetails
|
|
224
|
+
],
|
|
225
|
+
});
|
package/src/index.ts
CHANGED
|
@@ -104,6 +104,30 @@ export {StudyLeaveRequestAttachment} from './models/StudyLeaveAttachmentModel';
|
|
|
104
104
|
export {StudyLeaveRequestChat} from './models/StudyLeaveChatModel';
|
|
105
105
|
export {StudyLeaveMessageType} from './models/StudyLeaveChatModel';
|
|
106
106
|
export {StudyLeaveChatStatus} from './models/StudyLeaveChatModel';
|
|
107
|
+
export * from './models/AnnualTrainingPlanRequestModel';
|
|
108
|
+
export * from './models/AnnualTrainingPlanWorkflowModel';
|
|
109
|
+
export * from './models/AnnualTrainingPlanApprovalModel';
|
|
110
|
+
export * from './models/AnnualTrainingPlanChatModel';
|
|
111
|
+
export * from './models/AnnualTrainingPlanAttachmentModel';
|
|
112
|
+
export {AnnualTrainingPlanRequestStatus, AnnualTrainingPlanPlace} from './models/AnnualTrainingPlanRequestModel';
|
|
113
|
+
export {AnnualTrainingPlanApprovalStatus} from './models/AnnualTrainingPlanApprovalModel';
|
|
114
|
+
export {AnnualTrainingPlanWorkFlowStatus} from './models/AnnualTrainingPlanWorkflowModel';
|
|
115
|
+
export {AnnualTrainingPlanRequestAttachment} from './models/AnnualTrainingPlanAttachmentModel';
|
|
116
|
+
export {AnnualTrainingPlanRequestChat} from './models/AnnualTrainingPlanChatModel';
|
|
117
|
+
export {AnnualTrainingPlanMessageType} from './models/AnnualTrainingPlanChatModel';
|
|
118
|
+
export {AnnualTrainingPlanChatStatus} from './models/AnnualTrainingPlanChatModel';
|
|
119
|
+
export * from './models/TrainingRoomBookingRequestModel';
|
|
120
|
+
export * from './models/TrainingRoomBookingWorkflowModel';
|
|
121
|
+
export * from './models/TrainingRoomBookingApprovalModel';
|
|
122
|
+
export * from './models/TrainingRoomBookingChatModel';
|
|
123
|
+
export * from './models/TrainingRoomBookingAttachmentModel';
|
|
124
|
+
export {TrainingRoomBookingRequestStatus, TrainingRoomBookingRoomType} from './models/TrainingRoomBookingRequestModel';
|
|
125
|
+
export {TrainingRoomBookingApprovalStatus} from './models/TrainingRoomBookingApprovalModel';
|
|
126
|
+
export {TrainingRoomBookingWorkFlowStatus} from './models/TrainingRoomBookingWorkflowModel';
|
|
127
|
+
export {TrainingRoomBookingRequestAttachment} from './models/TrainingRoomBookingAttachmentModel';
|
|
128
|
+
export {TrainingRoomBookingRequestChat} from './models/TrainingRoomBookingChatModel';
|
|
129
|
+
export {TrainingRoomBookingMessageType} from './models/TrainingRoomBookingChatModel';
|
|
130
|
+
export {TrainingRoomBookingChatStatus} from './models/TrainingRoomBookingChatModel';
|
|
107
131
|
export * from './models/SecondmentRequestModel';
|
|
108
132
|
export {SecondmentRequestStatus} from './models/SecondmentRequestModel';
|
|
109
133
|
export * from './models/TemporaryAssignmentRequestModel';
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { Column, Entity } from "typeorm";
|
|
2
|
+
import { BaseModel } from "./BaseModel";
|
|
3
|
+
|
|
4
|
+
export enum AnnualTrainingPlanApprovalStatus {
|
|
5
|
+
PENDING = "Pending",
|
|
6
|
+
IN_PROGRESS = "In Progress",
|
|
7
|
+
APPROVED = "Approved",
|
|
8
|
+
REJECTED = "Rejected",
|
|
9
|
+
ASSIGNED = "Assigned"
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
@Entity({ name: "annual_training_plan_approvals" })
|
|
13
|
+
export class AnnualTrainingPlanApprovalDetails extends BaseModel {
|
|
14
|
+
@Column({ type: "integer", nullable: false })
|
|
15
|
+
request_id: number;
|
|
16
|
+
|
|
17
|
+
@Column({ type: "integer", nullable: true })
|
|
18
|
+
service_id: number | null;
|
|
19
|
+
|
|
20
|
+
@Column({ type: "integer", nullable: true })
|
|
21
|
+
sub_service_id: number | null;
|
|
22
|
+
|
|
23
|
+
@Column({ type: "integer", nullable: false })
|
|
24
|
+
level: number;
|
|
25
|
+
|
|
26
|
+
@Column({ type: "integer", nullable: true })
|
|
27
|
+
approver_user_id: number | null;
|
|
28
|
+
|
|
29
|
+
@Column({ type: "integer", nullable: true })
|
|
30
|
+
approver_role_id: number | null;
|
|
31
|
+
|
|
32
|
+
@Column({ type: "integer", nullable: true })
|
|
33
|
+
department_id: number | null;
|
|
34
|
+
|
|
35
|
+
@Column({ type: "integer", nullable: true })
|
|
36
|
+
section_id: number | null;
|
|
37
|
+
|
|
38
|
+
@Column({ type: "integer", nullable: true })
|
|
39
|
+
delegate_user_id: number | null;
|
|
40
|
+
|
|
41
|
+
@Column({ type: "integer", nullable: true })
|
|
42
|
+
approved_by: number | null;
|
|
43
|
+
|
|
44
|
+
@Column({ type: "varchar", length: 255, nullable: true, default: "" })
|
|
45
|
+
comment: string;
|
|
46
|
+
|
|
47
|
+
@Column({
|
|
48
|
+
type: "enum",
|
|
49
|
+
enum: AnnualTrainingPlanApprovalStatus,
|
|
50
|
+
default: AnnualTrainingPlanApprovalStatus.PENDING,
|
|
51
|
+
nullable: false
|
|
52
|
+
})
|
|
53
|
+
approval_status: AnnualTrainingPlanApprovalStatus;
|
|
54
|
+
|
|
55
|
+
@Column({ type: "boolean", default: false, nullable: false })
|
|
56
|
+
is_manager: boolean;
|
|
57
|
+
|
|
58
|
+
@Column({ type: "boolean", default: true, nullable: false })
|
|
59
|
+
is_allowed: boolean;
|
|
60
|
+
|
|
61
|
+
constructor(
|
|
62
|
+
request_id: number,
|
|
63
|
+
approver_user_id: number | null,
|
|
64
|
+
approver_role_id: number | null,
|
|
65
|
+
comment: string,
|
|
66
|
+
approval_status: AnnualTrainingPlanApprovalStatus,
|
|
67
|
+
level: number,
|
|
68
|
+
service_id?: number | null,
|
|
69
|
+
sub_service_id?: number | null,
|
|
70
|
+
department_id?: number | null,
|
|
71
|
+
section_id?: number | null,
|
|
72
|
+
delegate_user_id?: number | null,
|
|
73
|
+
approved_by?: number | null,
|
|
74
|
+
is_manager?: boolean,
|
|
75
|
+
is_allowed?: boolean
|
|
76
|
+
) {
|
|
77
|
+
super();
|
|
78
|
+
this.request_id = request_id;
|
|
79
|
+
this.service_id = service_id || null;
|
|
80
|
+
this.sub_service_id = sub_service_id || null;
|
|
81
|
+
this.approver_user_id = approver_user_id;
|
|
82
|
+
this.approver_role_id = approver_role_id;
|
|
83
|
+
this.comment = comment;
|
|
84
|
+
this.approval_status = approval_status;
|
|
85
|
+
this.level = level;
|
|
86
|
+
this.department_id = department_id || null;
|
|
87
|
+
this.section_id = section_id || null;
|
|
88
|
+
this.delegate_user_id = delegate_user_id || null;
|
|
89
|
+
this.approved_by = approved_by || null;
|
|
90
|
+
this.is_manager = is_manager ?? false;
|
|
91
|
+
this.is_allowed = is_allowed !== undefined ? is_allowed : true;
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { Column, Entity } from "typeorm";
|
|
2
|
+
import { BaseModel } from "./BaseModel";
|
|
3
|
+
|
|
4
|
+
@Entity({ name: "annual_training_plan_request_attachments" })
|
|
5
|
+
export class AnnualTrainingPlanRequestAttachment extends BaseModel {
|
|
6
|
+
@Column({ type: "integer", nullable: false })
|
|
7
|
+
request_id: number;
|
|
8
|
+
|
|
9
|
+
@Column({ type: "integer", nullable: true })
|
|
10
|
+
service_id: number | null;
|
|
11
|
+
|
|
12
|
+
@Column({ type: "integer", nullable: true })
|
|
13
|
+
sub_service_id: number | null;
|
|
14
|
+
|
|
15
|
+
@Column({ type: "integer", nullable: false })
|
|
16
|
+
uploaded_by: number;
|
|
17
|
+
|
|
18
|
+
@Column({ type: "varchar", length: 500, nullable: false })
|
|
19
|
+
file_url: string;
|
|
20
|
+
|
|
21
|
+
@Column({ type: "varchar", length: 255, nullable: true })
|
|
22
|
+
file_name: string;
|
|
23
|
+
|
|
24
|
+
@Column({ type: "varchar", length: 100, nullable: true })
|
|
25
|
+
file_type: string;
|
|
26
|
+
|
|
27
|
+
@Column({ type: "bigint", nullable: true })
|
|
28
|
+
file_size: number | null;
|
|
29
|
+
|
|
30
|
+
@Column({ type: "text", nullable: true })
|
|
31
|
+
description: string;
|
|
32
|
+
|
|
33
|
+
constructor(
|
|
34
|
+
request_id: number,
|
|
35
|
+
uploaded_by: number,
|
|
36
|
+
file_url: string,
|
|
37
|
+
service_id?: number | null,
|
|
38
|
+
sub_service_id?: number | null,
|
|
39
|
+
file_name?: string,
|
|
40
|
+
file_type?: string,
|
|
41
|
+
file_size?: number,
|
|
42
|
+
description?: string
|
|
43
|
+
) {
|
|
44
|
+
super();
|
|
45
|
+
this.request_id = request_id;
|
|
46
|
+
this.service_id = service_id || null;
|
|
47
|
+
this.sub_service_id = sub_service_id || null;
|
|
48
|
+
this.uploaded_by = uploaded_by;
|
|
49
|
+
this.file_url = file_url;
|
|
50
|
+
this.file_name = file_name || "";
|
|
51
|
+
this.file_type = file_type || "";
|
|
52
|
+
this.file_size = file_size || null;
|
|
53
|
+
this.description = description || "";
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
|