Skip to content

Commit

Permalink
Change trip-type from array to string
Browse files Browse the repository at this point in the history
Corrects error changing trip_type from array to string in models/trip.yaml and each mode
  • Loading branch information
mplsmitch committed Oct 4, 2024
1 parent 1c1c52c commit a285fd7
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 34 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@
.venv
.vscode
*.egg-info
/.idea
11 changes: 4 additions & 7 deletions models/modes/car-share/trip.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,10 @@ properties:
$ref: ../../data-types/uuid.yaml
description: A unique identifier for an entire car share reservation, tied across multiple journeys and therefore trips.
trip_type:
minItems: 1
maxItems: 1
items:
enum:
- private
- reservation
- empty
enum:
- private
- reservation
- empty
trip_attributes:
required:
- reservation_type
Expand Down
15 changes: 6 additions & 9 deletions models/modes/delivery-robots/trip.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,12 @@ properties:
The `journey_id` field shall have a consistent value in overlapping trips. Journeys may be point-to-point, multi-segment,
or multi-segment overlapping.
trip_type:
minItems: 1
maxItems: 1
items:
enum:
- delivery
- return
- advertising
- mapping
- roaming
enum:
- delivery
- return
- advertising
- mapping
- roaming
trip_attributes:
required:
- driver_type
Expand Down
10 changes: 4 additions & 6 deletions models/modes/micromobility/trip.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,10 @@ x-stoplight:

properties:
trip_type:
maxItems: 1
items:
enum:
- rider
- rebalance
- maintenance
enum:
- rider
- rebalance
- maintenance
accessibility_attributes:
$ref: ./accessibility-attributes.yaml
description: The accessibility options utilized for a given trip. Required if available.
13 changes: 5 additions & 8 deletions models/modes/passenger-services/trip.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,11 @@ properties:
$ref: ../../data-types/uuid.yaml
description: A unique identifier for an entire driver's work shift, tied across multiple journeys and therefore trips.
trip_type:
minItems: 1
maxItems: 1
items:
enum:
- private
- shared
- reservation
- empty
enum:
- private
- shared
- reservation
- empty
trip_attributes:
required:
- hail_type
Expand Down
5 changes: 1 addition & 4 deletions models/trip.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,7 @@ allOf:
$ref: ./data-types/uuid.yaml
description: A unique ID for each trip
trip_type:
type: array
uniqueItems: true
items:
type: string
type: string
trip_attributes:
type: object
fare_attributes:
Expand Down

0 comments on commit a285fd7

Please sign in to comment.