@tmlmobilidade/types 20251028.1802.11 → 20251029.1355.53

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.
@@ -81,10 +81,19 @@ export declare const FlatRideSchema: z.ZodObject<{
81
81
  trip_id: z.ZodString;
82
82
  updated_at: z.ZodNumber;
83
83
  vehicle_ids: z.ZodString;
84
+ acceptance_status: z.ZodEnum<["justification_required", "under_review", "accepted", "rejected"]>;
85
+ justification_cause: z.ZodEnum<["ACCIDENT", "CONSTRUCTION", "DEMONSTRATION", "HOLIDAY", "MAINTENANCE", "MEDICAL_EMERGENCY", "OTHER_CAUSE", "POLICE_ACTIVITY", "STRIKE", "TECHNICAL_PROBLEM", "UNKNOWN_CAUSE", "WEATHER", "DRIVER_ABSENCE", "DRIVER_ISSUE", "HIGH_PASSENGER_LOAD", "ROAD_INCIDENT", "SYSTEM_FAILURE", "TRAFFIC_JAM", "VEHICLE_ISSUE"]>;
86
+ justification_source: z.ZodEnum<["MANUAL", "ALERT"]>;
87
+ manual_trip_id: z.ZodOptional<z.ZodString>;
88
+ pto_message: z.ZodDefault<z.ZodString>;
84
89
  }, "strip", z.ZodTypeAny, {
85
90
  _id: string;
86
91
  created_at: number;
87
92
  updated_at: number;
93
+ acceptance_status: "rejected" | "justification_required" | "under_review" | "accepted";
94
+ pto_message: string;
95
+ justification_cause: "ACCIDENT" | "CONSTRUCTION" | "DEMONSTRATION" | "HOLIDAY" | "MAINTENANCE" | "MEDICAL_EMERGENCY" | "OTHER_CAUSE" | "POLICE_ACTIVITY" | "STRIKE" | "TECHNICAL_PROBLEM" | "UNKNOWN_CAUSE" | "WEATHER" | "DRIVER_ABSENCE" | "DRIVER_ISSUE" | "HIGH_PASSENGER_LOAD" | "ROAD_INCIDENT" | "SYSTEM_FAILURE" | "TRAFFIC_JAM" | "VEHICLE_ISSUE";
96
+ justification_source: "MANUAL" | "ALERT";
88
97
  is_locked: boolean;
89
98
  agency_id: string;
90
99
  apex_locations_qty: number;
@@ -163,10 +172,14 @@ export declare const FlatRideSchema: z.ZodObject<{
163
172
  operational_status: string;
164
173
  seen_status: string;
165
174
  start_delay_status: string;
175
+ manual_trip_id?: string | undefined;
166
176
  }, {
167
177
  _id: string;
168
178
  created_at: number;
169
179
  updated_at: number;
180
+ acceptance_status: "rejected" | "justification_required" | "under_review" | "accepted";
181
+ justification_cause: "ACCIDENT" | "CONSTRUCTION" | "DEMONSTRATION" | "HOLIDAY" | "MAINTENANCE" | "MEDICAL_EMERGENCY" | "OTHER_CAUSE" | "POLICE_ACTIVITY" | "STRIKE" | "TECHNICAL_PROBLEM" | "UNKNOWN_CAUSE" | "WEATHER" | "DRIVER_ABSENCE" | "DRIVER_ISSUE" | "HIGH_PASSENGER_LOAD" | "ROAD_INCIDENT" | "SYSTEM_FAILURE" | "TRAFFIC_JAM" | "VEHICLE_ISSUE";
182
+ justification_source: "MANUAL" | "ALERT";
170
183
  is_locked: boolean;
171
184
  agency_id: string;
172
185
  apex_locations_qty: number;
@@ -245,6 +258,8 @@ export declare const FlatRideSchema: z.ZodObject<{
245
258
  operational_status: string;
246
259
  seen_status: string;
247
260
  start_delay_status: string;
261
+ pto_message?: string | undefined;
262
+ manual_trip_id?: string | undefined;
248
263
  }>;
249
264
  export declare const RideExportPropertiesSchema: z.ZodObject<{
250
265
  properties: z.ZodObject<{
@@ -1,6 +1,6 @@
1
1
  /* * */
2
2
  import { unixTimeStampSchema } from '../_common/unix-timestamp.js';
3
- import { RideAcceptanceStatusSchema } from '../rides/ride-acceptance.js';
3
+ import { RideAcceptanceSchema, RideAcceptanceStatusSchema, RideJustificationSchema } from '../rides/ride-acceptance.js';
4
4
  import { RideAnalysisGradeWithNoneSchema } from '../rides/ride-analysis.js';
5
5
  import { RideDelayStatusSchema, RideOperationalStatusSchema, RideSeenStatusSchema } from '../rides/ride.js';
6
6
  import { z } from 'zod';
@@ -89,6 +89,13 @@ export const FlatRideSchema = z.object({
89
89
  trip_id: z.string(),
90
90
  updated_at: z.number(),
91
91
  vehicle_ids: z.string(),
92
+ /* ACCEPTANCE / JUSTIFICATION */
93
+ /* * */
94
+ acceptance_status: RideAcceptanceSchema.shape.acceptance_status,
95
+ justification_cause: RideJustificationSchema.shape.justification_cause,
96
+ justification_source: RideJustificationSchema.shape.justification_source,
97
+ manual_trip_id: RideJustificationSchema.shape.manual_trip_id,
98
+ pto_message: RideJustificationSchema.shape.pto_message,
92
99
  });
93
100
  /* PROPERTIES SCHEMA */
94
101
  /* * */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tmlmobilidade/types",
3
- "version": "20251028.1802.11",
3
+ "version": "20251029.1355.53",
4
4
  "author": "João de Vasconcelos & Jusi Monteiro",
5
5
  "license": "AGPL-3.0-or-later",
6
6
  "homepage": "https://github.com/tmlmobilidade/services#readme",