@tmlmobilidade/types 20250915.1331.9 → 20250915.1643.34
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/src/_common/comment.d.ts +181 -27
- package/dist/src/_common/comment.js +27 -5
- package/dist/src/file.d.ts +7 -7
- package/dist/src/rides/ride-audit.d.ts +15 -0
- package/dist/src/rides/ride-justification.d.ts +159 -475
- package/dist/src/rides/ride-justification.js +4 -22
- package/dist/src/stop.d.ts +147 -63
- package/package.json +1 -1
|
@@ -8,222 +8,9 @@ export type RideJustificationCause = z.infer<typeof RideJustificationCauseSchema
|
|
|
8
8
|
export declare const RIDE_JUSTIFICATION_SOURCE_OPTIONS: readonly ["MANUAL", "REALTIME_ALERT"];
|
|
9
9
|
export declare const RideJustificationSourceSchema: z.ZodEnum<["MANUAL", "REALTIME_ALERT"]>;
|
|
10
10
|
export type RideJustificationSource = z.infer<typeof RideJustificationSourceSchema>;
|
|
11
|
-
declare const
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
created_by: z.ZodOptional<z.ZodString>;
|
|
15
|
-
updated_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
16
|
-
updated_by: z.ZodOptional<z.ZodString>;
|
|
17
|
-
} & {
|
|
18
|
-
message: z.ZodString;
|
|
19
|
-
type: z.ZodLiteral<"note">;
|
|
20
|
-
}, "strip", z.ZodTypeAny, {
|
|
21
|
-
_id: string;
|
|
22
|
-
created_at: number & {
|
|
23
|
-
__brand: "UnixTimestamp";
|
|
24
|
-
};
|
|
25
|
-
updated_at: number & {
|
|
26
|
-
__brand: "UnixTimestamp";
|
|
27
|
-
};
|
|
28
|
-
message: string;
|
|
29
|
-
type: "note";
|
|
30
|
-
created_by?: string | undefined;
|
|
31
|
-
updated_by?: string | undefined;
|
|
32
|
-
}, {
|
|
33
|
-
_id: string;
|
|
34
|
-
created_at: number;
|
|
35
|
-
updated_at: number;
|
|
36
|
-
message: string;
|
|
37
|
-
type: "note";
|
|
38
|
-
created_by?: string | undefined;
|
|
39
|
-
updated_by?: string | undefined;
|
|
40
|
-
}>, z.ZodObject<{
|
|
41
|
-
_id: z.ZodString;
|
|
42
|
-
created_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
43
|
-
updated_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
44
|
-
} & {
|
|
45
|
-
created_by: z.ZodLiteral<"system">;
|
|
46
|
-
message: z.ZodString;
|
|
47
|
-
type: z.ZodLiteral<"system_info">;
|
|
48
|
-
updated_by: z.ZodLiteral<"system">;
|
|
49
|
-
}, "strip", z.ZodTypeAny, {
|
|
50
|
-
_id: string;
|
|
51
|
-
created_at: number & {
|
|
52
|
-
__brand: "UnixTimestamp";
|
|
53
|
-
};
|
|
54
|
-
created_by: "system";
|
|
55
|
-
updated_at: number & {
|
|
56
|
-
__brand: "UnixTimestamp";
|
|
57
|
-
};
|
|
58
|
-
updated_by: "system";
|
|
59
|
-
message: string;
|
|
60
|
-
type: "system_info";
|
|
61
|
-
}, {
|
|
62
|
-
_id: string;
|
|
63
|
-
created_at: number;
|
|
64
|
-
created_by: "system";
|
|
65
|
-
updated_at: number;
|
|
66
|
-
updated_by: "system";
|
|
67
|
-
message: string;
|
|
68
|
-
type: "system_info";
|
|
69
|
-
}>, z.ZodObject<{
|
|
70
|
-
_id: z.ZodString;
|
|
71
|
-
created_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
72
|
-
created_by: z.ZodOptional<z.ZodString>;
|
|
73
|
-
updated_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
74
|
-
updated_by: z.ZodOptional<z.ZodString>;
|
|
75
|
-
} & {
|
|
76
|
-
curr_status: z.ZodString;
|
|
77
|
-
prev_status: z.ZodString;
|
|
78
|
-
type: z.ZodLiteral<"statusChanged">;
|
|
79
|
-
}, "strip", z.ZodTypeAny, {
|
|
80
|
-
_id: string;
|
|
81
|
-
created_at: number & {
|
|
82
|
-
__brand: "UnixTimestamp";
|
|
83
|
-
};
|
|
84
|
-
updated_at: number & {
|
|
85
|
-
__brand: "UnixTimestamp";
|
|
86
|
-
};
|
|
87
|
-
type: "statusChanged";
|
|
88
|
-
curr_status: string;
|
|
89
|
-
prev_status: string;
|
|
90
|
-
created_by?: string | undefined;
|
|
91
|
-
updated_by?: string | undefined;
|
|
92
|
-
}, {
|
|
93
|
-
_id: string;
|
|
94
|
-
created_at: number;
|
|
95
|
-
updated_at: number;
|
|
96
|
-
type: "statusChanged";
|
|
97
|
-
curr_status: string;
|
|
98
|
-
prev_status: string;
|
|
99
|
-
created_by?: string | undefined;
|
|
100
|
-
updated_by?: string | undefined;
|
|
101
|
-
}>]>, {
|
|
102
|
-
_id: string;
|
|
103
|
-
created_at: number & {
|
|
104
|
-
__brand: "UnixTimestamp";
|
|
105
|
-
};
|
|
106
|
-
updated_at: number & {
|
|
107
|
-
__brand: "UnixTimestamp";
|
|
108
|
-
};
|
|
109
|
-
message: string;
|
|
110
|
-
type: "note";
|
|
111
|
-
created_by?: string | undefined;
|
|
112
|
-
updated_by?: string | undefined;
|
|
113
|
-
} | {
|
|
114
|
-
_id: string;
|
|
115
|
-
created_at: number & {
|
|
116
|
-
__brand: "UnixTimestamp";
|
|
117
|
-
};
|
|
118
|
-
created_by: "system";
|
|
119
|
-
updated_at: number & {
|
|
120
|
-
__brand: "UnixTimestamp";
|
|
121
|
-
};
|
|
122
|
-
updated_by: "system";
|
|
123
|
-
message: string;
|
|
124
|
-
type: "system_info";
|
|
125
|
-
} | {
|
|
126
|
-
_id: string;
|
|
127
|
-
created_at: number & {
|
|
128
|
-
__brand: "UnixTimestamp";
|
|
129
|
-
};
|
|
130
|
-
updated_at: number & {
|
|
131
|
-
__brand: "UnixTimestamp";
|
|
132
|
-
};
|
|
133
|
-
type: "statusChanged";
|
|
134
|
-
curr_status: string;
|
|
135
|
-
prev_status: string;
|
|
136
|
-
created_by?: string | undefined;
|
|
137
|
-
updated_by?: string | undefined;
|
|
138
|
-
}, {
|
|
139
|
-
_id: string;
|
|
140
|
-
created_at: number;
|
|
141
|
-
updated_at: number;
|
|
142
|
-
message: string;
|
|
143
|
-
type: "note";
|
|
144
|
-
created_by?: string | undefined;
|
|
145
|
-
updated_by?: string | undefined;
|
|
146
|
-
} | {
|
|
147
|
-
_id: string;
|
|
148
|
-
created_at: number;
|
|
149
|
-
created_by: "system";
|
|
150
|
-
updated_at: number;
|
|
151
|
-
updated_by: "system";
|
|
152
|
-
message: string;
|
|
153
|
-
type: "system_info";
|
|
154
|
-
} | {
|
|
155
|
-
_id: string;
|
|
156
|
-
created_at: number;
|
|
157
|
-
updated_at: number;
|
|
158
|
-
type: "statusChanged";
|
|
159
|
-
curr_status: string;
|
|
160
|
-
prev_status: string;
|
|
161
|
-
created_by?: string | undefined;
|
|
162
|
-
updated_by?: string | undefined;
|
|
163
|
-
}>, {
|
|
164
|
-
_id: string;
|
|
165
|
-
created_at: number & {
|
|
166
|
-
__brand: "UnixTimestamp";
|
|
167
|
-
};
|
|
168
|
-
updated_at: number & {
|
|
169
|
-
__brand: "UnixTimestamp";
|
|
170
|
-
};
|
|
171
|
-
message: string;
|
|
172
|
-
type: "note";
|
|
173
|
-
created_by?: string | undefined;
|
|
174
|
-
updated_by?: string | undefined;
|
|
175
|
-
} | {
|
|
176
|
-
_id: string;
|
|
177
|
-
created_at: number & {
|
|
178
|
-
__brand: "UnixTimestamp";
|
|
179
|
-
};
|
|
180
|
-
created_by: "system";
|
|
181
|
-
updated_at: number & {
|
|
182
|
-
__brand: "UnixTimestamp";
|
|
183
|
-
};
|
|
184
|
-
updated_by: "system";
|
|
185
|
-
message: string;
|
|
186
|
-
type: "system_info";
|
|
187
|
-
} | {
|
|
188
|
-
_id: string;
|
|
189
|
-
created_at: number & {
|
|
190
|
-
__brand: "UnixTimestamp";
|
|
191
|
-
};
|
|
192
|
-
updated_at: number & {
|
|
193
|
-
__brand: "UnixTimestamp";
|
|
194
|
-
};
|
|
195
|
-
type: "statusChanged";
|
|
196
|
-
curr_status: string;
|
|
197
|
-
prev_status: string;
|
|
198
|
-
created_by?: string | undefined;
|
|
199
|
-
updated_by?: string | undefined;
|
|
200
|
-
}, {
|
|
201
|
-
_id: string;
|
|
202
|
-
created_at: number;
|
|
203
|
-
updated_at: number;
|
|
204
|
-
message: string;
|
|
205
|
-
type: "note";
|
|
206
|
-
created_by?: string | undefined;
|
|
207
|
-
updated_by?: string | undefined;
|
|
208
|
-
} | {
|
|
209
|
-
_id: string;
|
|
210
|
-
created_at: number;
|
|
211
|
-
created_by: "system";
|
|
212
|
-
updated_at: number;
|
|
213
|
-
updated_by: "system";
|
|
214
|
-
message: string;
|
|
215
|
-
type: "system_info";
|
|
216
|
-
} | {
|
|
217
|
-
_id: string;
|
|
218
|
-
created_at: number;
|
|
219
|
-
updated_at: number;
|
|
220
|
-
type: "statusChanged";
|
|
221
|
-
curr_status: string;
|
|
222
|
-
prev_status: string;
|
|
223
|
-
created_by?: string | undefined;
|
|
224
|
-
updated_by?: string | undefined;
|
|
225
|
-
}>;
|
|
226
|
-
export type RideJustificationComment = z.infer<typeof CommentSchemaWithRideJustificationStatus>;
|
|
11
|
+
export declare const RIDE_JUSTIFICATION_STATUS_TYPE_OPTIONS: readonly ["locked_status", "acceptance_status", "pto_message"];
|
|
12
|
+
export declare const RideJustificationStatusTypeSchema: z.ZodEnum<["locked_status", "acceptance_status", "pto_message"]>;
|
|
13
|
+
export type RideJustificationStatusType = z.infer<typeof RideJustificationStatusTypeSchema>;
|
|
227
14
|
export declare const RideJustificationSchema: z.ZodObject<{
|
|
228
15
|
_id: z.ZodString;
|
|
229
16
|
created_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
@@ -245,7 +32,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
245
32
|
reason: string;
|
|
246
33
|
error_message?: string | undefined;
|
|
247
34
|
}>;
|
|
248
|
-
comments: z.ZodDefault<z.ZodArray<z.ZodEffects<z.
|
|
35
|
+
comments: z.ZodDefault<z.ZodArray<z.ZodEffects<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
249
36
|
_id: z.ZodString;
|
|
250
37
|
created_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
251
38
|
created_by: z.ZodOptional<z.ZodString>;
|
|
@@ -253,6 +40,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
253
40
|
updated_by: z.ZodOptional<z.ZodString>;
|
|
254
41
|
} & {
|
|
255
42
|
message: z.ZodString;
|
|
43
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
256
44
|
type: z.ZodLiteral<"note">;
|
|
257
45
|
}, "strip", z.ZodTypeAny, {
|
|
258
46
|
_id: string;
|
|
@@ -266,6 +54,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
266
54
|
type: "note";
|
|
267
55
|
created_by?: string | undefined;
|
|
268
56
|
updated_by?: string | undefined;
|
|
57
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
269
58
|
}, {
|
|
270
59
|
_id: string;
|
|
271
60
|
created_at: number;
|
|
@@ -274,6 +63,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
274
63
|
type: "note";
|
|
275
64
|
created_by?: string | undefined;
|
|
276
65
|
updated_by?: string | undefined;
|
|
66
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
277
67
|
}>, z.ZodObject<{
|
|
278
68
|
_id: z.ZodString;
|
|
279
69
|
created_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
@@ -281,6 +71,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
281
71
|
} & {
|
|
282
72
|
created_by: z.ZodLiteral<"system">;
|
|
283
73
|
message: z.ZodString;
|
|
74
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
284
75
|
type: z.ZodLiteral<"system_info">;
|
|
285
76
|
updated_by: z.ZodLiteral<"system">;
|
|
286
77
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -295,6 +86,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
295
86
|
updated_by: "system";
|
|
296
87
|
message: string;
|
|
297
88
|
type: "system_info";
|
|
89
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
298
90
|
}, {
|
|
299
91
|
_id: string;
|
|
300
92
|
created_at: number;
|
|
@@ -303,6 +95,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
303
95
|
updated_by: "system";
|
|
304
96
|
message: string;
|
|
305
97
|
type: "system_info";
|
|
98
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
306
99
|
}>, z.ZodObject<{
|
|
307
100
|
_id: z.ZodString;
|
|
308
101
|
created_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
@@ -310,9 +103,11 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
310
103
|
updated_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
311
104
|
updated_by: z.ZodOptional<z.ZodString>;
|
|
312
105
|
} & {
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
106
|
+
accessor: z.ZodString;
|
|
107
|
+
curr_status: z.ZodUnion<[z.ZodString, z.ZodBoolean]>;
|
|
108
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
109
|
+
prev_status: z.ZodUnion<[z.ZodString, z.ZodBoolean]>;
|
|
110
|
+
type: z.ZodLiteral<"status_changed">;
|
|
316
111
|
}, "strip", z.ZodTypeAny, {
|
|
317
112
|
_id: string;
|
|
318
113
|
created_at: number & {
|
|
@@ -321,20 +116,24 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
321
116
|
updated_at: number & {
|
|
322
117
|
__brand: "UnixTimestamp";
|
|
323
118
|
};
|
|
324
|
-
type: "
|
|
325
|
-
|
|
326
|
-
|
|
119
|
+
type: "status_changed";
|
|
120
|
+
accessor: string;
|
|
121
|
+
curr_status: string | boolean;
|
|
122
|
+
prev_status: string | boolean;
|
|
327
123
|
created_by?: string | undefined;
|
|
328
124
|
updated_by?: string | undefined;
|
|
125
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
329
126
|
}, {
|
|
330
127
|
_id: string;
|
|
331
128
|
created_at: number;
|
|
332
129
|
updated_at: number;
|
|
333
|
-
type: "
|
|
334
|
-
|
|
335
|
-
|
|
130
|
+
type: "status_changed";
|
|
131
|
+
accessor: string;
|
|
132
|
+
curr_status: string | boolean;
|
|
133
|
+
prev_status: string | boolean;
|
|
336
134
|
created_by?: string | undefined;
|
|
337
135
|
updated_by?: string | undefined;
|
|
136
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
338
137
|
}>]>, {
|
|
339
138
|
_id: string;
|
|
340
139
|
created_at: number & {
|
|
@@ -347,6 +146,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
347
146
|
type: "note";
|
|
348
147
|
created_by?: string | undefined;
|
|
349
148
|
updated_by?: string | undefined;
|
|
149
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
350
150
|
} | {
|
|
351
151
|
_id: string;
|
|
352
152
|
created_at: number & {
|
|
@@ -359,6 +159,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
359
159
|
updated_by: "system";
|
|
360
160
|
message: string;
|
|
361
161
|
type: "system_info";
|
|
162
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
362
163
|
} | {
|
|
363
164
|
_id: string;
|
|
364
165
|
created_at: number & {
|
|
@@ -367,11 +168,13 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
367
168
|
updated_at: number & {
|
|
368
169
|
__brand: "UnixTimestamp";
|
|
369
170
|
};
|
|
370
|
-
type: "
|
|
371
|
-
|
|
372
|
-
|
|
171
|
+
type: "status_changed";
|
|
172
|
+
accessor: string;
|
|
173
|
+
curr_status: string | boolean;
|
|
174
|
+
prev_status: string | boolean;
|
|
373
175
|
created_by?: string | undefined;
|
|
374
176
|
updated_by?: string | undefined;
|
|
177
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
375
178
|
}, {
|
|
376
179
|
_id: string;
|
|
377
180
|
created_at: number;
|
|
@@ -380,6 +183,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
380
183
|
type: "note";
|
|
381
184
|
created_by?: string | undefined;
|
|
382
185
|
updated_by?: string | undefined;
|
|
186
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
383
187
|
} | {
|
|
384
188
|
_id: string;
|
|
385
189
|
created_at: number;
|
|
@@ -388,77 +192,18 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
388
192
|
updated_by: "system";
|
|
389
193
|
message: string;
|
|
390
194
|
type: "system_info";
|
|
195
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
391
196
|
} | {
|
|
392
197
|
_id: string;
|
|
393
198
|
created_at: number;
|
|
394
199
|
updated_at: number;
|
|
395
|
-
type: "
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
updated_by?: string | undefined;
|
|
400
|
-
}>, {
|
|
401
|
-
_id: string;
|
|
402
|
-
created_at: number & {
|
|
403
|
-
__brand: "UnixTimestamp";
|
|
404
|
-
};
|
|
405
|
-
updated_at: number & {
|
|
406
|
-
__brand: "UnixTimestamp";
|
|
407
|
-
};
|
|
408
|
-
message: string;
|
|
409
|
-
type: "note";
|
|
410
|
-
created_by?: string | undefined;
|
|
411
|
-
updated_by?: string | undefined;
|
|
412
|
-
} | {
|
|
413
|
-
_id: string;
|
|
414
|
-
created_at: number & {
|
|
415
|
-
__brand: "UnixTimestamp";
|
|
416
|
-
};
|
|
417
|
-
created_by: "system";
|
|
418
|
-
updated_at: number & {
|
|
419
|
-
__brand: "UnixTimestamp";
|
|
420
|
-
};
|
|
421
|
-
updated_by: "system";
|
|
422
|
-
message: string;
|
|
423
|
-
type: "system_info";
|
|
424
|
-
} | {
|
|
425
|
-
_id: string;
|
|
426
|
-
created_at: number & {
|
|
427
|
-
__brand: "UnixTimestamp";
|
|
428
|
-
};
|
|
429
|
-
updated_at: number & {
|
|
430
|
-
__brand: "UnixTimestamp";
|
|
431
|
-
};
|
|
432
|
-
type: "statusChanged";
|
|
433
|
-
curr_status: string;
|
|
434
|
-
prev_status: string;
|
|
435
|
-
created_by?: string | undefined;
|
|
436
|
-
updated_by?: string | undefined;
|
|
437
|
-
}, {
|
|
438
|
-
_id: string;
|
|
439
|
-
created_at: number;
|
|
440
|
-
updated_at: number;
|
|
441
|
-
message: string;
|
|
442
|
-
type: "note";
|
|
443
|
-
created_by?: string | undefined;
|
|
444
|
-
updated_by?: string | undefined;
|
|
445
|
-
} | {
|
|
446
|
-
_id: string;
|
|
447
|
-
created_at: number;
|
|
448
|
-
created_by: "system";
|
|
449
|
-
updated_at: number;
|
|
450
|
-
updated_by: "system";
|
|
451
|
-
message: string;
|
|
452
|
-
type: "system_info";
|
|
453
|
-
} | {
|
|
454
|
-
_id: string;
|
|
455
|
-
created_at: number;
|
|
456
|
-
updated_at: number;
|
|
457
|
-
type: "statusChanged";
|
|
458
|
-
curr_status: string;
|
|
459
|
-
prev_status: string;
|
|
200
|
+
type: "status_changed";
|
|
201
|
+
accessor: string;
|
|
202
|
+
curr_status: string | boolean;
|
|
203
|
+
prev_status: string | boolean;
|
|
460
204
|
created_by?: string | undefined;
|
|
461
205
|
updated_by?: string | undefined;
|
|
206
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
462
207
|
}>, "many">>;
|
|
463
208
|
is_locked: z.ZodDefault<z.ZodBoolean>;
|
|
464
209
|
justification_cause: z.ZodEnum<["TECHNICAL_PROBLEM", "DEMONSTRATION", "ACCIDENT", "WEATHER", "CONSTRUCTION", "POLICE_ACTIVITY", "MEDICAL_EMERGENCY", "OTHER_CAUSE"]>;
|
|
@@ -486,6 +231,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
486
231
|
type: "note";
|
|
487
232
|
created_by?: string | undefined;
|
|
488
233
|
updated_by?: string | undefined;
|
|
234
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
489
235
|
} | {
|
|
490
236
|
_id: string;
|
|
491
237
|
created_at: number & {
|
|
@@ -498,6 +244,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
498
244
|
updated_by: "system";
|
|
499
245
|
message: string;
|
|
500
246
|
type: "system_info";
|
|
247
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
501
248
|
} | {
|
|
502
249
|
_id: string;
|
|
503
250
|
created_at: number & {
|
|
@@ -506,13 +253,16 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
506
253
|
updated_at: number & {
|
|
507
254
|
__brand: "UnixTimestamp";
|
|
508
255
|
};
|
|
509
|
-
type: "
|
|
510
|
-
|
|
511
|
-
|
|
256
|
+
type: "status_changed";
|
|
257
|
+
accessor: string;
|
|
258
|
+
curr_status: string | boolean;
|
|
259
|
+
prev_status: string | boolean;
|
|
512
260
|
created_by?: string | undefined;
|
|
513
261
|
updated_by?: string | undefined;
|
|
262
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
514
263
|
})[];
|
|
515
264
|
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
265
|
+
pto_message: string;
|
|
516
266
|
analysis: {
|
|
517
267
|
grade: "error" | "pass" | "fail" | "skip";
|
|
518
268
|
reason: string;
|
|
@@ -520,7 +270,6 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
520
270
|
};
|
|
521
271
|
justification_cause: "ACCIDENT" | "CONSTRUCTION" | "DEMONSTRATION" | "MEDICAL_EMERGENCY" | "OTHER_CAUSE" | "POLICE_ACTIVITY" | "TECHNICAL_PROBLEM" | "WEATHER";
|
|
522
272
|
justification_source: "MANUAL" | "REALTIME_ALERT";
|
|
523
|
-
pto_message: string;
|
|
524
273
|
trip_id: string;
|
|
525
274
|
created_by?: string | undefined;
|
|
526
275
|
updated_by?: string | undefined;
|
|
@@ -548,6 +297,7 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
548
297
|
type: "note";
|
|
549
298
|
created_by?: string | undefined;
|
|
550
299
|
updated_by?: string | undefined;
|
|
300
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
551
301
|
} | {
|
|
552
302
|
_id: string;
|
|
553
303
|
created_at: number;
|
|
@@ -556,15 +306,18 @@ export declare const RideJustificationSchema: z.ZodObject<{
|
|
|
556
306
|
updated_by: "system";
|
|
557
307
|
message: string;
|
|
558
308
|
type: "system_info";
|
|
309
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
559
310
|
} | {
|
|
560
311
|
_id: string;
|
|
561
312
|
created_at: number;
|
|
562
313
|
updated_at: number;
|
|
563
|
-
type: "
|
|
564
|
-
|
|
565
|
-
|
|
314
|
+
type: "status_changed";
|
|
315
|
+
accessor: string;
|
|
316
|
+
curr_status: string | boolean;
|
|
317
|
+
prev_status: string | boolean;
|
|
566
318
|
created_by?: string | undefined;
|
|
567
319
|
updated_by?: string | undefined;
|
|
320
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
568
321
|
})[] | undefined;
|
|
569
322
|
pto_message?: string | undefined;
|
|
570
323
|
}>;
|
|
@@ -575,7 +328,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
575
328
|
updated_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
576
329
|
updated_by: z.ZodOptional<z.ZodString>;
|
|
577
330
|
is_locked: z.ZodDefault<z.ZodBoolean>;
|
|
578
|
-
comments: z.ZodDefault<z.ZodArray<z.ZodEffects<z.
|
|
331
|
+
comments: z.ZodDefault<z.ZodArray<z.ZodEffects<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
579
332
|
_id: z.ZodString;
|
|
580
333
|
created_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
581
334
|
created_by: z.ZodOptional<z.ZodString>;
|
|
@@ -583,6 +336,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
583
336
|
updated_by: z.ZodOptional<z.ZodString>;
|
|
584
337
|
} & {
|
|
585
338
|
message: z.ZodString;
|
|
339
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
586
340
|
type: z.ZodLiteral<"note">;
|
|
587
341
|
}, "strip", z.ZodTypeAny, {
|
|
588
342
|
_id: string;
|
|
@@ -596,6 +350,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
596
350
|
type: "note";
|
|
597
351
|
created_by?: string | undefined;
|
|
598
352
|
updated_by?: string | undefined;
|
|
353
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
599
354
|
}, {
|
|
600
355
|
_id: string;
|
|
601
356
|
created_at: number;
|
|
@@ -604,6 +359,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
604
359
|
type: "note";
|
|
605
360
|
created_by?: string | undefined;
|
|
606
361
|
updated_by?: string | undefined;
|
|
362
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
607
363
|
}>, z.ZodObject<{
|
|
608
364
|
_id: z.ZodString;
|
|
609
365
|
created_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
@@ -611,6 +367,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
611
367
|
} & {
|
|
612
368
|
created_by: z.ZodLiteral<"system">;
|
|
613
369
|
message: z.ZodString;
|
|
370
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
614
371
|
type: z.ZodLiteral<"system_info">;
|
|
615
372
|
updated_by: z.ZodLiteral<"system">;
|
|
616
373
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -625,6 +382,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
625
382
|
updated_by: "system";
|
|
626
383
|
message: string;
|
|
627
384
|
type: "system_info";
|
|
385
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
628
386
|
}, {
|
|
629
387
|
_id: string;
|
|
630
388
|
created_at: number;
|
|
@@ -633,6 +391,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
633
391
|
updated_by: "system";
|
|
634
392
|
message: string;
|
|
635
393
|
type: "system_info";
|
|
394
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
636
395
|
}>, z.ZodObject<{
|
|
637
396
|
_id: z.ZodString;
|
|
638
397
|
created_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
@@ -640,9 +399,11 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
640
399
|
updated_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
641
400
|
updated_by: z.ZodOptional<z.ZodString>;
|
|
642
401
|
} & {
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
402
|
+
accessor: z.ZodString;
|
|
403
|
+
curr_status: z.ZodUnion<[z.ZodString, z.ZodBoolean]>;
|
|
404
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
405
|
+
prev_status: z.ZodUnion<[z.ZodString, z.ZodBoolean]>;
|
|
406
|
+
type: z.ZodLiteral<"status_changed">;
|
|
646
407
|
}, "strip", z.ZodTypeAny, {
|
|
647
408
|
_id: string;
|
|
648
409
|
created_at: number & {
|
|
@@ -651,20 +412,24 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
651
412
|
updated_at: number & {
|
|
652
413
|
__brand: "UnixTimestamp";
|
|
653
414
|
};
|
|
654
|
-
type: "
|
|
655
|
-
|
|
656
|
-
|
|
415
|
+
type: "status_changed";
|
|
416
|
+
accessor: string;
|
|
417
|
+
curr_status: string | boolean;
|
|
418
|
+
prev_status: string | boolean;
|
|
657
419
|
created_by?: string | undefined;
|
|
658
420
|
updated_by?: string | undefined;
|
|
421
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
659
422
|
}, {
|
|
660
423
|
_id: string;
|
|
661
424
|
created_at: number;
|
|
662
425
|
updated_at: number;
|
|
663
|
-
type: "
|
|
664
|
-
|
|
665
|
-
|
|
426
|
+
type: "status_changed";
|
|
427
|
+
accessor: string;
|
|
428
|
+
curr_status: string | boolean;
|
|
429
|
+
prev_status: string | boolean;
|
|
666
430
|
created_by?: string | undefined;
|
|
667
431
|
updated_by?: string | undefined;
|
|
432
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
668
433
|
}>]>, {
|
|
669
434
|
_id: string;
|
|
670
435
|
created_at: number & {
|
|
@@ -677,6 +442,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
677
442
|
type: "note";
|
|
678
443
|
created_by?: string | undefined;
|
|
679
444
|
updated_by?: string | undefined;
|
|
445
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
680
446
|
} | {
|
|
681
447
|
_id: string;
|
|
682
448
|
created_at: number & {
|
|
@@ -689,6 +455,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
689
455
|
updated_by: "system";
|
|
690
456
|
message: string;
|
|
691
457
|
type: "system_info";
|
|
458
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
692
459
|
} | {
|
|
693
460
|
_id: string;
|
|
694
461
|
created_at: number & {
|
|
@@ -697,73 +464,13 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
697
464
|
updated_at: number & {
|
|
698
465
|
__brand: "UnixTimestamp";
|
|
699
466
|
};
|
|
700
|
-
type: "
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
updated_by?: string | undefined;
|
|
705
|
-
}, {
|
|
706
|
-
_id: string;
|
|
707
|
-
created_at: number;
|
|
708
|
-
updated_at: number;
|
|
709
|
-
message: string;
|
|
710
|
-
type: "note";
|
|
711
|
-
created_by?: string | undefined;
|
|
712
|
-
updated_by?: string | undefined;
|
|
713
|
-
} | {
|
|
714
|
-
_id: string;
|
|
715
|
-
created_at: number;
|
|
716
|
-
created_by: "system";
|
|
717
|
-
updated_at: number;
|
|
718
|
-
updated_by: "system";
|
|
719
|
-
message: string;
|
|
720
|
-
type: "system_info";
|
|
721
|
-
} | {
|
|
722
|
-
_id: string;
|
|
723
|
-
created_at: number;
|
|
724
|
-
updated_at: number;
|
|
725
|
-
type: "statusChanged";
|
|
726
|
-
curr_status: string;
|
|
727
|
-
prev_status: string;
|
|
728
|
-
created_by?: string | undefined;
|
|
729
|
-
updated_by?: string | undefined;
|
|
730
|
-
}>, {
|
|
731
|
-
_id: string;
|
|
732
|
-
created_at: number & {
|
|
733
|
-
__brand: "UnixTimestamp";
|
|
734
|
-
};
|
|
735
|
-
updated_at: number & {
|
|
736
|
-
__brand: "UnixTimestamp";
|
|
737
|
-
};
|
|
738
|
-
message: string;
|
|
739
|
-
type: "note";
|
|
740
|
-
created_by?: string | undefined;
|
|
741
|
-
updated_by?: string | undefined;
|
|
742
|
-
} | {
|
|
743
|
-
_id: string;
|
|
744
|
-
created_at: number & {
|
|
745
|
-
__brand: "UnixTimestamp";
|
|
746
|
-
};
|
|
747
|
-
created_by: "system";
|
|
748
|
-
updated_at: number & {
|
|
749
|
-
__brand: "UnixTimestamp";
|
|
750
|
-
};
|
|
751
|
-
updated_by: "system";
|
|
752
|
-
message: string;
|
|
753
|
-
type: "system_info";
|
|
754
|
-
} | {
|
|
755
|
-
_id: string;
|
|
756
|
-
created_at: number & {
|
|
757
|
-
__brand: "UnixTimestamp";
|
|
758
|
-
};
|
|
759
|
-
updated_at: number & {
|
|
760
|
-
__brand: "UnixTimestamp";
|
|
761
|
-
};
|
|
762
|
-
type: "statusChanged";
|
|
763
|
-
curr_status: string;
|
|
764
|
-
prev_status: string;
|
|
467
|
+
type: "status_changed";
|
|
468
|
+
accessor: string;
|
|
469
|
+
curr_status: string | boolean;
|
|
470
|
+
prev_status: string | boolean;
|
|
765
471
|
created_by?: string | undefined;
|
|
766
472
|
updated_by?: string | undefined;
|
|
473
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
767
474
|
}, {
|
|
768
475
|
_id: string;
|
|
769
476
|
created_at: number;
|
|
@@ -772,6 +479,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
772
479
|
type: "note";
|
|
773
480
|
created_by?: string | undefined;
|
|
774
481
|
updated_by?: string | undefined;
|
|
482
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
775
483
|
} | {
|
|
776
484
|
_id: string;
|
|
777
485
|
created_at: number;
|
|
@@ -780,17 +488,21 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
780
488
|
updated_by: "system";
|
|
781
489
|
message: string;
|
|
782
490
|
type: "system_info";
|
|
491
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
783
492
|
} | {
|
|
784
493
|
_id: string;
|
|
785
494
|
created_at: number;
|
|
786
495
|
updated_at: number;
|
|
787
|
-
type: "
|
|
788
|
-
|
|
789
|
-
|
|
496
|
+
type: "status_changed";
|
|
497
|
+
accessor: string;
|
|
498
|
+
curr_status: string | boolean;
|
|
499
|
+
prev_status: string | boolean;
|
|
790
500
|
created_by?: string | undefined;
|
|
791
501
|
updated_by?: string | undefined;
|
|
502
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
792
503
|
}>, "many">>;
|
|
793
504
|
acceptance_status: z.ZodEnum<["justification_required", "under_review", "accepted", "rejected"]>;
|
|
505
|
+
pto_message: z.ZodDefault<z.ZodString>;
|
|
794
506
|
analysis: z.ZodObject<{
|
|
795
507
|
error_message: z.ZodOptional<z.ZodString>;
|
|
796
508
|
grade: z.ZodEnum<["pass", "fail", "skip", "error"]>;
|
|
@@ -806,7 +518,6 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
806
518
|
}>;
|
|
807
519
|
justification_cause: z.ZodEnum<["TECHNICAL_PROBLEM", "DEMONSTRATION", "ACCIDENT", "WEATHER", "CONSTRUCTION", "POLICE_ACTIVITY", "MEDICAL_EMERGENCY", "OTHER_CAUSE"]>;
|
|
808
520
|
justification_source: z.ZodEnum<["MANUAL", "REALTIME_ALERT"]>;
|
|
809
|
-
pto_message: z.ZodDefault<z.ZodString>;
|
|
810
521
|
trip_id: z.ZodString;
|
|
811
522
|
}, "created_at" | "updated_at">, "strict", z.ZodTypeAny, {
|
|
812
523
|
is_locked: boolean;
|
|
@@ -822,6 +533,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
822
533
|
type: "note";
|
|
823
534
|
created_by?: string | undefined;
|
|
824
535
|
updated_by?: string | undefined;
|
|
536
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
825
537
|
} | {
|
|
826
538
|
_id: string;
|
|
827
539
|
created_at: number & {
|
|
@@ -834,6 +546,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
834
546
|
updated_by: "system";
|
|
835
547
|
message: string;
|
|
836
548
|
type: "system_info";
|
|
549
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
837
550
|
} | {
|
|
838
551
|
_id: string;
|
|
839
552
|
created_at: number & {
|
|
@@ -842,13 +555,16 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
842
555
|
updated_at: number & {
|
|
843
556
|
__brand: "UnixTimestamp";
|
|
844
557
|
};
|
|
845
|
-
type: "
|
|
846
|
-
|
|
847
|
-
|
|
558
|
+
type: "status_changed";
|
|
559
|
+
accessor: string;
|
|
560
|
+
curr_status: string | boolean;
|
|
561
|
+
prev_status: string | boolean;
|
|
848
562
|
created_by?: string | undefined;
|
|
849
563
|
updated_by?: string | undefined;
|
|
564
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
850
565
|
})[];
|
|
851
566
|
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
567
|
+
pto_message: string;
|
|
852
568
|
analysis: {
|
|
853
569
|
grade: "error" | "pass" | "fail" | "skip";
|
|
854
570
|
reason: string;
|
|
@@ -856,7 +572,6 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
856
572
|
};
|
|
857
573
|
justification_cause: "ACCIDENT" | "CONSTRUCTION" | "DEMONSTRATION" | "MEDICAL_EMERGENCY" | "OTHER_CAUSE" | "POLICE_ACTIVITY" | "TECHNICAL_PROBLEM" | "WEATHER";
|
|
858
574
|
justification_source: "MANUAL" | "REALTIME_ALERT";
|
|
859
|
-
pto_message: string;
|
|
860
575
|
trip_id: string;
|
|
861
576
|
_id?: string | undefined;
|
|
862
577
|
created_by?: string | undefined;
|
|
@@ -883,6 +598,7 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
883
598
|
type: "note";
|
|
884
599
|
created_by?: string | undefined;
|
|
885
600
|
updated_by?: string | undefined;
|
|
601
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
886
602
|
} | {
|
|
887
603
|
_id: string;
|
|
888
604
|
created_at: number;
|
|
@@ -891,15 +607,18 @@ export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
|
891
607
|
updated_by: "system";
|
|
892
608
|
message: string;
|
|
893
609
|
type: "system_info";
|
|
610
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
894
611
|
} | {
|
|
895
612
|
_id: string;
|
|
896
613
|
created_at: number;
|
|
897
614
|
updated_at: number;
|
|
898
|
-
type: "
|
|
899
|
-
|
|
900
|
-
|
|
615
|
+
type: "status_changed";
|
|
616
|
+
accessor: string;
|
|
617
|
+
curr_status: string | boolean;
|
|
618
|
+
prev_status: string | boolean;
|
|
901
619
|
created_by?: string | undefined;
|
|
902
620
|
updated_by?: string | undefined;
|
|
621
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
903
622
|
})[] | undefined;
|
|
904
623
|
pto_message?: string | undefined;
|
|
905
624
|
}>;
|
|
@@ -907,7 +626,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
907
626
|
_id: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
908
627
|
updated_by: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
909
628
|
is_locked: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
910
|
-
comments: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodEffects<z.
|
|
629
|
+
comments: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodEffects<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
|
|
911
630
|
_id: z.ZodString;
|
|
912
631
|
created_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
913
632
|
created_by: z.ZodOptional<z.ZodString>;
|
|
@@ -915,6 +634,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
915
634
|
updated_by: z.ZodOptional<z.ZodString>;
|
|
916
635
|
} & {
|
|
917
636
|
message: z.ZodString;
|
|
637
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
918
638
|
type: z.ZodLiteral<"note">;
|
|
919
639
|
}, "strip", z.ZodTypeAny, {
|
|
920
640
|
_id: string;
|
|
@@ -928,6 +648,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
928
648
|
type: "note";
|
|
929
649
|
created_by?: string | undefined;
|
|
930
650
|
updated_by?: string | undefined;
|
|
651
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
931
652
|
}, {
|
|
932
653
|
_id: string;
|
|
933
654
|
created_at: number;
|
|
@@ -936,6 +657,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
936
657
|
type: "note";
|
|
937
658
|
created_by?: string | undefined;
|
|
938
659
|
updated_by?: string | undefined;
|
|
660
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
939
661
|
}>, z.ZodObject<{
|
|
940
662
|
_id: z.ZodString;
|
|
941
663
|
created_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
@@ -943,6 +665,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
943
665
|
} & {
|
|
944
666
|
created_by: z.ZodLiteral<"system">;
|
|
945
667
|
message: z.ZodString;
|
|
668
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
946
669
|
type: z.ZodLiteral<"system_info">;
|
|
947
670
|
updated_by: z.ZodLiteral<"system">;
|
|
948
671
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -957,6 +680,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
957
680
|
updated_by: "system";
|
|
958
681
|
message: string;
|
|
959
682
|
type: "system_info";
|
|
683
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
960
684
|
}, {
|
|
961
685
|
_id: string;
|
|
962
686
|
created_at: number;
|
|
@@ -965,6 +689,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
965
689
|
updated_by: "system";
|
|
966
690
|
message: string;
|
|
967
691
|
type: "system_info";
|
|
692
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
968
693
|
}>, z.ZodObject<{
|
|
969
694
|
_id: z.ZodString;
|
|
970
695
|
created_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
@@ -972,9 +697,11 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
972
697
|
updated_at: z.ZodEffects<z.ZodNumber, import("../_common/unix-timestamp.js").UnixTimestamp, number>;
|
|
973
698
|
updated_by: z.ZodOptional<z.ZodString>;
|
|
974
699
|
} & {
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
700
|
+
accessor: z.ZodString;
|
|
701
|
+
curr_status: z.ZodUnion<[z.ZodString, z.ZodBoolean]>;
|
|
702
|
+
metadata: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
703
|
+
prev_status: z.ZodUnion<[z.ZodString, z.ZodBoolean]>;
|
|
704
|
+
type: z.ZodLiteral<"status_changed">;
|
|
978
705
|
}, "strip", z.ZodTypeAny, {
|
|
979
706
|
_id: string;
|
|
980
707
|
created_at: number & {
|
|
@@ -983,20 +710,24 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
983
710
|
updated_at: number & {
|
|
984
711
|
__brand: "UnixTimestamp";
|
|
985
712
|
};
|
|
986
|
-
type: "
|
|
987
|
-
|
|
988
|
-
|
|
713
|
+
type: "status_changed";
|
|
714
|
+
accessor: string;
|
|
715
|
+
curr_status: string | boolean;
|
|
716
|
+
prev_status: string | boolean;
|
|
989
717
|
created_by?: string | undefined;
|
|
990
718
|
updated_by?: string | undefined;
|
|
719
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
991
720
|
}, {
|
|
992
721
|
_id: string;
|
|
993
722
|
created_at: number;
|
|
994
723
|
updated_at: number;
|
|
995
|
-
type: "
|
|
996
|
-
|
|
997
|
-
|
|
724
|
+
type: "status_changed";
|
|
725
|
+
accessor: string;
|
|
726
|
+
curr_status: string | boolean;
|
|
727
|
+
prev_status: string | boolean;
|
|
998
728
|
created_by?: string | undefined;
|
|
999
729
|
updated_by?: string | undefined;
|
|
730
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1000
731
|
}>]>, {
|
|
1001
732
|
_id: string;
|
|
1002
733
|
created_at: number & {
|
|
@@ -1009,6 +740,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
1009
740
|
type: "note";
|
|
1010
741
|
created_by?: string | undefined;
|
|
1011
742
|
updated_by?: string | undefined;
|
|
743
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1012
744
|
} | {
|
|
1013
745
|
_id: string;
|
|
1014
746
|
created_at: number & {
|
|
@@ -1021,6 +753,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
1021
753
|
updated_by: "system";
|
|
1022
754
|
message: string;
|
|
1023
755
|
type: "system_info";
|
|
756
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1024
757
|
} | {
|
|
1025
758
|
_id: string;
|
|
1026
759
|
created_at: number & {
|
|
@@ -1029,73 +762,13 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
1029
762
|
updated_at: number & {
|
|
1030
763
|
__brand: "UnixTimestamp";
|
|
1031
764
|
};
|
|
1032
|
-
type: "
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
updated_by?: string | undefined;
|
|
1037
|
-
}, {
|
|
1038
|
-
_id: string;
|
|
1039
|
-
created_at: number;
|
|
1040
|
-
updated_at: number;
|
|
1041
|
-
message: string;
|
|
1042
|
-
type: "note";
|
|
1043
|
-
created_by?: string | undefined;
|
|
1044
|
-
updated_by?: string | undefined;
|
|
1045
|
-
} | {
|
|
1046
|
-
_id: string;
|
|
1047
|
-
created_at: number;
|
|
1048
|
-
created_by: "system";
|
|
1049
|
-
updated_at: number;
|
|
1050
|
-
updated_by: "system";
|
|
1051
|
-
message: string;
|
|
1052
|
-
type: "system_info";
|
|
1053
|
-
} | {
|
|
1054
|
-
_id: string;
|
|
1055
|
-
created_at: number;
|
|
1056
|
-
updated_at: number;
|
|
1057
|
-
type: "statusChanged";
|
|
1058
|
-
curr_status: string;
|
|
1059
|
-
prev_status: string;
|
|
1060
|
-
created_by?: string | undefined;
|
|
1061
|
-
updated_by?: string | undefined;
|
|
1062
|
-
}>, {
|
|
1063
|
-
_id: string;
|
|
1064
|
-
created_at: number & {
|
|
1065
|
-
__brand: "UnixTimestamp";
|
|
1066
|
-
};
|
|
1067
|
-
updated_at: number & {
|
|
1068
|
-
__brand: "UnixTimestamp";
|
|
1069
|
-
};
|
|
1070
|
-
message: string;
|
|
1071
|
-
type: "note";
|
|
1072
|
-
created_by?: string | undefined;
|
|
1073
|
-
updated_by?: string | undefined;
|
|
1074
|
-
} | {
|
|
1075
|
-
_id: string;
|
|
1076
|
-
created_at: number & {
|
|
1077
|
-
__brand: "UnixTimestamp";
|
|
1078
|
-
};
|
|
1079
|
-
created_by: "system";
|
|
1080
|
-
updated_at: number & {
|
|
1081
|
-
__brand: "UnixTimestamp";
|
|
1082
|
-
};
|
|
1083
|
-
updated_by: "system";
|
|
1084
|
-
message: string;
|
|
1085
|
-
type: "system_info";
|
|
1086
|
-
} | {
|
|
1087
|
-
_id: string;
|
|
1088
|
-
created_at: number & {
|
|
1089
|
-
__brand: "UnixTimestamp";
|
|
1090
|
-
};
|
|
1091
|
-
updated_at: number & {
|
|
1092
|
-
__brand: "UnixTimestamp";
|
|
1093
|
-
};
|
|
1094
|
-
type: "statusChanged";
|
|
1095
|
-
curr_status: string;
|
|
1096
|
-
prev_status: string;
|
|
765
|
+
type: "status_changed";
|
|
766
|
+
accessor: string;
|
|
767
|
+
curr_status: string | boolean;
|
|
768
|
+
prev_status: string | boolean;
|
|
1097
769
|
created_by?: string | undefined;
|
|
1098
770
|
updated_by?: string | undefined;
|
|
771
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1099
772
|
}, {
|
|
1100
773
|
_id: string;
|
|
1101
774
|
created_at: number;
|
|
@@ -1104,6 +777,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
1104
777
|
type: "note";
|
|
1105
778
|
created_by?: string | undefined;
|
|
1106
779
|
updated_by?: string | undefined;
|
|
780
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1107
781
|
} | {
|
|
1108
782
|
_id: string;
|
|
1109
783
|
created_at: number;
|
|
@@ -1112,19 +786,22 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
1112
786
|
updated_by: "system";
|
|
1113
787
|
message: string;
|
|
1114
788
|
type: "system_info";
|
|
789
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1115
790
|
} | {
|
|
1116
791
|
_id: string;
|
|
1117
792
|
created_at: number;
|
|
1118
793
|
updated_at: number;
|
|
1119
|
-
type: "
|
|
1120
|
-
|
|
1121
|
-
|
|
794
|
+
type: "status_changed";
|
|
795
|
+
accessor: string;
|
|
796
|
+
curr_status: string | boolean;
|
|
797
|
+
prev_status: string | boolean;
|
|
1122
798
|
created_by?: string | undefined;
|
|
1123
799
|
updated_by?: string | undefined;
|
|
800
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1124
801
|
}>, "many">>>;
|
|
1125
802
|
acceptance_status: z.ZodOptional<z.ZodEnum<["justification_required", "under_review", "accepted", "rejected"]>>;
|
|
1126
|
-
justification_cause: z.ZodOptional<z.ZodEnum<["TECHNICAL_PROBLEM", "DEMONSTRATION", "ACCIDENT", "WEATHER", "CONSTRUCTION", "POLICE_ACTIVITY", "MEDICAL_EMERGENCY", "OTHER_CAUSE"]>>;
|
|
1127
803
|
pto_message: z.ZodOptional<z.ZodDefault<z.ZodString>>;
|
|
804
|
+
justification_cause: z.ZodOptional<z.ZodEnum<["TECHNICAL_PROBLEM", "DEMONSTRATION", "ACCIDENT", "WEATHER", "CONSTRUCTION", "POLICE_ACTIVITY", "MEDICAL_EMERGENCY", "OTHER_CAUSE"]>>;
|
|
1128
805
|
trip_id: z.ZodOptional<z.ZodString>;
|
|
1129
806
|
}, "strict", z.ZodTypeAny, {
|
|
1130
807
|
_id?: string | undefined;
|
|
@@ -1142,6 +819,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
1142
819
|
type: "note";
|
|
1143
820
|
created_by?: string | undefined;
|
|
1144
821
|
updated_by?: string | undefined;
|
|
822
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1145
823
|
} | {
|
|
1146
824
|
_id: string;
|
|
1147
825
|
created_at: number & {
|
|
@@ -1154,6 +832,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
1154
832
|
updated_by: "system";
|
|
1155
833
|
message: string;
|
|
1156
834
|
type: "system_info";
|
|
835
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1157
836
|
} | {
|
|
1158
837
|
_id: string;
|
|
1159
838
|
created_at: number & {
|
|
@@ -1162,15 +841,17 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
1162
841
|
updated_at: number & {
|
|
1163
842
|
__brand: "UnixTimestamp";
|
|
1164
843
|
};
|
|
1165
|
-
type: "
|
|
1166
|
-
|
|
1167
|
-
|
|
844
|
+
type: "status_changed";
|
|
845
|
+
accessor: string;
|
|
846
|
+
curr_status: string | boolean;
|
|
847
|
+
prev_status: string | boolean;
|
|
1168
848
|
created_by?: string | undefined;
|
|
1169
849
|
updated_by?: string | undefined;
|
|
850
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1170
851
|
})[] | undefined;
|
|
1171
852
|
acceptance_status?: "accepted" | "justification_required" | "under_review" | "rejected" | undefined;
|
|
1172
|
-
justification_cause?: "ACCIDENT" | "CONSTRUCTION" | "DEMONSTRATION" | "MEDICAL_EMERGENCY" | "OTHER_CAUSE" | "POLICE_ACTIVITY" | "TECHNICAL_PROBLEM" | "WEATHER" | undefined;
|
|
1173
853
|
pto_message?: string | undefined;
|
|
854
|
+
justification_cause?: "ACCIDENT" | "CONSTRUCTION" | "DEMONSTRATION" | "MEDICAL_EMERGENCY" | "OTHER_CAUSE" | "POLICE_ACTIVITY" | "TECHNICAL_PROBLEM" | "WEATHER" | undefined;
|
|
1174
855
|
trip_id?: string | undefined;
|
|
1175
856
|
}, {
|
|
1176
857
|
_id?: string | undefined;
|
|
@@ -1184,6 +865,7 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
1184
865
|
type: "note";
|
|
1185
866
|
created_by?: string | undefined;
|
|
1186
867
|
updated_by?: string | undefined;
|
|
868
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1187
869
|
} | {
|
|
1188
870
|
_id: string;
|
|
1189
871
|
created_at: number;
|
|
@@ -1192,22 +874,24 @@ export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
|
1192
874
|
updated_by: "system";
|
|
1193
875
|
message: string;
|
|
1194
876
|
type: "system_info";
|
|
877
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1195
878
|
} | {
|
|
1196
879
|
_id: string;
|
|
1197
880
|
created_at: number;
|
|
1198
881
|
updated_at: number;
|
|
1199
|
-
type: "
|
|
1200
|
-
|
|
1201
|
-
|
|
882
|
+
type: "status_changed";
|
|
883
|
+
accessor: string;
|
|
884
|
+
curr_status: string | boolean;
|
|
885
|
+
prev_status: string | boolean;
|
|
1202
886
|
created_by?: string | undefined;
|
|
1203
887
|
updated_by?: string | undefined;
|
|
888
|
+
metadata?: Record<string, unknown> | null | undefined;
|
|
1204
889
|
})[] | undefined;
|
|
1205
890
|
acceptance_status?: "accepted" | "justification_required" | "under_review" | "rejected" | undefined;
|
|
1206
|
-
justification_cause?: "ACCIDENT" | "CONSTRUCTION" | "DEMONSTRATION" | "MEDICAL_EMERGENCY" | "OTHER_CAUSE" | "POLICE_ACTIVITY" | "TECHNICAL_PROBLEM" | "WEATHER" | undefined;
|
|
1207
891
|
pto_message?: string | undefined;
|
|
892
|
+
justification_cause?: "ACCIDENT" | "CONSTRUCTION" | "DEMONSTRATION" | "MEDICAL_EMERGENCY" | "OTHER_CAUSE" | "POLICE_ACTIVITY" | "TECHNICAL_PROBLEM" | "WEATHER" | undefined;
|
|
1208
893
|
trip_id?: string | undefined;
|
|
1209
894
|
}>;
|
|
1210
895
|
export type RideJustification = z.infer<typeof RideJustificationSchema>;
|
|
1211
896
|
export type CreateRideJustificationDto = z.infer<typeof CreateRideJustificationSchema>;
|
|
1212
897
|
export type UpdateRideJustificationDto = z.infer<typeof UpdateRideJustificationSchema>;
|
|
1213
|
-
export {};
|