@platform-modules/civil-aviation-authority 2.0.6 → 2.0.7

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 CHANGED
@@ -1,11 +1,11 @@
1
- DB_HOST=localhost
2
- DB_PORT=5433
3
- DB_USER=postgres
4
- DB_PASS=123
5
- DB_NAME=CAA
1
+ # DB_HOST=localhost
2
+ # DB_PORT=5433
3
+ # DB_USER=postgres
4
+ # DB_PASS=123
5
+ # DB_NAME=CAA
6
6
 
7
- # DB_HOST=164.52.222.169
8
- # DB_PORT=5432
9
- # DB_USER=postgres_admin_user
10
- # DB_PASS=pg_admin_user_pwd_caa_fa_$%^&OIukhjgcvbn
11
- # DB_NAME=CAA
7
+ DB_HOST=164.52.222.169
8
+ DB_PORT=5432
9
+ DB_USER=postgres_admin_user
10
+ DB_PASS=pg_admin_user_pwd_caa_fa_$%^&OIukhjgcvbn
11
+ DB_NAME=CAA
@@ -34,6 +34,8 @@ const NotificationModel_1 = require("./models/NotificationModel");
34
34
  const ITRequestChatModel_1 = require("./models/ITRequestChatModel");
35
35
  const ITRequestAttachmentModel_1 = require("./models/ITRequestAttachmentModel");
36
36
  const LogisticsModel_1 = require("./models/LogisticsModel");
37
+ const LogisticsForeignVehicleModel_1 = require("./models/LogisticsForeignVehicleModel");
38
+ const LogisticsForeignVehiclePassengerModel_1 = require("./models/LogisticsForeignVehiclePassengerModel");
37
39
  const LogisticsApprovalModel_1 = require("./models/LogisticsApprovalModel");
38
40
  const LogisticsChatModel_1 = require("./models/LogisticsChatModel");
39
41
  const LogisticsAttachmentModel_1 = require("./models/LogisticsAttachmentModel");
