@tmlmobilidade/types 20250909.1559.44 → 20250910.1344.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 +20 -12
- package/dist/src/_common/comment.js +0 -1
- package/dist/src/_common/document.d.ts +14 -8
- package/dist/src/_common/document.js +4 -2
- package/dist/src/_common/proposed-change.d.ts +37 -19
- package/dist/src/agency.d.ts +30 -12
- package/dist/src/alert.d.ts +21 -12
- package/dist/src/auth/role.d.ts +30 -12
- package/dist/src/auth/session.d.ts +30 -12
- package/dist/src/auth/user.d.ts +30 -12
- package/dist/src/auth/verification-token.d.ts +30 -12
- package/dist/src/file.d.ts +23 -23
- package/dist/src/organization.d.ts +30 -12
- package/dist/src/plans/gtfs-validation.d.ts +30 -12
- package/dist/src/plans/plan.d.ts +30 -12
- package/dist/src/rides/index.d.ts +2 -1
- package/dist/src/rides/index.js +2 -1
- package/dist/src/rides/ride-audit.d.ts +219 -0
- package/dist/src/rides/ride-audit.js +12 -0
- package/dist/src/rides/ride-justification.d.ts +447 -0
- package/dist/src/rides/ride-justification.js +43 -0
- package/dist/src/rides/ride-overrides.d.ts +9 -0
- package/dist/src/rides/ride-overrides.js +6 -0
- package/dist/src/rides/ride.d.ts +38 -20
- package/dist/src/sams/sam.d.ts +30 -12
- package/dist/src/simplified-apex/simplified-apex-location.d.ts +32 -20
- package/dist/src/simplified-apex/simplified-apex-on-board-refund.d.ts +32 -20
- package/dist/src/simplified-apex/simplified-apex-on-board-sale.d.ts +32 -20
- package/dist/src/simplified-apex/simplified-apex-validation.d.ts +32 -20
- package/dist/src/stop.d.ts +146 -101
- package/dist/src/vehicle-event.d.ts +18 -12
- package/dist/src/zone.d.ts +24 -6
- package/package.json +1 -1
- package/dist/src/rides/ride-annotation.d.ts +0 -579
- package/dist/src/rides/ride-annotation.js +0 -34
|
@@ -0,0 +1,219 @@
|
|
|
1
|
+
import { type UnixTimestamp } from '../_common/unix-timestamp.js';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
export declare const RideAuditSchema: z.ZodObject<{
|
|
4
|
+
_id: z.ZodString;
|
|
5
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
6
|
+
created_by: z.ZodDefault<z.ZodString>;
|
|
7
|
+
updated_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
8
|
+
updated_by: z.ZodDefault<z.ZodString>;
|
|
9
|
+
} & {
|
|
10
|
+
comments: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
11
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
12
|
+
created_by: z.ZodDefault<z.ZodString>;
|
|
13
|
+
updated_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
14
|
+
updated_by: z.ZodDefault<z.ZodString>;
|
|
15
|
+
} & {
|
|
16
|
+
_id: z.ZodString;
|
|
17
|
+
text: z.ZodString;
|
|
18
|
+
}, "strict", z.ZodTypeAny, {
|
|
19
|
+
_id: string;
|
|
20
|
+
created_at: number & {
|
|
21
|
+
__brand: "UnixTimestamp";
|
|
22
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
23
|
+
created_by: string;
|
|
24
|
+
updated_at: number & {
|
|
25
|
+
__brand: "UnixTimestamp";
|
|
26
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
27
|
+
updated_by: string;
|
|
28
|
+
text: string;
|
|
29
|
+
}, {
|
|
30
|
+
_id: string;
|
|
31
|
+
created_at: number;
|
|
32
|
+
updated_at: number;
|
|
33
|
+
text: string;
|
|
34
|
+
created_by?: string | undefined;
|
|
35
|
+
updated_by?: string | undefined;
|
|
36
|
+
}>, "many">>;
|
|
37
|
+
is_locked: z.ZodDefault<z.ZodBoolean>;
|
|
38
|
+
ride_id: z.ZodString;
|
|
39
|
+
}, "strict", z.ZodTypeAny, {
|
|
40
|
+
_id: string;
|
|
41
|
+
created_at: number & {
|
|
42
|
+
__brand: "UnixTimestamp";
|
|
43
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
44
|
+
created_by: string;
|
|
45
|
+
updated_at: number & {
|
|
46
|
+
__brand: "UnixTimestamp";
|
|
47
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
48
|
+
updated_by: string;
|
|
49
|
+
is_locked: boolean;
|
|
50
|
+
comments: {
|
|
51
|
+
_id: string;
|
|
52
|
+
created_at: number & {
|
|
53
|
+
__brand: "UnixTimestamp";
|
|
54
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
55
|
+
created_by: string;
|
|
56
|
+
updated_at: number & {
|
|
57
|
+
__brand: "UnixTimestamp";
|
|
58
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
59
|
+
updated_by: string;
|
|
60
|
+
text: string;
|
|
61
|
+
}[];
|
|
62
|
+
ride_id: string;
|
|
63
|
+
}, {
|
|
64
|
+
_id: string;
|
|
65
|
+
created_at: number;
|
|
66
|
+
updated_at: number;
|
|
67
|
+
ride_id: string;
|
|
68
|
+
created_by?: string | undefined;
|
|
69
|
+
updated_by?: string | undefined;
|
|
70
|
+
is_locked?: boolean | undefined;
|
|
71
|
+
comments?: {
|
|
72
|
+
_id: string;
|
|
73
|
+
created_at: number;
|
|
74
|
+
updated_at: number;
|
|
75
|
+
text: string;
|
|
76
|
+
created_by?: string | undefined;
|
|
77
|
+
updated_by?: string | undefined;
|
|
78
|
+
}[] | undefined;
|
|
79
|
+
}>;
|
|
80
|
+
export declare const CreateRideAuditSchema: z.ZodObject<Omit<{
|
|
81
|
+
_id: z.ZodOptional<z.ZodString>;
|
|
82
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
83
|
+
created_by: z.ZodDefault<z.ZodString>;
|
|
84
|
+
updated_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
85
|
+
updated_by: z.ZodDefault<z.ZodString>;
|
|
86
|
+
is_locked: z.ZodDefault<z.ZodBoolean>;
|
|
87
|
+
comments: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
88
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
89
|
+
created_by: z.ZodDefault<z.ZodString>;
|
|
90
|
+
updated_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
91
|
+
updated_by: z.ZodDefault<z.ZodString>;
|
|
92
|
+
} & {
|
|
93
|
+
_id: z.ZodString;
|
|
94
|
+
text: z.ZodString;
|
|
95
|
+
}, "strict", z.ZodTypeAny, {
|
|
96
|
+
_id: string;
|
|
97
|
+
created_at: number & {
|
|
98
|
+
__brand: "UnixTimestamp";
|
|
99
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
100
|
+
created_by: string;
|
|
101
|
+
updated_at: number & {
|
|
102
|
+
__brand: "UnixTimestamp";
|
|
103
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
104
|
+
updated_by: string;
|
|
105
|
+
text: string;
|
|
106
|
+
}, {
|
|
107
|
+
_id: string;
|
|
108
|
+
created_at: number;
|
|
109
|
+
updated_at: number;
|
|
110
|
+
text: string;
|
|
111
|
+
created_by?: string | undefined;
|
|
112
|
+
updated_by?: string | undefined;
|
|
113
|
+
}>, "many">>;
|
|
114
|
+
ride_id: z.ZodString;
|
|
115
|
+
}, "created_at" | "updated_at">, "strict", z.ZodTypeAny, {
|
|
116
|
+
created_by: string;
|
|
117
|
+
updated_by: string;
|
|
118
|
+
is_locked: boolean;
|
|
119
|
+
comments: {
|
|
120
|
+
_id: string;
|
|
121
|
+
created_at: number & {
|
|
122
|
+
__brand: "UnixTimestamp";
|
|
123
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
124
|
+
created_by: string;
|
|
125
|
+
updated_at: number & {
|
|
126
|
+
__brand: "UnixTimestamp";
|
|
127
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
128
|
+
updated_by: string;
|
|
129
|
+
text: string;
|
|
130
|
+
}[];
|
|
131
|
+
ride_id: string;
|
|
132
|
+
_id?: string | undefined;
|
|
133
|
+
}, {
|
|
134
|
+
ride_id: string;
|
|
135
|
+
_id?: string | undefined;
|
|
136
|
+
created_by?: string | undefined;
|
|
137
|
+
updated_by?: string | undefined;
|
|
138
|
+
is_locked?: boolean | undefined;
|
|
139
|
+
comments?: {
|
|
140
|
+
_id: string;
|
|
141
|
+
created_at: number;
|
|
142
|
+
updated_at: number;
|
|
143
|
+
text: string;
|
|
144
|
+
created_by?: string | undefined;
|
|
145
|
+
updated_by?: string | undefined;
|
|
146
|
+
}[] | undefined;
|
|
147
|
+
}>;
|
|
148
|
+
export declare const UpdateRideAuditSchema: z.ZodObject<{
|
|
149
|
+
_id: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
150
|
+
created_by: z.ZodOptional<z.ZodDefault<z.ZodString>>;
|
|
151
|
+
updated_by: z.ZodOptional<z.ZodDefault<z.ZodString>>;
|
|
152
|
+
is_locked: z.ZodOptional<z.ZodDefault<z.ZodBoolean>>;
|
|
153
|
+
comments: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
154
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
155
|
+
created_by: z.ZodDefault<z.ZodString>;
|
|
156
|
+
updated_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
157
|
+
updated_by: z.ZodDefault<z.ZodString>;
|
|
158
|
+
} & {
|
|
159
|
+
_id: z.ZodString;
|
|
160
|
+
text: z.ZodString;
|
|
161
|
+
}, "strict", z.ZodTypeAny, {
|
|
162
|
+
_id: string;
|
|
163
|
+
created_at: number & {
|
|
164
|
+
__brand: "UnixTimestamp";
|
|
165
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
166
|
+
created_by: string;
|
|
167
|
+
updated_at: number & {
|
|
168
|
+
__brand: "UnixTimestamp";
|
|
169
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
170
|
+
updated_by: string;
|
|
171
|
+
text: string;
|
|
172
|
+
}, {
|
|
173
|
+
_id: string;
|
|
174
|
+
created_at: number;
|
|
175
|
+
updated_at: number;
|
|
176
|
+
text: string;
|
|
177
|
+
created_by?: string | undefined;
|
|
178
|
+
updated_by?: string | undefined;
|
|
179
|
+
}>, "many">>>;
|
|
180
|
+
ride_id: z.ZodOptional<z.ZodString>;
|
|
181
|
+
}, "strict", z.ZodTypeAny, {
|
|
182
|
+
_id?: string | undefined;
|
|
183
|
+
created_by?: string | undefined;
|
|
184
|
+
updated_by?: string | undefined;
|
|
185
|
+
is_locked?: boolean | undefined;
|
|
186
|
+
comments?: {
|
|
187
|
+
_id: string;
|
|
188
|
+
created_at: number & {
|
|
189
|
+
__brand: "UnixTimestamp";
|
|
190
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
191
|
+
created_by: string;
|
|
192
|
+
updated_at: number & {
|
|
193
|
+
__brand: "UnixTimestamp";
|
|
194
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
195
|
+
updated_by: string;
|
|
196
|
+
text: string;
|
|
197
|
+
}[] | undefined;
|
|
198
|
+
ride_id?: string | undefined;
|
|
199
|
+
}, {
|
|
200
|
+
_id?: string | undefined;
|
|
201
|
+
created_by?: string | undefined;
|
|
202
|
+
updated_by?: string | undefined;
|
|
203
|
+
is_locked?: boolean | undefined;
|
|
204
|
+
comments?: {
|
|
205
|
+
_id: string;
|
|
206
|
+
created_at: number;
|
|
207
|
+
updated_at: number;
|
|
208
|
+
text: string;
|
|
209
|
+
created_by?: string | undefined;
|
|
210
|
+
updated_by?: string | undefined;
|
|
211
|
+
}[] | undefined;
|
|
212
|
+
ride_id?: string | undefined;
|
|
213
|
+
}>;
|
|
214
|
+
export interface RideAudit extends Omit<z.infer<typeof RideAuditSchema>, 'created_at' | 'updated_at'> {
|
|
215
|
+
created_at: UnixTimestamp;
|
|
216
|
+
updated_at: UnixTimestamp;
|
|
217
|
+
}
|
|
218
|
+
export type CreateRideAuditDto = z.infer<typeof CreateRideAuditSchema>;
|
|
219
|
+
export type UpdateRideAuditDto = Partial<CreateRideAuditDto>;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/* * */
|
|
2
|
+
import { CommentSchema } from '../_common/comment.js';
|
|
3
|
+
import { DocumentSchema } from '../_common/document.js';
|
|
4
|
+
import { z } from 'zod';
|
|
5
|
+
/* * */
|
|
6
|
+
export const RideAuditSchema = DocumentSchema.extend({
|
|
7
|
+
comments: z.array(CommentSchema).default([]),
|
|
8
|
+
is_locked: z.boolean().default(false),
|
|
9
|
+
ride_id: z.string(),
|
|
10
|
+
}).strict();
|
|
11
|
+
export const CreateRideAuditSchema = RideAuditSchema.partial({ _id: true }).omit({ created_at: true, updated_at: true });
|
|
12
|
+
export const UpdateRideAuditSchema = CreateRideAuditSchema.partial();
|
|
@@ -0,0 +1,447 @@
|
|
|
1
|
+
import { type UnixTimestamp } from '../_common/unix-timestamp.js';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
export declare const RIDE_ACCEPTANCE_STATUS_OPTIONS: readonly ["justification_required", "under_review", "accepted", "rejected"];
|
|
4
|
+
export declare const RideAcceptanceStatusSchema: z.ZodEnum<["justification_required", "under_review", "accepted", "rejected"]>;
|
|
5
|
+
export type RideAcceptanceStatus = z.infer<typeof RideAcceptanceStatusSchema>;
|
|
6
|
+
export declare const RideJustificationChangelogSchema: z.ZodObject<{
|
|
7
|
+
acceptance_status: z.ZodEnum<["justification_required", "under_review", "accepted", "rejected"]>;
|
|
8
|
+
analysis_result: z.ZodObject<{
|
|
9
|
+
error_message: z.ZodOptional<z.ZodString>;
|
|
10
|
+
grade: z.ZodEnum<["pass", "fail", "skip", "error"]>;
|
|
11
|
+
reason: z.ZodString;
|
|
12
|
+
}, "strict", z.ZodTypeAny, {
|
|
13
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
14
|
+
reason: string;
|
|
15
|
+
error_message?: string | undefined;
|
|
16
|
+
}, {
|
|
17
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
18
|
+
reason: string;
|
|
19
|
+
error_message?: string | undefined;
|
|
20
|
+
}>;
|
|
21
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
22
|
+
created_by: z.ZodString;
|
|
23
|
+
}, "strict", z.ZodTypeAny, {
|
|
24
|
+
created_at: number & {
|
|
25
|
+
__brand: "UnixTimestamp";
|
|
26
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
27
|
+
created_by: string;
|
|
28
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
29
|
+
analysis_result: {
|
|
30
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
31
|
+
reason: string;
|
|
32
|
+
error_message?: string | undefined;
|
|
33
|
+
};
|
|
34
|
+
}, {
|
|
35
|
+
created_at: number;
|
|
36
|
+
created_by: string;
|
|
37
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
38
|
+
analysis_result: {
|
|
39
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
40
|
+
reason: string;
|
|
41
|
+
error_message?: string | undefined;
|
|
42
|
+
};
|
|
43
|
+
}>;
|
|
44
|
+
export interface RideJustificationChangelog extends Omit<z.infer<typeof RideJustificationChangelogSchema>, 'created_at'> {
|
|
45
|
+
created_at: UnixTimestamp;
|
|
46
|
+
}
|
|
47
|
+
export declare const RIDE_JUSTIFICATION_TYPE_OPTIONS: readonly ["traffic_accident", "traffic_delay", "accepted", "rejected"];
|
|
48
|
+
export declare const RideJustificationTypeSchema: z.ZodEnum<["traffic_accident", "traffic_delay", "accepted", "rejected"]>;
|
|
49
|
+
export type RideJustificationType = z.infer<typeof RideJustificationTypeSchema>;
|
|
50
|
+
export declare const RideJustificationSchema: z.ZodObject<{
|
|
51
|
+
_id: z.ZodString;
|
|
52
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
53
|
+
created_by: z.ZodDefault<z.ZodString>;
|
|
54
|
+
updated_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
55
|
+
updated_by: z.ZodDefault<z.ZodString>;
|
|
56
|
+
} & {
|
|
57
|
+
acceptance_status: z.ZodEnum<["justification_required", "under_review", "accepted", "rejected"]>;
|
|
58
|
+
changelog: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
59
|
+
acceptance_status: z.ZodEnum<["justification_required", "under_review", "accepted", "rejected"]>;
|
|
60
|
+
analysis_result: z.ZodObject<{
|
|
61
|
+
error_message: z.ZodOptional<z.ZodString>;
|
|
62
|
+
grade: z.ZodEnum<["pass", "fail", "skip", "error"]>;
|
|
63
|
+
reason: z.ZodString;
|
|
64
|
+
}, "strict", z.ZodTypeAny, {
|
|
65
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
66
|
+
reason: string;
|
|
67
|
+
error_message?: string | undefined;
|
|
68
|
+
}, {
|
|
69
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
70
|
+
reason: string;
|
|
71
|
+
error_message?: string | undefined;
|
|
72
|
+
}>;
|
|
73
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
74
|
+
created_by: z.ZodString;
|
|
75
|
+
}, "strict", z.ZodTypeAny, {
|
|
76
|
+
created_at: number & {
|
|
77
|
+
__brand: "UnixTimestamp";
|
|
78
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
79
|
+
created_by: string;
|
|
80
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
81
|
+
analysis_result: {
|
|
82
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
83
|
+
reason: string;
|
|
84
|
+
error_message?: string | undefined;
|
|
85
|
+
};
|
|
86
|
+
}, {
|
|
87
|
+
created_at: number;
|
|
88
|
+
created_by: string;
|
|
89
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
90
|
+
analysis_result: {
|
|
91
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
92
|
+
reason: string;
|
|
93
|
+
error_message?: string | undefined;
|
|
94
|
+
};
|
|
95
|
+
}>, "many">>;
|
|
96
|
+
comments: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
97
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
98
|
+
created_by: z.ZodDefault<z.ZodString>;
|
|
99
|
+
updated_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
100
|
+
updated_by: z.ZodDefault<z.ZodString>;
|
|
101
|
+
} & {
|
|
102
|
+
_id: z.ZodString;
|
|
103
|
+
text: z.ZodString;
|
|
104
|
+
}, "strict", z.ZodTypeAny, {
|
|
105
|
+
_id: string;
|
|
106
|
+
created_at: number & {
|
|
107
|
+
__brand: "UnixTimestamp";
|
|
108
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
109
|
+
created_by: string;
|
|
110
|
+
updated_at: number & {
|
|
111
|
+
__brand: "UnixTimestamp";
|
|
112
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
113
|
+
updated_by: string;
|
|
114
|
+
text: string;
|
|
115
|
+
}, {
|
|
116
|
+
_id: string;
|
|
117
|
+
created_at: number;
|
|
118
|
+
updated_at: number;
|
|
119
|
+
text: string;
|
|
120
|
+
created_by?: string | undefined;
|
|
121
|
+
updated_by?: string | undefined;
|
|
122
|
+
}>, "many">>;
|
|
123
|
+
pto_message: z.ZodDefault<z.ZodString>;
|
|
124
|
+
}, "strict", z.ZodTypeAny, {
|
|
125
|
+
_id: string;
|
|
126
|
+
created_at: number & {
|
|
127
|
+
__brand: "UnixTimestamp";
|
|
128
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
129
|
+
created_by: string;
|
|
130
|
+
updated_at: number & {
|
|
131
|
+
__brand: "UnixTimestamp";
|
|
132
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
133
|
+
updated_by: string;
|
|
134
|
+
comments: {
|
|
135
|
+
_id: string;
|
|
136
|
+
created_at: number & {
|
|
137
|
+
__brand: "UnixTimestamp";
|
|
138
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
139
|
+
created_by: string;
|
|
140
|
+
updated_at: number & {
|
|
141
|
+
__brand: "UnixTimestamp";
|
|
142
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
143
|
+
updated_by: string;
|
|
144
|
+
text: string;
|
|
145
|
+
}[];
|
|
146
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
147
|
+
changelog: {
|
|
148
|
+
created_at: number & {
|
|
149
|
+
__brand: "UnixTimestamp";
|
|
150
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
151
|
+
created_by: string;
|
|
152
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
153
|
+
analysis_result: {
|
|
154
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
155
|
+
reason: string;
|
|
156
|
+
error_message?: string | undefined;
|
|
157
|
+
};
|
|
158
|
+
}[];
|
|
159
|
+
pto_message: string;
|
|
160
|
+
}, {
|
|
161
|
+
_id: string;
|
|
162
|
+
created_at: number;
|
|
163
|
+
updated_at: number;
|
|
164
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
165
|
+
created_by?: string | undefined;
|
|
166
|
+
updated_by?: string | undefined;
|
|
167
|
+
comments?: {
|
|
168
|
+
_id: string;
|
|
169
|
+
created_at: number;
|
|
170
|
+
updated_at: number;
|
|
171
|
+
text: string;
|
|
172
|
+
created_by?: string | undefined;
|
|
173
|
+
updated_by?: string | undefined;
|
|
174
|
+
}[] | undefined;
|
|
175
|
+
changelog?: {
|
|
176
|
+
created_at: number;
|
|
177
|
+
created_by: string;
|
|
178
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
179
|
+
analysis_result: {
|
|
180
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
181
|
+
reason: string;
|
|
182
|
+
error_message?: string | undefined;
|
|
183
|
+
};
|
|
184
|
+
}[] | undefined;
|
|
185
|
+
pto_message?: string | undefined;
|
|
186
|
+
}>;
|
|
187
|
+
export declare const CreateRideJustificationSchema: z.ZodObject<Omit<{
|
|
188
|
+
_id: z.ZodOptional<z.ZodString>;
|
|
189
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
190
|
+
created_by: z.ZodDefault<z.ZodString>;
|
|
191
|
+
updated_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
192
|
+
updated_by: z.ZodDefault<z.ZodString>;
|
|
193
|
+
comments: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
194
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
195
|
+
created_by: z.ZodDefault<z.ZodString>;
|
|
196
|
+
updated_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
197
|
+
updated_by: z.ZodDefault<z.ZodString>;
|
|
198
|
+
} & {
|
|
199
|
+
_id: z.ZodString;
|
|
200
|
+
text: z.ZodString;
|
|
201
|
+
}, "strict", z.ZodTypeAny, {
|
|
202
|
+
_id: string;
|
|
203
|
+
created_at: number & {
|
|
204
|
+
__brand: "UnixTimestamp";
|
|
205
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
206
|
+
created_by: string;
|
|
207
|
+
updated_at: number & {
|
|
208
|
+
__brand: "UnixTimestamp";
|
|
209
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
210
|
+
updated_by: string;
|
|
211
|
+
text: string;
|
|
212
|
+
}, {
|
|
213
|
+
_id: string;
|
|
214
|
+
created_at: number;
|
|
215
|
+
updated_at: number;
|
|
216
|
+
text: string;
|
|
217
|
+
created_by?: string | undefined;
|
|
218
|
+
updated_by?: string | undefined;
|
|
219
|
+
}>, "many">>;
|
|
220
|
+
acceptance_status: z.ZodEnum<["justification_required", "under_review", "accepted", "rejected"]>;
|
|
221
|
+
changelog: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
222
|
+
acceptance_status: z.ZodEnum<["justification_required", "under_review", "accepted", "rejected"]>;
|
|
223
|
+
analysis_result: z.ZodObject<{
|
|
224
|
+
error_message: z.ZodOptional<z.ZodString>;
|
|
225
|
+
grade: z.ZodEnum<["pass", "fail", "skip", "error"]>;
|
|
226
|
+
reason: z.ZodString;
|
|
227
|
+
}, "strict", z.ZodTypeAny, {
|
|
228
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
229
|
+
reason: string;
|
|
230
|
+
error_message?: string | undefined;
|
|
231
|
+
}, {
|
|
232
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
233
|
+
reason: string;
|
|
234
|
+
error_message?: string | undefined;
|
|
235
|
+
}>;
|
|
236
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
237
|
+
created_by: z.ZodString;
|
|
238
|
+
}, "strict", z.ZodTypeAny, {
|
|
239
|
+
created_at: number & {
|
|
240
|
+
__brand: "UnixTimestamp";
|
|
241
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
242
|
+
created_by: string;
|
|
243
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
244
|
+
analysis_result: {
|
|
245
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
246
|
+
reason: string;
|
|
247
|
+
error_message?: string | undefined;
|
|
248
|
+
};
|
|
249
|
+
}, {
|
|
250
|
+
created_at: number;
|
|
251
|
+
created_by: string;
|
|
252
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
253
|
+
analysis_result: {
|
|
254
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
255
|
+
reason: string;
|
|
256
|
+
error_message?: string | undefined;
|
|
257
|
+
};
|
|
258
|
+
}>, "many">>;
|
|
259
|
+
pto_message: z.ZodDefault<z.ZodString>;
|
|
260
|
+
}, "created_at" | "updated_at">, "strict", z.ZodTypeAny, {
|
|
261
|
+
created_by: string;
|
|
262
|
+
updated_by: string;
|
|
263
|
+
comments: {
|
|
264
|
+
_id: string;
|
|
265
|
+
created_at: number & {
|
|
266
|
+
__brand: "UnixTimestamp";
|
|
267
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
268
|
+
created_by: string;
|
|
269
|
+
updated_at: number & {
|
|
270
|
+
__brand: "UnixTimestamp";
|
|
271
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
272
|
+
updated_by: string;
|
|
273
|
+
text: string;
|
|
274
|
+
}[];
|
|
275
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
276
|
+
changelog: {
|
|
277
|
+
created_at: number & {
|
|
278
|
+
__brand: "UnixTimestamp";
|
|
279
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
280
|
+
created_by: string;
|
|
281
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
282
|
+
analysis_result: {
|
|
283
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
284
|
+
reason: string;
|
|
285
|
+
error_message?: string | undefined;
|
|
286
|
+
};
|
|
287
|
+
}[];
|
|
288
|
+
pto_message: string;
|
|
289
|
+
_id?: string | undefined;
|
|
290
|
+
}, {
|
|
291
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
292
|
+
_id?: string | undefined;
|
|
293
|
+
created_by?: string | undefined;
|
|
294
|
+
updated_by?: string | undefined;
|
|
295
|
+
comments?: {
|
|
296
|
+
_id: string;
|
|
297
|
+
created_at: number;
|
|
298
|
+
updated_at: number;
|
|
299
|
+
text: string;
|
|
300
|
+
created_by?: string | undefined;
|
|
301
|
+
updated_by?: string | undefined;
|
|
302
|
+
}[] | undefined;
|
|
303
|
+
changelog?: {
|
|
304
|
+
created_at: number;
|
|
305
|
+
created_by: string;
|
|
306
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
307
|
+
analysis_result: {
|
|
308
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
309
|
+
reason: string;
|
|
310
|
+
error_message?: string | undefined;
|
|
311
|
+
};
|
|
312
|
+
}[] | undefined;
|
|
313
|
+
pto_message?: string | undefined;
|
|
314
|
+
}>;
|
|
315
|
+
export declare const UpdateRideJustificationSchema: z.ZodObject<{
|
|
316
|
+
_id: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
317
|
+
created_by: z.ZodOptional<z.ZodDefault<z.ZodString>>;
|
|
318
|
+
updated_by: z.ZodOptional<z.ZodDefault<z.ZodString>>;
|
|
319
|
+
comments: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
320
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
321
|
+
created_by: z.ZodDefault<z.ZodString>;
|
|
322
|
+
updated_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
323
|
+
updated_by: z.ZodDefault<z.ZodString>;
|
|
324
|
+
} & {
|
|
325
|
+
_id: z.ZodString;
|
|
326
|
+
text: z.ZodString;
|
|
327
|
+
}, "strict", z.ZodTypeAny, {
|
|
328
|
+
_id: string;
|
|
329
|
+
created_at: number & {
|
|
330
|
+
__brand: "UnixTimestamp";
|
|
331
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
332
|
+
created_by: string;
|
|
333
|
+
updated_at: number & {
|
|
334
|
+
__brand: "UnixTimestamp";
|
|
335
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
336
|
+
updated_by: string;
|
|
337
|
+
text: string;
|
|
338
|
+
}, {
|
|
339
|
+
_id: string;
|
|
340
|
+
created_at: number;
|
|
341
|
+
updated_at: number;
|
|
342
|
+
text: string;
|
|
343
|
+
created_by?: string | undefined;
|
|
344
|
+
updated_by?: string | undefined;
|
|
345
|
+
}>, "many">>>;
|
|
346
|
+
acceptance_status: z.ZodOptional<z.ZodEnum<["justification_required", "under_review", "accepted", "rejected"]>>;
|
|
347
|
+
changelog: z.ZodOptional<z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
348
|
+
acceptance_status: z.ZodEnum<["justification_required", "under_review", "accepted", "rejected"]>;
|
|
349
|
+
analysis_result: z.ZodObject<{
|
|
350
|
+
error_message: z.ZodOptional<z.ZodString>;
|
|
351
|
+
grade: z.ZodEnum<["pass", "fail", "skip", "error"]>;
|
|
352
|
+
reason: z.ZodString;
|
|
353
|
+
}, "strict", z.ZodTypeAny, {
|
|
354
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
355
|
+
reason: string;
|
|
356
|
+
error_message?: string | undefined;
|
|
357
|
+
}, {
|
|
358
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
359
|
+
reason: string;
|
|
360
|
+
error_message?: string | undefined;
|
|
361
|
+
}>;
|
|
362
|
+
created_at: z.ZodBranded<z.ZodEffects<z.ZodNumber, UnixTimestamp, number>, "UnixTimestamp">;
|
|
363
|
+
created_by: z.ZodString;
|
|
364
|
+
}, "strict", z.ZodTypeAny, {
|
|
365
|
+
created_at: number & {
|
|
366
|
+
__brand: "UnixTimestamp";
|
|
367
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
368
|
+
created_by: string;
|
|
369
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
370
|
+
analysis_result: {
|
|
371
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
372
|
+
reason: string;
|
|
373
|
+
error_message?: string | undefined;
|
|
374
|
+
};
|
|
375
|
+
}, {
|
|
376
|
+
created_at: number;
|
|
377
|
+
created_by: string;
|
|
378
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
379
|
+
analysis_result: {
|
|
380
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
381
|
+
reason: string;
|
|
382
|
+
error_message?: string | undefined;
|
|
383
|
+
};
|
|
384
|
+
}>, "many">>>;
|
|
385
|
+
pto_message: z.ZodOptional<z.ZodDefault<z.ZodString>>;
|
|
386
|
+
}, "strict", z.ZodTypeAny, {
|
|
387
|
+
_id?: string | undefined;
|
|
388
|
+
created_by?: string | undefined;
|
|
389
|
+
updated_by?: string | undefined;
|
|
390
|
+
comments?: {
|
|
391
|
+
_id: string;
|
|
392
|
+
created_at: number & {
|
|
393
|
+
__brand: "UnixTimestamp";
|
|
394
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
395
|
+
created_by: string;
|
|
396
|
+
updated_at: number & {
|
|
397
|
+
__brand: "UnixTimestamp";
|
|
398
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
399
|
+
updated_by: string;
|
|
400
|
+
text: string;
|
|
401
|
+
}[] | undefined;
|
|
402
|
+
acceptance_status?: "accepted" | "justification_required" | "under_review" | "rejected" | undefined;
|
|
403
|
+
changelog?: {
|
|
404
|
+
created_at: number & {
|
|
405
|
+
__brand: "UnixTimestamp";
|
|
406
|
+
} & z.BRAND<"UnixTimestamp">;
|
|
407
|
+
created_by: string;
|
|
408
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
409
|
+
analysis_result: {
|
|
410
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
411
|
+
reason: string;
|
|
412
|
+
error_message?: string | undefined;
|
|
413
|
+
};
|
|
414
|
+
}[] | undefined;
|
|
415
|
+
pto_message?: string | undefined;
|
|
416
|
+
}, {
|
|
417
|
+
_id?: string | undefined;
|
|
418
|
+
created_by?: string | undefined;
|
|
419
|
+
updated_by?: string | undefined;
|
|
420
|
+
comments?: {
|
|
421
|
+
_id: string;
|
|
422
|
+
created_at: number;
|
|
423
|
+
updated_at: number;
|
|
424
|
+
text: string;
|
|
425
|
+
created_by?: string | undefined;
|
|
426
|
+
updated_by?: string | undefined;
|
|
427
|
+
}[] | undefined;
|
|
428
|
+
acceptance_status?: "accepted" | "justification_required" | "under_review" | "rejected" | undefined;
|
|
429
|
+
changelog?: {
|
|
430
|
+
created_at: number;
|
|
431
|
+
created_by: string;
|
|
432
|
+
acceptance_status: "accepted" | "justification_required" | "under_review" | "rejected";
|
|
433
|
+
analysis_result: {
|
|
434
|
+
grade: "error" | "pass" | "fail" | "skip";
|
|
435
|
+
reason: string;
|
|
436
|
+
error_message?: string | undefined;
|
|
437
|
+
};
|
|
438
|
+
}[] | undefined;
|
|
439
|
+
pto_message?: string | undefined;
|
|
440
|
+
}>;
|
|
441
|
+
export interface RideJustification extends Omit<z.infer<typeof RideJustificationSchema>, 'changelog' | 'created_at' | 'updated_at'> {
|
|
442
|
+
changelog: RideJustificationChangelog[];
|
|
443
|
+
created_at: UnixTimestamp;
|
|
444
|
+
updated_at: UnixTimestamp;
|
|
445
|
+
}
|
|
446
|
+
export type CreateRideJustificationDto = z.infer<typeof CreateRideJustificationSchema>;
|
|
447
|
+
export type UpdateRideJustificationDto = Partial<CreateRideJustificationDto>;
|