@platform-modules/civil-aviation-authority 2.0.7 → 2.0.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.env +10 -10
- package/dist/models/LogisticsModel.d.ts +7 -2
- package/dist/models/LogisticsModel.js +20 -5
- package/package.json +1 -1
- package/src/models/LogisticsModel.ts +18 -3
package/.env
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
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
|
|
@@ -29,18 +29,23 @@ export declare enum Type_of_Vehicle {
|
|
|
29
29
|
SEDAN = "Sedan",
|
|
30
30
|
SUV = "SUV"
|
|
31
31
|
}
|
|
32
|
+
export declare enum Type_of_Request {
|
|
33
|
+
NEW_REQUEST = "New Request",
|
|
34
|
+
EXTENSION = "Extension of Previous Request"
|
|
35
|
+
}
|
|
32
36
|
export declare class LogisticsRequests extends BaseModel {
|
|
33
37
|
req_user_department_id: number | null;
|
|
34
38
|
req_user_section_id: number | null;
|
|
35
39
|
service_id: number;
|
|
36
40
|
sub_service_id: number;
|
|
37
41
|
user_id: number;
|
|
38
|
-
|
|
42
|
+
category: Request_Type;
|
|
39
43
|
vehicle_required_for: Vehicle_Required_For;
|
|
40
44
|
vehicle_required_location: Vehicle_Required_Location;
|
|
41
45
|
title: string;
|
|
42
46
|
purpose_of_travel: Purpose_of_Travel;
|
|
43
47
|
type_of_vehicle_required: Type_of_Vehicle;
|
|
48
|
+
type_of_request: Type_of_Request;
|
|
44
49
|
date_of_travel: Date;
|
|
45
50
|
time_of_travel: string;
|
|
46
51
|
exp_duration_of_use_hrs: number;
|
|
@@ -48,5 +53,5 @@ export declare class LogisticsRequests extends BaseModel {
|
|
|
48
53
|
description: string;
|
|
49
54
|
status: Status;
|
|
50
55
|
workflow_execution_id: string | null;
|
|
51
|
-
constructor(req_user_department_id: number | null, req_user_section_id: number | null, service_id: number, sub_service_id: number, user_id: number,
|
|
56
|
+
constructor(req_user_department_id: number | null, req_user_section_id: number | null, service_id: number, sub_service_id: number, user_id: number, category: Request_Type, vehicle_required_for: Vehicle_Required_For, vehicle_required_location: Vehicle_Required_Location, title: string, purpose_of_travel: Purpose_of_Travel, type_of_vehicle_required: Type_of_Vehicle, type_of_request: Type_of_Request, date_of_travel: Date, time_of_travel: string, exp_duration_of_use_hrs: number, exp_duration_of_use_days: number, description: string, status: Status, workflow_execution_id?: string | null);
|
|
52
57
|
}
|
|
@@ -9,7 +9,7 @@ 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.LogisticsRequests = exports.Type_of_Vehicle = exports.Purpose_of_Travel = exports.Vehicle_Required_Location = exports.Vehicle_Required_For = exports.Status = exports.Request_Type = void 0;
|
|
12
|
+
exports.LogisticsRequests = exports.Type_of_Request = exports.Type_of_Vehicle = exports.Purpose_of_Travel = exports.Vehicle_Required_Location = exports.Vehicle_Required_For = exports.Status = exports.Request_Type = void 0;
|
|
13
13
|
const typeorm_1 = require("typeorm");
|
|
14
14
|
const BaseModel_1 = require("./BaseModel");
|
|
15
15
|
var Request_Type;
|
|
@@ -48,20 +48,26 @@ var Type_of_Vehicle;
|
|
|
48
48
|
Type_of_Vehicle["SEDAN"] = "Sedan";
|
|
49
49
|
Type_of_Vehicle["SUV"] = "SUV";
|
|
50
50
|
})(Type_of_Vehicle || (exports.Type_of_Vehicle = Type_of_Vehicle = {}));
|
|
51
|
+
var Type_of_Request;
|
|
52
|
+
(function (Type_of_Request) {
|
|
53
|
+
Type_of_Request["NEW_REQUEST"] = "New Request";
|
|
54
|
+
Type_of_Request["EXTENSION"] = "Extension of Previous Request";
|
|
55
|
+
})(Type_of_Request || (exports.Type_of_Request = Type_of_Request = {}));
|
|
51
56
|
let LogisticsRequests = class LogisticsRequests extends BaseModel_1.BaseModel {
|
|
52
|
-
constructor(req_user_department_id, req_user_section_id, service_id, sub_service_id, user_id,
|
|
57
|
+
constructor(req_user_department_id, req_user_section_id, service_id, sub_service_id, user_id, category, vehicle_required_for, vehicle_required_location, title, purpose_of_travel, type_of_vehicle_required, type_of_request, date_of_travel, time_of_travel, exp_duration_of_use_hrs, exp_duration_of_use_days, description, status, workflow_execution_id) {
|
|
53
58
|
super();
|
|
54
59
|
this.req_user_department_id = req_user_department_id ?? null;
|
|
55
60
|
this.req_user_section_id = req_user_section_id ?? null;
|
|
56
61
|
this.service_id = service_id;
|
|
57
62
|
this.sub_service_id = sub_service_id;
|
|
58
63
|
this.user_id = user_id;
|
|
59
|
-
this.
|
|
64
|
+
this.category = category;
|
|
60
65
|
this.vehicle_required_for = vehicle_required_for;
|
|
61
66
|
this.vehicle_required_location = vehicle_required_location;
|
|
62
67
|
this.title = title;
|
|
63
68
|
this.purpose_of_travel = purpose_of_travel;
|
|
64
69
|
this.type_of_vehicle_required = type_of_vehicle_required;
|
|
70
|
+
this.type_of_request = type_of_request;
|
|
65
71
|
this.date_of_travel = date_of_travel;
|
|
66
72
|
this.time_of_travel = time_of_travel;
|
|
67
73
|
this.exp_duration_of_use_hrs = exp_duration_of_use_hrs;
|
|
@@ -100,7 +106,7 @@ __decorate([
|
|
|
100
106
|
nullable: false,
|
|
101
107
|
}),
|
|
102
108
|
__metadata("design:type", String)
|
|
103
|
-
], LogisticsRequests.prototype, "
|
|
109
|
+
], LogisticsRequests.prototype, "category", void 0);
|
|
104
110
|
__decorate([
|
|
105
111
|
(0, typeorm_1.Column)({
|
|
106
112
|
type: "enum",
|
|
@@ -141,6 +147,15 @@ __decorate([
|
|
|
141
147
|
}),
|
|
142
148
|
__metadata("design:type", String)
|
|
143
149
|
], LogisticsRequests.prototype, "type_of_vehicle_required", void 0);
|
|
150
|
+
__decorate([
|
|
151
|
+
(0, typeorm_1.Column)({
|
|
152
|
+
type: "enum",
|
|
153
|
+
enum: Type_of_Request,
|
|
154
|
+
default: Type_of_Request.NEW_REQUEST,
|
|
155
|
+
nullable: false,
|
|
156
|
+
}),
|
|
157
|
+
__metadata("design:type", String)
|
|
158
|
+
], LogisticsRequests.prototype, "type_of_request", void 0);
|
|
144
159
|
__decorate([
|
|
145
160
|
(0, typeorm_1.Column)({ type: "date", nullable: false }),
|
|
146
161
|
__metadata("design:type", Date)
|
|
@@ -176,5 +191,5 @@ __decorate([
|
|
|
176
191
|
], LogisticsRequests.prototype, "workflow_execution_id", void 0);
|
|
177
192
|
exports.LogisticsRequests = LogisticsRequests = __decorate([
|
|
178
193
|
(0, typeorm_1.Entity)({ name: 'logistics_requests' }),
|
|
179
|
-
__metadata("design:paramtypes", [Object, Object, Number, Number, Number, String, String, String, String, String, String, Date, String, Number, Number, String, String, Object])
|
|
194
|
+
__metadata("design:paramtypes", [Object, Object, Number, Number, Number, String, String, String, String, String, String, String, Date, String, Number, Number, String, String, Object])
|
|
180
195
|
], LogisticsRequests);
|
package/package.json
CHANGED
|
@@ -37,6 +37,11 @@ export enum Type_of_Vehicle {
|
|
|
37
37
|
SUV = "SUV"
|
|
38
38
|
}
|
|
39
39
|
|
|
40
|
+
export enum Type_of_Request {
|
|
41
|
+
NEW_REQUEST = "New Request",
|
|
42
|
+
EXTENSION = "Extension of Previous Request"
|
|
43
|
+
}
|
|
44
|
+
|
|
40
45
|
@Entity({ name: 'logistics_requests' })
|
|
41
46
|
export class LogisticsRequests extends BaseModel {
|
|
42
47
|
|
|
@@ -61,7 +66,7 @@ export class LogisticsRequests extends BaseModel {
|
|
|
61
66
|
default: Request_Type.DAILY,
|
|
62
67
|
nullable: false,
|
|
63
68
|
})
|
|
64
|
-
|
|
69
|
+
category: Request_Type;
|
|
65
70
|
|
|
66
71
|
@Column({
|
|
67
72
|
type: "enum",
|
|
@@ -98,6 +103,14 @@ export class LogisticsRequests extends BaseModel {
|
|
|
98
103
|
})
|
|
99
104
|
type_of_vehicle_required: Type_of_Vehicle;
|
|
100
105
|
|
|
106
|
+
@Column({
|
|
107
|
+
type: "enum",
|
|
108
|
+
enum: Type_of_Request,
|
|
109
|
+
default: Type_of_Request.NEW_REQUEST,
|
|
110
|
+
nullable: false,
|
|
111
|
+
})
|
|
112
|
+
type_of_request: Type_of_Request;
|
|
113
|
+
|
|
101
114
|
@Column({ type: "date", nullable: false })
|
|
102
115
|
date_of_travel: Date;
|
|
103
116
|
|
|
@@ -130,12 +143,13 @@ export class LogisticsRequests extends BaseModel {
|
|
|
130
143
|
service_id: number,
|
|
131
144
|
sub_service_id: number,
|
|
132
145
|
user_id: number,
|
|
133
|
-
|
|
146
|
+
category: Request_Type,
|
|
134
147
|
vehicle_required_for: Vehicle_Required_For,
|
|
135
148
|
vehicle_required_location: Vehicle_Required_Location,
|
|
136
149
|
title: string,
|
|
137
150
|
purpose_of_travel: Purpose_of_Travel,
|
|
138
151
|
type_of_vehicle_required: Type_of_Vehicle,
|
|
152
|
+
type_of_request: Type_of_Request,
|
|
139
153
|
date_of_travel: Date,
|
|
140
154
|
time_of_travel: string,
|
|
141
155
|
exp_duration_of_use_hrs: number,
|
|
@@ -150,12 +164,13 @@ export class LogisticsRequests extends BaseModel {
|
|
|
150
164
|
this.service_id = service_id;
|
|
151
165
|
this.sub_service_id = sub_service_id;
|
|
152
166
|
this.user_id = user_id;
|
|
153
|
-
this.
|
|
167
|
+
this.category = category;
|
|
154
168
|
this.vehicle_required_for = vehicle_required_for;
|
|
155
169
|
this.vehicle_required_location = vehicle_required_location;
|
|
156
170
|
this.title = title;
|
|
157
171
|
this.purpose_of_travel = purpose_of_travel;
|
|
158
172
|
this.type_of_vehicle_required = type_of_vehicle_required;
|
|
173
|
+
this.type_of_request = type_of_request;
|
|
159
174
|
this.date_of_travel = date_of_travel;
|
|
160
175
|
this.time_of_travel = time_of_travel;
|
|
161
176
|
this.exp_duration_of_use_hrs = exp_duration_of_use_hrs;
|