@@ -76,6 +78,8 @@ exports.AppDataSource = new typeorm_1.DataSource({
76
78
  ITRequestChatModel_1.ITRequestChat,
77
79
  ITRequestAttachmentModel_1.ITRequestAttachment,
78
80
  LogisticsModel_1.LogisticsRequests,
81
+ LogisticsForeignVehicleModel_1.LogisticsForeignVehicleRequests,
82
+ LogisticsForeignVehiclePassengerModel_1.LogisticsForeignVehiclePassengers,
79
83
  LogisticsApprovalModel_1.LogisticsApprovalDetails,
80
84
  LogisticsChatModel_1.LogisticsRequestChat,
81
85
  LogisticsAttachmentModel_1.LogisticsRequestAttachment,
package/dist/index.d.ts CHANGED
@@ -26,6 +26,8 @@ export * from './models/NotificationModel';
26
26
  export * from './models/ITRequestChatModel';
27
27
  export * from './models/ITRequestAttachmentModel';
28
28
  export * from './models/LogisticsModel';
29
+ export * from './models/LogisticsForeignVehicleModel';
30
+ export * from './models/LogisticsForeignVehiclePassengerModel';
29
31
  export * from './models/LogisticsApprovalModel';
30
32
  export * from './models/LogisticsChatModel';
31
33
  export * from './models/LogisticsAttachmentModel';
package/dist/index.js CHANGED
@@ -43,6 +43,8 @@ __exportStar(require("./models/NotificationModel"), exports);
43
43
  __exportStar(require("./models/ITRequestChatModel"), exports);
44
44
  __exportStar(require("./models/ITRequestAttachmentModel"), exports);
45
45
  __exportStar(require("./models/LogisticsModel"), exports);
46
+ __exportStar(require("./models/LogisticsForeignVehicleModel"), exports);
47
+ __exportStar(require("./models/LogisticsForeignVehiclePassengerModel"), exports);
46
48
  __exportStar(require("./models/LogisticsApprovalModel"), exports);
47
49
  __exportStar(require("./models/LogisticsChatModel"), exports);
48
50
  __exportStar(require("./models/LogisticsAttachmentModel"), exports);
@@ -0,0 +1,43 @@
1
+ import { BaseModel } from './BaseModel';
2
+ export declare enum Foreign_Purpose_of_Travel {
3
+ AIRPORT_PICKUP = "Airport Pickup/Drop-off",
4
+ OFFICIAL_MEETING = "Official Meeting",
5
+ SITE_VISIT = "Site Visit",
6
+ CONFERENCE = "Conference/Event",
7
+ OTHER = "Other"
8
+ }
9
+ export declare enum Foreign_Vehicle_Required_Location {
10
+ INSIDE = "Inside Muscat",
11
+ OUTSIDE = "Outside Muscat"
12
+ }
13
+ export declare enum Foreign_Request_Type {
14
+ NEW_REQUEST = "New Request",
15
+ EXTENSION = "Extension of Previous Request"
16
+ }
17
+ export declare enum Foreign_Request_Status {
18
+ PENDING = "Pending",
19
+ ASSIGNED = "Assigned",
20
+ IN_PROGRESS = "In Progress",
21
+ APPROVED = "Approved",
22
+ REJECTED = "Rejected"
23
+ }
24
+ export declare class LogisticsForeignVehicleRequests extends BaseModel {
25
+ req_user_department_id: number | null;
26
+ req_user_section_id: number | null;
27
+ service_id: number;
28
+ sub_service_id: number;
29
+ user_id: number;
30
+ number_of_passengers: number;
31
+ purpose_of_travel: Foreign_Purpose_of_Travel;
32
+ vehicle_required_location: Foreign_Vehicle_Required_Location;
33
+ employee_id_passport: string | null;
34
+ contact_number: string;
35
+ request_type: Foreign_Request_Type;
36
+ origin_city: string | null;
37
+ destination_city: string;
38
+ arrival_departure_datetime: Date;
39
+ special_instructions: string | null;
40
+ status: Foreign_Request_Status;
41
+ workflow_execution_id: string | null;
42
+ constructor(req_user_department_id: number | null, req_user_section_id: number | null, service_id: number, sub_service_id: number, user_id: number, number_of_passengers: number, purpose_of_travel: Foreign_Purpose_of_Travel, vehicle_required_location: Foreign_Vehicle_Required_Location, contact_number: string, request_type: Foreign_Request_Type, destination_city: string, arrival_departure_datetime: Date, status: Foreign_Request_Status, employee_id_passport?: string | null, origin_city?: string | null, special_instructions?: string | null, workflow_execution_id?: string | null);
43
+ }
@@ -0,0 +1,155 @@
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.LogisticsForeignVehicleRequests = exports.Foreign_Request_Status = exports.Foreign_Request_Type = exports.Foreign_Vehicle_Required_Location = exports.Foreign_Purpose_of_Travel = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ var Foreign_Purpose_of_Travel;
16
+ (function (Foreign_Purpose_of_Travel) {
17
+ Foreign_Purpose_of_Travel["AIRPORT_PICKUP"] = "Airport Pickup/Drop-off";
18
+ Foreign_Purpose_of_Travel["OFFICIAL_MEETING"] = "Official Meeting";
19
+ Foreign_Purpose_of_Travel["SITE_VISIT"] = "Site Visit";
20
+ Foreign_Purpose_of_Travel["CONFERENCE"] = "Conference/Event";
21
+ Foreign_Purpose_of_Travel["OTHER"] = "Other";
22
+ })(Foreign_Purpose_of_Travel || (exports.Foreign_Purpose_of_Travel = Foreign_Purpose_of_Travel = {}));
23
+ var Foreign_Vehicle_Required_Location;
24
+ (function (Foreign_Vehicle_Required_Location) {
25
+ Foreign_Vehicle_Required_Location["INSIDE"] = "Inside Muscat";
26
+ Foreign_Vehicle_Required_Location["OUTSIDE"] = "Outside Muscat";
27
+ })(Foreign_Vehicle_Required_Location || (exports.Foreign_Vehicle_Required_Location = Foreign_Vehicle_Required_Location = {}));
28
+ var Foreign_Request_Type;
29
+ (function (Foreign_Request_Type) {
30
+ Foreign_Request_Type["NEW_REQUEST"] = "New Request";
31
+ Foreign_Request_Type["EXTENSION"] = "Extension of Previous Request";
32
+ })(Foreign_Request_Type || (exports.Foreign_Request_Type = Foreign_Request_Type = {}));
33
+ var Foreign_Request_Status;
34
+ (function (Foreign_Request_Status) {
35
+ Foreign_Request_Status["PENDING"] = "Pending";
36
+ Foreign_Request_Status["ASSIGNED"] = "Assigned";
37
+ Foreign_Request_Status["IN_PROGRESS"] = "In Progress";
38
+ Foreign_Request_Status["APPROVED"] = "Approved";
39
+ Foreign_Request_Status["REJECTED"] = "Rejected";
40
+ })(Foreign_Request_Status || (exports.Foreign_Request_Status = Foreign_Request_Status = {}));
41
+ let LogisticsForeignVehicleRequests = class LogisticsForeignVehicleRequests extends BaseModel_1.BaseModel {
42
+ constructor(req_user_department_id, req_user_section_id, service_id, sub_service_id, user_id, number_of_passengers, purpose_of_travel, vehicle_required_location, contact_number, request_type, destination_city, arrival_departure_datetime, status, employee_id_passport, origin_city, special_instructions, workflow_execution_id) {
43
+ super();
44
+ this.req_user_department_id = req_user_department_id ?? null;
45
+ this.req_user_section_id = req_user_section_id ?? null;
46
+ this.service_id = service_id;
47
+ this.sub_service_id = sub_service_id;
48
+ this.user_id = user_id;
49
+ this.number_of_passengers = number_of_passengers;
50
+ this.purpose_of_travel = purpose_of_travel;
51
+ this.vehicle_required_location = vehicle_required_location;
52
+ this.employee_id_passport = employee_id_passport ?? null;
53
+ this.contact_number = contact_number;
54
+ this.request_type = request_type;
55
+ this.origin_city = origin_city ?? null;
56
+ this.destination_city = destination_city;
57
+ this.arrival_departure_datetime = arrival_departure_datetime;
58
+ this.special_instructions = special_instructions ?? null;
59
+ this.status = status;
60
+ this.workflow_execution_id = workflow_execution_id ?? null;
61
+ }
62
+ };
63
+ exports.LogisticsForeignVehicleRequests = LogisticsForeignVehicleRequests;
64
+ __decorate([
65
+ (0, typeorm_1.Column)({ type: 'int', nullable: true }),
66
+ __metadata("design:type", Object)
67
+ ], LogisticsForeignVehicleRequests.prototype, "req_user_department_id", void 0);
68
+ __decorate([
69
+ (0, typeorm_1.Column)({ type: 'int', nullable: true }),
70
+ __metadata("design:type", Object)
71
+ ], LogisticsForeignVehicleRequests.prototype, "req_user_section_id", void 0);
72
+ __decorate([
73
+ (0, typeorm_1.Column)({ nullable: true }),
74
+ __metadata("design:type", Number)
75
+ ], LogisticsForeignVehicleRequests.prototype, "service_id", void 0);
76
+ __decorate([
77
+ (0, typeorm_1.Column)({ nullable: true }),
78
+ __metadata("design:type", Number)
79
+ ], LogisticsForeignVehicleRequests.prototype, "sub_service_id", void 0);
80
+ __decorate([
81
+ (0, typeorm_1.Column)({ nullable: false }),
82
+ __metadata("design:type", Number)
83
+ ], LogisticsForeignVehicleRequests.prototype, "user_id", void 0);
84
+ __decorate([
85
+ (0, typeorm_1.Column)({ type: 'int', nullable: false }),
86
+ __metadata("design:type", Number)
87
+ ], LogisticsForeignVehicleRequests.prototype, "number_of_passengers", void 0);
88
+ __decorate([
89
+ (0, typeorm_1.Column)({
90
+ type: "enum",
91
+ enum: Foreign_Purpose_of_Travel,
92
+ default: Foreign_Purpose_of_Travel.OTHER,
93
+ nullable: false,
94
+ }),
95
+ __metadata("design:type", String)
96
+ ], LogisticsForeignVehicleRequests.prototype, "purpose_of_travel", void 0);
97
+ __decorate([
98
+ (0, typeorm_1.Column)({
99
+ type: "enum",
100
+ enum: Foreign_Vehicle_Required_Location,
101
+ default: Foreign_Vehicle_Required_Location.INSIDE,
102
+ nullable: false,
103
+ }),
104
+ __metadata("design:type", String)
105
+ ], LogisticsForeignVehicleRequests.prototype, "vehicle_required_location", void 0);
106
+ __decorate([
107
+ (0, typeorm_1.Column)({ type: 'varchar', length: 100, nullable: true }),
108
+ __metadata("design:type", Object)
109
+ ], LogisticsForeignVehicleRequests.prototype, "employee_id_passport", void 0);
110
+ __decorate([
111
+ (0, typeorm_1.Column)({ type: 'varchar', length: 20, nullable: false }),
112
+ __metadata("design:type", String)
113
+ ], LogisticsForeignVehicleRequests.prototype, "contact_number", void 0);
114
+ __decorate([
115
+ (0, typeorm_1.Column)({
116
+ type: "enum",
117
+ enum: Foreign_Request_Type,
118
+ default: Foreign_Request_Type.NEW_REQUEST,
119
+ nullable: false,
120
+ }),
121
+ __metadata("design:type", String)
122
+ ], LogisticsForeignVehicleRequests.prototype, "request_type", void 0);
123
+ __decorate([
124
+ (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: true }),
125
+ __metadata("design:type", Object)
126
+ ], LogisticsForeignVehicleRequests.prototype, "origin_city", void 0);
127
+ __decorate([
128
+ (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: false }),
129
+ __metadata("design:type", String)
130
+ ], LogisticsForeignVehicleRequests.prototype, "destination_city", void 0);
131
+ __decorate([
132
+ (0, typeorm_1.Column)({ type: 'timestamp', nullable: false }),
133
+ __metadata("design:type", Date)
134
+ ], LogisticsForeignVehicleRequests.prototype, "arrival_departure_datetime", void 0);
135
+ __decorate([
136
+ (0, typeorm_1.Column)({ type: 'text', nullable: true }),
137
+ __metadata("design:type", Object)
138
+ ], LogisticsForeignVehicleRequests.prototype, "special_instructions", void 0);
139
+ __decorate([
140
+ (0, typeorm_1.Column)({
141
+ type: "enum",
142
+ enum: Foreign_Request_Status,
143
+ default: Foreign_Request_Status.PENDING,
144
+ nullable: false,
145
+ }),
146
+ __metadata("design:type", String)
147
+ ], LogisticsForeignVehicleRequests.prototype, "status", void 0);
148
+ __decorate([
149
+ (0, typeorm_1.Column)({ type: "varchar", nullable: true }),
150
+ __metadata("design:type", Object)
151
+ ], LogisticsForeignVehicleRequests.prototype, "workflow_execution_id", void 0);
152
+ exports.LogisticsForeignVehicleRequests = LogisticsForeignVehicleRequests = __decorate([
153
+ (0, typeorm_1.Entity)({ name: 'logistics_foreign_vehicle_requests' }),
154
+ __metadata("design:paramtypes", [Object, Object, Number, Number, Number, Number, String, String, String, String, String, Date, String, Object, Object, Object, Object])
155
+ ], LogisticsForeignVehicleRequests);
@@ -0,0 +1,6 @@
1
+ import { BaseModel } from './BaseModel';
2
+ export declare class LogisticsForeignVehiclePassengers extends BaseModel {
3
+ foreign_vehicle_request_id: number;
4
+ passenger_name: string;
5
+ constructor(foreign_vehicle_request_id: number, passenger_name: string);
6
+ }
@@ -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.LogisticsForeignVehiclePassengers = void 0;
13
+ const typeorm_1 = require("typeorm");
14
+ const BaseModel_1 = require("./BaseModel");
15
+ let LogisticsForeignVehiclePassengers = class LogisticsForeignVehiclePassengers extends BaseModel_1.BaseModel {
16
+ constructor(foreign_vehicle_request_id, passenger_name) {
17
+ super();
18
+ this.foreign_vehicle_request_id = foreign_vehicle_request_id;
19
+ this.passenger_name = passenger_name;
20
+ }
21
+ };
22
+ exports.LogisticsForeignVehiclePassengers = LogisticsForeignVehiclePassengers;
23
+ __decorate([
24
+ (0, typeorm_1.Column)({ type: 'integer', nullable: false }),
25
+ __metadata("design:type", Number)
26
+ ], LogisticsForeignVehiclePassengers.prototype, "foreign_vehicle_request_id", void 0);
27
+ __decorate([
28
+ (0, typeorm_1.Column)({ type: 'varchar', length: 255, nullable: false }),
29
+ __metadata("design:type", String)
30
+ ], LogisticsForeignVehiclePassengers.prototype, "passenger_name", void 0);
31
+ exports.LogisticsForeignVehiclePassengers = LogisticsForeignVehiclePassengers = __decorate([
32
+ (0, typeorm_1.Entity)({ name: 'logistics_foreign_vehicle_passengers' }),
33
+ __metadata("design:paramtypes", [Number, String])
34
+ ], LogisticsForeignVehiclePassengers);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@platform-modules/civil-aviation-authority",
3
- "version": "2.0.6",
3
+ "version": "2.0.7",
4
4
  "main": "dist/index.js",
5
5
  "types": "dist/index.d.ts",
6
6
  "scripts": {
@@ -31,6 +31,8 @@ import { Notification } from './models/NotificationModel';
31
31
  import { ITRequestChat } from './models/ITRequestChatModel';
32
32
  import { ITRequestAttachment } from './models/ITRequestAttachmentModel';
33
33
  import { LogisticsRequests } from './models/LogisticsModel';
34
+ import { LogisticsForeignVehicleRequests } from './models/LogisticsForeignVehicleModel';
35
+ import { LogisticsForeignVehiclePassengers } from './models/LogisticsForeignVehiclePassengerModel';
34
36
  import { LogisticsApprovalDetails } from './models/LogisticsApprovalModel';
35
37
  import { LogisticsRequestChat } from './models/LogisticsChatModel';
36
38
  import { LogisticsRequestAttachment } from './models/LogisticsAttachmentModel';
@@ -76,6 +78,8 @@ export const AppDataSource = new DataSource({
76
78
  ITRequestChat,
77
79
  ITRequestAttachment,
78
80
  LogisticsRequests,
81
+ LogisticsForeignVehicleRequests,
82
+ LogisticsForeignVehiclePassengers,
79
83
  LogisticsApprovalDetails,
80
84
  LogisticsRequestChat,
81
85
  LogisticsRequestAttachment,
package/src/index.ts CHANGED
@@ -27,6 +27,8 @@ export * from './models/NotificationModel';
27
27
  export * from './models/ITRequestChatModel';
28
28
  export * from './models/ITRequestAttachmentModel';
29
29
  export * from './models/LogisticsModel';
30
+ export * from './models/LogisticsForeignVehicleModel';
31
+ export * from './models/LogisticsForeignVehiclePassengerModel';
30
32
  export * from './models/LogisticsApprovalModel';
31
33
  export * from './models/LogisticsChatModel';
32
34
  export * from './models/LogisticsAttachmentModel';
@@ -0,0 +1,143 @@
1
+ import { Column, Entity } from "typeorm";
2
+ import { BaseModel } from './BaseModel';
3
+
4
+ export enum Foreign_Purpose_of_Travel {
5
+ AIRPORT_PICKUP = "Airport Pickup/Drop-off",
6
+ OFFICIAL_MEETING = "Official Meeting",
7
+ SITE_VISIT = "Site Visit",
8
+ CONFERENCE = "Conference/Event",
9
+ OTHER = "Other"
10
+ }
11
+
12
+ export enum Foreign_Vehicle_Required_Location {
13
+ INSIDE = "Inside Muscat",
14
+ OUTSIDE = "Outside Muscat"
15
+ }
16
+
17
+ export enum Foreign_Request_Type {
18
+ NEW_REQUEST = "New Request",
19
+ EXTENSION = "Extension of Previous Request"
20
+ }
21
+
22
+ export enum Foreign_Request_Status {
23
+ PENDING = "Pending",
24
+ ASSIGNED = "Assigned",
25
+ IN_PROGRESS = "In Progress",
26
+ APPROVED = "Approved",
27
+ REJECTED = "Rejected"
28
+ }
29
+
30
+ @Entity({ name: 'logistics_foreign_vehicle_requests' })
31
+ export class LogisticsForeignVehicleRequests extends BaseModel {
32
+
33
+ @Column({ type: 'int', nullable: true })
34
+ req_user_department_id: number | null;
35
+
36
+ @Column({ type: 'int', nullable: true })
37
+ req_user_section_id: number | null;
38
+
39
+ @Column({ nullable: true })
40
+ service_id: number;
41
+
42
+ @Column({ nullable: true })
43
+ sub_service_id: number;
44
+
45
+ @Column({ nullable: false })
46
+ user_id: number;
47
+
48
+ @Column({ type: 'int', nullable: false })
49
+ number_of_passengers: number;
50
+
51
+ @Column({
52
+ type: "enum",
53
+ enum: Foreign_Purpose_of_Travel,
54
+ default: Foreign_Purpose_of_Travel.OTHER,
55
+ nullable: false,
56
+ })
57
+ purpose_of_travel: Foreign_Purpose_of_Travel;
58
+
59
+ @Column({
60
+ type: "enum",
61
+ enum: Foreign_Vehicle_Required_Location,
62
+ default: Foreign_Vehicle_Required_Location.INSIDE,
63
+ nullable: false,
64
+ })
65
+ vehicle_required_location: Foreign_Vehicle_Required_Location;
66
+
67
+ @Column({ type: 'varchar', length: 100, nullable: true })
68
+ employee_id_passport: string | null;
69
+
70
+ @Column({ type: 'varchar', length: 20, nullable: false })
71
+ contact_number: string;
72
+
73
+ @Column({
74
+ type: "enum",
75
+ enum: Foreign_Request_Type,
76
+ default: Foreign_Request_Type.NEW_REQUEST,
77
+ nullable: false,
78
+ })
79
+ request_type: Foreign_Request_Type;
80
+
81
+ @Column({ type: 'varchar', length: 255, nullable: true })
82
+ origin_city: string | null;
83
+
84
+ @Column({ type: 'varchar', length: 255, nullable: false })
85
+ destination_city: string;
86
+
87
+ @Column({ type: 'timestamp', nullable: false })
88
+ arrival_departure_datetime: Date;
89
+
90
+ @Column({ type: 'text', nullable: true })
91
+ special_instructions: string | null;
92
+
93
+ @Column({
94
+ type: "enum",
95
+ enum: Foreign_Request_Status,
96
+ default: Foreign_Request_Status.PENDING,
97
+ nullable: false,
98
+ })
99
+ status: Foreign_Request_Status;
100
+
101
+ @Column({ type: "varchar", nullable: true })
102
+ workflow_execution_id: string | null;
103
+
104
+ constructor(
105
+ req_user_department_id: number | null,
106
+ req_user_section_id: number | null,
107
+ service_id: number,
108
+ sub_service_id: number,
109
+ user_id: number,
110
+ number_of_passengers: number,
111
+ purpose_of_travel: Foreign_Purpose_of_Travel,
112
+ vehicle_required_location: Foreign_Vehicle_Required_Location,
113
+ contact_number: string,
114
+ request_type: Foreign_Request_Type,
115
+ destination_city: string,
116
+ arrival_departure_datetime: Date,
117
+ status: Foreign_Request_Status,
118
+ employee_id_passport?: string | null,
119
+ origin_city?: string | null,
120
+ special_instructions?: string | null,
121
+ workflow_execution_id?: string | null,
122
+ ) {
123
+ super();
124
+ this.req_user_department_id = req_user_department_id ?? null;
125
+ this.req_user_section_id = req_user_section_id ?? null;
126
+ this.service_id = service_id;
127
+ this.sub_service_id = sub_service_id;
128
+ this.user_id = user_id;
129
+ this.number_of_passengers = number_of_passengers;
130
+ this.purpose_of_travel = purpose_of_travel;
131
+ this.vehicle_required_location = vehicle_required_location;
132
+ this.employee_id_passport = employee_id_passport ?? null;
133
+ this.contact_number = contact_number;
134
+ this.request_type = request_type;
135
+ this.origin_city = origin_city ?? null;
136
+ this.destination_city = destination_city;
137
+ this.arrival_departure_datetime = arrival_departure_datetime;
138
+ this.special_instructions = special_instructions ?? null;
139
+ this.status = status;
140
+ this.workflow_execution_id = workflow_execution_id ?? null;
141
+ }
142
+ }
143
+
@@ -0,0 +1,23 @@
1
+ import { Column, Entity } from "typeorm";
2
+ import { BaseModel } from './BaseModel';
3
+
4
+ @Entity({ name: 'logistics_foreign_vehicle_passengers' })
5
+ export class LogisticsForeignVehiclePassengers extends BaseModel {
6
+
7
+ @Column({ type: 'integer', nullable: false })
8
+ foreign_vehicle_request_id: number;
9
+
10
+ @Column({ type: 'varchar', length: 255, nullable: false })
11
+ passenger_name: string;
12
+
13
+
14
+ constructor(
15
+ foreign_vehicle_request_id: number,
16
+ passenger_name: string,
17
+ ) {
18
+ super();
19
+ this.foreign_vehicle_request_id = foreign_vehicle_request_id;
20
+ this.passenger_name = passenger_name;
21
+ }
22
+ }
23
+