From a3dc2d1e748de7d1bd09950f56227c7d3c2453a9 Mon Sep 17 00:00:00 2001 From: Daniel Date: Fri, 14 Mar 2025 18:02:52 +0200 Subject: [PATCH] user trips images --- angular/openapi.json | 2 +- angular/openapi.yaml | 218 +++++++++++++++++- .../_abstract/abstract-data-form-component.ts | 1 + angular/src/app/_forms/apiForms.ts | 32 ++- .../src/app/_helpers/app-helper.service.ts | 29 +++ .../location-form.component.html | 8 +- .../location-form/location-form.component.ts | 7 +- .../trip-detail/trip-detail.component.html | 6 +- .../trip/trip-detail/trip-detail.component.ts | 18 +- .../trip/trip-form/trip-form.component.html | 24 +- .../trip/trip-form/trip-form.component.ts | 8 +- .../user-trip-detail.component.html | 2 +- .../user-trip-form.component.html | 24 +- .../user-trip-form.component.ts | 146 +++++++++--- .../vessel-form/vessel-form.component.html | 8 +- .../vessel-form/vessel-form.component.ts | 8 +- angular/src/app/core/api/v1/model/location.ts | 4 +- .../app/core/api/v1/model/locationJsonld.ts | 3 +- angular/src/app/core/api/v1/model/trip.ts | 11 +- .../src/app/core/api/v1/model/tripJsonld.ts | 9 +- .../src/app/core/api/v1/model/tripLocation.ts | 2 + .../core/api/v1/model/tripLocationJsonld.ts | 2 + angular/src/app/core/api/v1/model/userTrip.ts | 12 +- .../app/core/api/v1/model/userTripEvent.ts | 2 + .../core/api/v1/model/userTripEventJsonld.ts | 2 + .../app/core/api/v1/model/userTripJsonld.ts | 9 +- angular/src/app/core/api/v1/model/vessel.ts | 4 +- .../src/app/core/api/v1/model/vesselJsonld.ts | 3 +- httpdocs/src/ApiResource/LocationApi.php | 9 +- httpdocs/src/ApiResource/TripApi.php | 97 ++++---- httpdocs/src/ApiResource/TripLocationApi.php | 9 + httpdocs/src/ApiResource/UserTripApi.php | 26 ++- httpdocs/src/ApiResource/UserTripEventApi.php | 9 + httpdocs/src/ApiResource/VesselApi.php | 9 +- .../src/Mapper/LocationEntityToApiMapper.php | 2 +- .../src/Mapper/UserTripApiToEntityMapper.php | 21 +- .../src/Mapper/UserTripEntityToApiMapper.php | 8 +- .../State/EntityClassDtoStateProcessor.php | 8 +- 38 files changed, 619 insertions(+), 183 deletions(-) diff --git a/angular/openapi.json b/angular/openapi.json index b3eae1c..27e0491 100644 --- a/angular/openapi.json +++ b/angular/openapi.json @@ -1 +1 @@ -{"openapi":"3.1.0","info":{"title":"Imaq Platform","description":"","version":"1.0.0"},"servers":[{"url":"\/","description":""}],"paths":{"\/api\/auth":{"post":{"operationId":"postCredentialsItem","tags":["Auth"],"responses":{"200":{"description":"Get JWT token","content":{"application\/json":{"schema":{"$ref":"#\/components\/schemas\/AuthResponse"}}}}},"summary":"Get JWT token to login.","requestBody":{"description":"Generate new JWT Token","content":{"application\/json":{"schema":{"$ref":"#\/components\/schemas\/Credentials"}}},"required":false},"security":[]}},"\/api\/events":{"get":{"operationId":"api_events_get_collection","tags":["Event"],"responses":{"200":{"description":"Event collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/Event.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of Event resources.","description":"Retrieves the collection of Event resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"name","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false}},"\/api\/events\/{id}":{"get":{"operationId":"api_events_id_get","tags":["Event"],"responses":{"200":{"description":"Event resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Event.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a Event resource.","description":"Retrieves a Event resource.","parameters":[{"name":"id","in":"path","description":"Event identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false}},"\/api\/locations":{"get":{"operationId":"api_locations_get_collection","tags":["Location"],"responses":{"200":{"description":"Location collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/Location.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of Location resources.","description":"Retrieves the collection of Location resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"name","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_locations_post","tags":["Location"],"responses":{"201":{"description":"Location resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Location.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a Location resource.","description":"Creates a Location resource.","parameters":[],"requestBody":{"description":"The new Location resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Location.jsonld"}}},"required":true},"deprecated":false}},"\/api\/locations\/{id}":{"get":{"operationId":"api_locations_id_get","tags":["Location"],"responses":{"200":{"description":"Location resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Location.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a Location resource.","description":"Retrieves a Location resource.","parameters":[{"name":"id","in":"path","description":"Location identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_locations_id_delete","tags":["Location"],"responses":{"204":{"description":"Location resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the Location resource.","description":"Removes the Location resource.","parameters":[{"name":"id","in":"path","description":"Location identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_locations_id_patch","tags":["Location"],"responses":{"200":{"description":"Location resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Location.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the Location resource.","description":"Updates the Location resource.","parameters":[{"name":"id","in":"path","description":"Location identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated Location resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/Location"}}},"required":true},"deprecated":false}},"\/api\/media_objects":{"get":{"operationId":"api_media_objects_get_collection","tags":["MediaObject"],"responses":{"200":{"description":"MediaObject collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/MediaObject.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of MediaObject resources.","description":"Retrieves the collection of MediaObject resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_media_objects_post","tags":["MediaObject"],"responses":{"201":{"description":"MediaObject resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/MediaObject.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a MediaObject resource.","description":"Creates a MediaObject resource.","parameters":[],"requestBody":{"description":"The new MediaObject resource","content":{"multipart\/form-data":{"schema":{"type":"object","properties":{"file":{"type":"string","format":"binary"}}}}},"required":false},"deprecated":false}},"\/api\/media_objects\/{id}":{"get":{"operationId":"api_media_objects_id_get","tags":["MediaObject"],"responses":{"200":{"description":"MediaObject resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/MediaObject.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a MediaObject resource.","description":"Retrieves a MediaObject resource.","parameters":[{"name":"id","in":"path","description":"MediaObject identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_media_objects_id_delete","tags":["MediaObject"],"responses":{"204":{"description":"MediaObject resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the MediaObject resource.","description":"Removes the MediaObject resource.","parameters":[{"name":"id","in":"path","description":"MediaObject identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false}},"\/api\/shipping_companies":{"get":{"operationId":"api_shipping_companies_get_collection","tags":["ShippingCompany"],"responses":{"200":{"description":"ShippingCompany collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/ShippingCompany.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of ShippingCompany resources.","description":"Retrieves the collection of ShippingCompany resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"name","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_shipping_companies_post","tags":["ShippingCompany"],"responses":{"201":{"description":"ShippingCompany resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/ShippingCompany.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a ShippingCompany resource.","description":"Creates a ShippingCompany resource.","parameters":[],"requestBody":{"description":"The new ShippingCompany resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/ShippingCompany.jsonld"}}},"required":true},"deprecated":false}},"\/api\/shipping_companies\/{id}":{"get":{"operationId":"api_shipping_companies_id_get","tags":["ShippingCompany"],"responses":{"200":{"description":"ShippingCompany resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/ShippingCompany.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a ShippingCompany resource.","description":"Retrieves a ShippingCompany resource.","parameters":[{"name":"id","in":"path","description":"ShippingCompany identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_shipping_companies_id_delete","tags":["ShippingCompany"],"responses":{"204":{"description":"ShippingCompany resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the ShippingCompany resource.","description":"Removes the ShippingCompany resource.","parameters":[{"name":"id","in":"path","description":"ShippingCompany identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_shipping_companies_id_patch","tags":["ShippingCompany"],"responses":{"200":{"description":"ShippingCompany resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/ShippingCompany.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the ShippingCompany resource.","description":"Updates the ShippingCompany resource.","parameters":[{"name":"id","in":"path","description":"ShippingCompany identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated ShippingCompany resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/ShippingCompany"}}},"required":true},"deprecated":false}},"\/api\/trips":{"get":{"operationId":"api_trips_get_collection","tags":["Trip"],"responses":{"200":{"description":"Trip collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/Trip.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of Trip resources.","description":"Retrieves the collection of Trip resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"id","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"integer"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_trips_post","tags":["Trip"],"responses":{"201":{"description":"Trip resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Trip.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a Trip resource.","description":"Creates a Trip resource.","parameters":[],"requestBody":{"description":"The new Trip resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Trip.jsonld"}}},"required":true},"deprecated":false}},"\/api\/trips\/{id}":{"get":{"operationId":"api_trips_id_get","tags":["Trip"],"responses":{"200":{"description":"Trip resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Trip.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a Trip resource.","description":"Retrieves a Trip resource.","parameters":[{"name":"id","in":"path","description":"Trip identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_trips_id_delete","tags":["Trip"],"responses":{"204":{"description":"Trip resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the Trip resource.","description":"Removes the Trip resource.","parameters":[{"name":"id","in":"path","description":"Trip identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_trips_id_patch","tags":["Trip"],"responses":{"200":{"description":"Trip resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Trip.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the Trip resource.","description":"Updates the Trip resource.","parameters":[{"name":"id","in":"path","description":"Trip identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated Trip resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/Trip"}}},"required":true},"deprecated":false}},"\/api\/trip_locations":{"get":{"operationId":"api_trip_locations_get_collection","tags":["TripLocation"],"responses":{"200":{"description":"TripLocation collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/TripLocation.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of TripLocation resources.","description":"Retrieves the collection of TripLocation resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"trip","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"trip[]","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"array","items":{"type":"string"}},"style":"form","explode":true,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_trip_locations_post","tags":["TripLocation"],"responses":{"201":{"description":"TripLocation resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/TripLocation.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a TripLocation resource.","description":"Creates a TripLocation resource.","parameters":[],"requestBody":{"description":"The new TripLocation resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/TripLocation.jsonld"}}},"required":true},"deprecated":false}},"\/api\/trip_locations\/{id}":{"get":{"operationId":"api_trip_locations_id_get","tags":["TripLocation"],"responses":{"200":{"description":"TripLocation resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/TripLocation.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a TripLocation resource.","description":"Retrieves a TripLocation resource.","parameters":[{"name":"id","in":"path","description":"TripLocation identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_trip_locations_id_delete","tags":["TripLocation"],"responses":{"204":{"description":"TripLocation resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the TripLocation resource.","description":"Removes the TripLocation resource.","parameters":[{"name":"id","in":"path","description":"TripLocation identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_trip_locations_id_patch","tags":["TripLocation"],"responses":{"200":{"description":"TripLocation resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/TripLocation.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the TripLocation resource.","description":"Updates the TripLocation resource.","parameters":[{"name":"id","in":"path","description":"TripLocation identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated TripLocation resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/TripLocation"}}},"required":true},"deprecated":false}},"\/api\/users":{"get":{"operationId":"api_users_get_collection","tags":["User"],"responses":{"200":{"description":"User collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/User.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of User resources.","description":"Retrieves the collection of User resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"firstName","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"lastName","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"userNameSearch","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_users_post","tags":["User"],"responses":{"201":{"description":"User resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/User.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a User resource.","description":"Creates a User resource.","parameters":[],"requestBody":{"description":"The new User resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/User.jsonld"}}},"required":true},"deprecated":false}},"\/api\/users\/{id}":{"get":{"operationId":"api_users_id_get","tags":["User"],"responses":{"200":{"description":"User resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/User.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a User resource.","description":"Retrieves a User resource.","parameters":[{"name":"id","in":"path","description":"User identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_users_id_delete","tags":["User"],"responses":{"204":{"description":"User resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the User resource.","description":"Removes the User resource.","parameters":[{"name":"id","in":"path","description":"User identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_users_id_patch","tags":["User"],"responses":{"200":{"description":"User resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/User.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the User resource.","description":"Updates the User resource.","parameters":[{"name":"id","in":"path","description":"User identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated User resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/User"}}},"required":true},"deprecated":false}},"\/api\/user_trips":{"get":{"operationId":"api_user_trips_get_collection","tags":["UserTrip"],"responses":{"200":{"description":"UserTrip collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/UserTrip.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of UserTrip resources.","description":"Retrieves the collection of UserTrip resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"trip","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"trip[]","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"array","items":{"type":"string"}},"style":"form","explode":true,"allowReserved":false},{"name":"user","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"user[]","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"array","items":{"type":"string"}},"style":"form","explode":true,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_user_trips_post","tags":["UserTrip"],"responses":{"201":{"description":"UserTrip resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTrip.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a UserTrip resource.","description":"Creates a UserTrip resource.","parameters":[],"requestBody":{"description":"The new UserTrip resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTrip.jsonld"}}},"required":true},"deprecated":false}},"\/api\/user_trips\/{id}":{"get":{"operationId":"api_user_trips_id_get","tags":["UserTrip"],"responses":{"200":{"description":"UserTrip resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTrip.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a UserTrip resource.","description":"Retrieves a UserTrip resource.","parameters":[{"name":"id","in":"path","description":"UserTrip identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_user_trips_id_delete","tags":["UserTrip"],"responses":{"204":{"description":"UserTrip resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the UserTrip resource.","description":"Removes the UserTrip resource.","parameters":[{"name":"id","in":"path","description":"UserTrip identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_user_trips_id_patch","tags":["UserTrip"],"responses":{"200":{"description":"UserTrip resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTrip.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the UserTrip resource.","description":"Updates the UserTrip resource.","parameters":[{"name":"id","in":"path","description":"UserTrip identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated UserTrip resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/UserTrip"}}},"required":true},"deprecated":false}},"\/api\/user_trip_events":{"get":{"operationId":"api_user_trip_events_get_collection","tags":["UserTripEvent"],"responses":{"200":{"description":"UserTripEvent collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/UserTripEvent.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of UserTripEvent resources.","description":"Retrieves the collection of UserTripEvent resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_user_trip_events_post","tags":["UserTripEvent"],"responses":{"201":{"description":"UserTripEvent resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTripEvent.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a UserTripEvent resource.","description":"Creates a UserTripEvent resource.","parameters":[],"requestBody":{"description":"The new UserTripEvent resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTripEvent.jsonld"}}},"required":true},"deprecated":false}},"\/api\/user_trip_events\/{id}":{"get":{"operationId":"api_user_trip_events_id_get","tags":["UserTripEvent"],"responses":{"200":{"description":"UserTripEvent resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTripEvent.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a UserTripEvent resource.","description":"Retrieves a UserTripEvent resource.","parameters":[{"name":"id","in":"path","description":"UserTripEvent identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_user_trip_events_id_patch","tags":["UserTripEvent"],"responses":{"200":{"description":"UserTripEvent resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTripEvent.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the UserTripEvent resource.","description":"Updates the UserTripEvent resource.","parameters":[{"name":"id","in":"path","description":"UserTripEvent identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated UserTripEvent resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/UserTripEvent"}}},"required":true},"deprecated":false}},"\/api\/vessels":{"get":{"operationId":"api_vessels_get_collection","tags":["Vessel"],"responses":{"200":{"description":"Vessel collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/Vessel.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of Vessel resources.","description":"Retrieves the collection of Vessel resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"name","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_vessels_post","tags":["Vessel"],"responses":{"201":{"description":"Vessel resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Vessel.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a Vessel resource.","description":"Creates a Vessel resource.","parameters":[],"requestBody":{"description":"The new Vessel resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Vessel.jsonld"}}},"required":true},"deprecated":false}},"\/api\/vessels\/{id}":{"get":{"operationId":"api_vessels_id_get","tags":["Vessel"],"responses":{"200":{"description":"Vessel resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Vessel.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a Vessel resource.","description":"Retrieves a Vessel resource.","parameters":[{"name":"id","in":"path","description":"Vessel identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_vessels_id_delete","tags":["Vessel"],"responses":{"204":{"description":"Vessel resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the Vessel resource.","description":"Removes the Vessel resource.","parameters":[{"name":"id","in":"path","description":"Vessel identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_vessels_id_patch","tags":["Vessel"],"responses":{"200":{"description":"Vessel resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Vessel.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the Vessel resource.","description":"Updates the Vessel resource.","parameters":[{"name":"id","in":"path","description":"Vessel identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated Vessel resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/Vessel"}}},"required":true},"deprecated":false}},"\/api\/zones":{"get":{"operationId":"api_zones_get_collection","tags":["Zone"],"responses":{"200":{"description":"Zone collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/Zone.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of Zone resources.","description":"Retrieves the collection of Zone resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"name","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_zones_post","tags":["Zone"],"responses":{"201":{"description":"Zone resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Zone.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a Zone resource.","description":"Creates a Zone resource.","parameters":[],"requestBody":{"description":"The new Zone resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Zone.jsonld"}}},"required":true},"deprecated":false}},"\/api\/zones\/{id}":{"get":{"operationId":"api_zones_id_get","tags":["Zone"],"responses":{"200":{"description":"Zone resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Zone.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a Zone resource.","description":"Retrieves a Zone resource.","parameters":[{"name":"id","in":"path","description":"Zone identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_zones_id_delete","tags":["Zone"],"responses":{"204":{"description":"Zone resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the Zone resource.","description":"Removes the Zone resource.","parameters":[{"name":"id","in":"path","description":"Zone identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_zones_id_patch","tags":["Zone"],"responses":{"200":{"description":"Zone resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Zone.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the Zone resource.","description":"Updates the Zone resource.","parameters":[{"name":"id","in":"path","description":"Zone identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated Zone resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/Zone"}}},"required":true},"deprecated":false}}},"components":{"schemas":{"Event.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"identifier":{"type":"string"},"sequence":{"type":"integer"},"mandatory":{"type":"boolean"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}}},"Location":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"zone":{"$ref":"#\/components\/schemas\/Zone"},"name":{"type":"string"},"code":{"type":"string"},"isZone":{"type":"boolean"},"isPlace":{"type":"boolean"},"isPort":{"type":"boolean"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name","code"]},"Location.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"zone":{"$ref":"#\/components\/schemas\/Zone.jsonld"},"name":{"type":"string"},"code":{"type":"string"},"isZone":{"type":"boolean"},"isPlace":{"type":"boolean"},"isPort":{"type":"boolean"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name","code"]},"MediaObject":{"type":"object","description":"","deprecated":false,"properties":{"id":{"readOnly":true,"type":"integer"},"file":{"type":["string","null"],"format":"binary"},"filePath":{"type":["string","null"]},"createdBy":{"$ref":"#\/components\/schemas\/User"},"createdAt":{"readOnly":true,"type":"string","format":"date-time"}},"required":["file"]},"MediaObject.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"contentUrl":{"externalDocs":{"url":"https:\/\/schema.org\/contentUrl"},"type":["string","null"]},"filePath":{"readOnly":true,"type":["string","null"]},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}}},"ShippingCompany":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"code":{"type":"string"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name","code"]},"ShippingCompany.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"code":{"type":"string"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name","code"]},"Trip":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"vessel":{"$ref":"#\/components\/schemas\/Vessel"},"pilotageReference":{"readOnly":true,"type":["string","null"]},"customerReference":{"type":["string","null"]},"captainName":{"type":["string","null"]},"startLocation":{"$ref":"#\/components\/schemas\/Location"},"endLocation":{"$ref":"#\/components\/schemas\/Location"},"startDate":{"type":"string","format":"date-time"},"endDate":{"type":"string","format":"date-time"},"note":{"type":["string","null"]},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["startDate","endDate"]},"Trip.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"vessel":{"$ref":"#\/components\/schemas\/Vessel.jsonld"},"pilotageReference":{"readOnly":true,"type":["string","null"]},"customerReference":{"type":["string","null"]},"captainName":{"type":["string","null"]},"startLocation":{"$ref":"#\/components\/schemas\/Location.jsonld"},"endLocation":{"$ref":"#\/components\/schemas\/Location.jsonld"},"startDate":{"type":"string","format":"date-time"},"endDate":{"type":"string","format":"date-time"},"note":{"type":["string","null"]},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["startDate","endDate"]},"TripLocation":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"trip":{"$ref":"#\/components\/schemas\/Trip"},"location":{"$ref":"#\/components\/schemas\/Location"},"isArrival":{"type":"boolean"},"date":{"type":"string","format":"date-time"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["date"]},"TripLocation.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"trip":{"$ref":"#\/components\/schemas\/Trip.jsonld"},"location":{"$ref":"#\/components\/schemas\/Location.jsonld"},"isArrival":{"type":"boolean"},"date":{"type":"string","format":"date-time"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["date"]},"User":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"email":{"format":"email","externalDocs":{"url":"https:\/\/schema.org\/email"},"type":"string"},"firstName":{"type":"string"},"referenceId":{"type":"string"},"lastName":{"type":"string"},"image":{"anyOf":[{"$ref":"#\/components\/schemas\/MediaObject"},{"type":"null"}]},"imageUrl":{"readOnly":true,"type":["string","null"]},"fullName":{"readOnly":true,"type":["string","null"]},"password":{"writeOnly":true,"description":"The plaintext password when being set or changed.","type":"string"},"active":{"type":"boolean"},"roles":{"readOnly":true,"type":"array","items":{"type":"string"}},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["email","firstName","referenceId","lastName"]},"User.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"email":{"format":"email","externalDocs":{"url":"https:\/\/schema.org\/email"},"type":"string"},"firstName":{"type":"string"},"referenceId":{"type":"string"},"lastName":{"type":"string"},"image":{"anyOf":[{"$ref":"#\/components\/schemas\/MediaObject.jsonld"},{"type":"null"}]},"imageUrl":{"readOnly":true,"type":["string","null"]},"fullName":{"readOnly":true,"type":["string","null"]},"password":{"writeOnly":true,"description":"The plaintext password when being set or changed.","type":"string"},"active":{"type":"boolean"},"roles":{"readOnly":true,"type":"array","items":{"type":"string"}},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["email","firstName","referenceId","lastName"]},"UserTrip":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"trip":{"$ref":"#\/components\/schemas\/Trip"},"user":{"$ref":"#\/components\/schemas\/User"},"captainName":{"type":["string","null"]},"completed":{"type":"boolean"},"signature":{"$ref":"#\/components\/schemas\/MediaObject"},"signatureUrl":{"readOnly":true,"type":["string","null"]},"completedDate":{"type":["string","null"],"format":"date-time"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["trip","user","completed"]},"UserTrip.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"trip":{"$ref":"#\/components\/schemas\/Trip.jsonld"},"user":{"$ref":"#\/components\/schemas\/User.jsonld"},"captainName":{"type":["string","null"]},"completed":{"type":"boolean"},"signature":{"$ref":"#\/components\/schemas\/MediaObject.jsonld"},"signatureUrl":{"readOnly":true,"type":["string","null"]},"completedDate":{"type":["string","null"],"format":"date-time"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["trip","user","completed"]},"UserTripEvent":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"userTrip":{"readOnly":true,"$ref":"#\/components\/schemas\/UserTrip"},"event":{"readOnly":true,"type":"string","format":"iri-reference","example":"https:\/\/example.com\/"},"date":{"type":"string","format":"date-time"},"note":{"type":["string","null"]},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["date"]},"UserTripEvent.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"userTrip":{"readOnly":true,"$ref":"#\/components\/schemas\/UserTrip.jsonld"},"event":{"readOnly":true,"$ref":"#\/components\/schemas\/Event.jsonld"},"date":{"type":"string","format":"date-time"},"note":{"type":["string","null"]},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["date"]},"Vessel":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"code":{"type":"string"},"company":{"$ref":"#\/components\/schemas\/ShippingCompany"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name","code"]},"Vessel.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"code":{"type":"string"},"company":{"$ref":"#\/components\/schemas\/ShippingCompany.jsonld"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name","code"]},"Zone":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name"]},"Zone.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name"]},"Credentials":{"type":"object","properties":{"email":{"type":"string","example":"user@example.com"},"password":{"type":"string","example":"password123"}}},"AuthResponse":{"type":"object","properties":{"@id":{"type":"string","example":"\/api\/users\/1"},"dbId":{"type":"integer","example":1},"token":{"type":"string","example":"JWT_TOKEN"}}}},"responses":{},"parameters":{},"examples":{},"requestBodies":{},"headers":{},"securitySchemes":{"JWT":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}}},"security":[{"JWT":[]}],"tags":[],"webhooks":{}} \ No newline at end of file +{"openapi":"3.1.0","info":{"title":"Imaq Platform","description":"","version":"1.0.0"},"servers":[{"url":"\/","description":""}],"paths":{"\/api\/auth":{"post":{"operationId":"postCredentialsItem","tags":["Auth"],"responses":{"200":{"description":"Get JWT token","content":{"application\/json":{"schema":{"$ref":"#\/components\/schemas\/AuthResponse"}}}}},"summary":"Get JWT token to login.","requestBody":{"description":"Generate new JWT Token","content":{"application\/json":{"schema":{"$ref":"#\/components\/schemas\/Credentials"}}},"required":false},"security":[]}},"\/api\/events":{"get":{"operationId":"api_events_get_collection","tags":["Event"],"responses":{"200":{"description":"Event collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/Event.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of Event resources.","description":"Retrieves the collection of Event resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"name","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false}},"\/api\/events\/{id}":{"get":{"operationId":"api_events_id_get","tags":["Event"],"responses":{"200":{"description":"Event resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Event.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a Event resource.","description":"Retrieves a Event resource.","parameters":[{"name":"id","in":"path","description":"Event identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false}},"\/api\/locations":{"get":{"operationId":"api_locations_get_collection","tags":["Location"],"responses":{"200":{"description":"Location collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/Location.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of Location resources.","description":"Retrieves the collection of Location resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"name","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_locations_post","tags":["Location"],"responses":{"201":{"description":"Location resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Location.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a Location resource.","description":"Creates a Location resource.","parameters":[],"requestBody":{"description":"The new Location resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Location.jsonld"}}},"required":true},"deprecated":false}},"\/api\/locations\/{id}":{"get":{"operationId":"api_locations_id_get","tags":["Location"],"responses":{"200":{"description":"Location resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Location.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a Location resource.","description":"Retrieves a Location resource.","parameters":[{"name":"id","in":"path","description":"Location identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_locations_id_delete","tags":["Location"],"responses":{"204":{"description":"Location resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the Location resource.","description":"Removes the Location resource.","parameters":[{"name":"id","in":"path","description":"Location identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_locations_id_patch","tags":["Location"],"responses":{"200":{"description":"Location resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Location.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the Location resource.","description":"Updates the Location resource.","parameters":[{"name":"id","in":"path","description":"Location identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated Location resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/Location"}}},"required":true},"deprecated":false}},"\/api\/media_objects":{"get":{"operationId":"api_media_objects_get_collection","tags":["MediaObject"],"responses":{"200":{"description":"MediaObject collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/MediaObject.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of MediaObject resources.","description":"Retrieves the collection of MediaObject resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_media_objects_post","tags":["MediaObject"],"responses":{"201":{"description":"MediaObject resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/MediaObject.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a MediaObject resource.","description":"Creates a MediaObject resource.","parameters":[],"requestBody":{"description":"The new MediaObject resource","content":{"multipart\/form-data":{"schema":{"type":"object","properties":{"file":{"type":"string","format":"binary"}}}}},"required":false},"deprecated":false}},"\/api\/media_objects\/{id}":{"get":{"operationId":"api_media_objects_id_get","tags":["MediaObject"],"responses":{"200":{"description":"MediaObject resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/MediaObject.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a MediaObject resource.","description":"Retrieves a MediaObject resource.","parameters":[{"name":"id","in":"path","description":"MediaObject identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_media_objects_id_delete","tags":["MediaObject"],"responses":{"204":{"description":"MediaObject resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the MediaObject resource.","description":"Removes the MediaObject resource.","parameters":[{"name":"id","in":"path","description":"MediaObject identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false}},"\/api\/shipping_companies":{"get":{"operationId":"api_shipping_companies_get_collection","tags":["ShippingCompany"],"responses":{"200":{"description":"ShippingCompany collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/ShippingCompany.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of ShippingCompany resources.","description":"Retrieves the collection of ShippingCompany resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"name","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_shipping_companies_post","tags":["ShippingCompany"],"responses":{"201":{"description":"ShippingCompany resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/ShippingCompany.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a ShippingCompany resource.","description":"Creates a ShippingCompany resource.","parameters":[],"requestBody":{"description":"The new ShippingCompany resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/ShippingCompany.jsonld"}}},"required":true},"deprecated":false}},"\/api\/shipping_companies\/{id}":{"get":{"operationId":"api_shipping_companies_id_get","tags":["ShippingCompany"],"responses":{"200":{"description":"ShippingCompany resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/ShippingCompany.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a ShippingCompany resource.","description":"Retrieves a ShippingCompany resource.","parameters":[{"name":"id","in":"path","description":"ShippingCompany identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_shipping_companies_id_delete","tags":["ShippingCompany"],"responses":{"204":{"description":"ShippingCompany resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the ShippingCompany resource.","description":"Removes the ShippingCompany resource.","parameters":[{"name":"id","in":"path","description":"ShippingCompany identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_shipping_companies_id_patch","tags":["ShippingCompany"],"responses":{"200":{"description":"ShippingCompany resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/ShippingCompany.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the ShippingCompany resource.","description":"Updates the ShippingCompany resource.","parameters":[{"name":"id","in":"path","description":"ShippingCompany identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated ShippingCompany resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/ShippingCompany"}}},"required":true},"deprecated":false}},"\/api\/trips":{"get":{"operationId":"api_trips_get_collection","tags":["Trip"],"responses":{"200":{"description":"Trip collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/Trip.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of Trip resources.","description":"Retrieves the collection of Trip resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"id","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"integer"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_trips_post","tags":["Trip"],"responses":{"201":{"description":"Trip resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Trip.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a Trip resource.","description":"Creates a Trip resource.","parameters":[],"requestBody":{"description":"The new Trip resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Trip.jsonld"}}},"required":true},"deprecated":false}},"\/api\/trips\/{id}":{"get":{"operationId":"api_trips_id_get","tags":["Trip"],"responses":{"200":{"description":"Trip resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Trip.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a Trip resource.","description":"Retrieves a Trip resource.","parameters":[{"name":"id","in":"path","description":"Trip identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_trips_id_delete","tags":["Trip"],"responses":{"204":{"description":"Trip resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the Trip resource.","description":"Removes the Trip resource.","parameters":[{"name":"id","in":"path","description":"Trip identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_trips_id_patch","tags":["Trip"],"responses":{"200":{"description":"Trip resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Trip.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the Trip resource.","description":"Updates the Trip resource.","parameters":[{"name":"id","in":"path","description":"Trip identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated Trip resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/Trip"}}},"required":true},"deprecated":false}},"\/api\/trip_locations":{"get":{"operationId":"api_trip_locations_get_collection","tags":["TripLocation"],"responses":{"200":{"description":"TripLocation collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/TripLocation.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of TripLocation resources.","description":"Retrieves the collection of TripLocation resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"trip","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"trip[]","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"array","items":{"type":"string"}},"style":"form","explode":true,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_trip_locations_post","tags":["TripLocation"],"responses":{"201":{"description":"TripLocation resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/TripLocation.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a TripLocation resource.","description":"Creates a TripLocation resource.","parameters":[],"requestBody":{"description":"The new TripLocation resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/TripLocation.jsonld"}}},"required":true},"deprecated":false}},"\/api\/trip_locations\/{id}":{"get":{"operationId":"api_trip_locations_id_get","tags":["TripLocation"],"responses":{"200":{"description":"TripLocation resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/TripLocation.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a TripLocation resource.","description":"Retrieves a TripLocation resource.","parameters":[{"name":"id","in":"path","description":"TripLocation identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_trip_locations_id_delete","tags":["TripLocation"],"responses":{"204":{"description":"TripLocation resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the TripLocation resource.","description":"Removes the TripLocation resource.","parameters":[{"name":"id","in":"path","description":"TripLocation identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_trip_locations_id_patch","tags":["TripLocation"],"responses":{"200":{"description":"TripLocation resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/TripLocation.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the TripLocation resource.","description":"Updates the TripLocation resource.","parameters":[{"name":"id","in":"path","description":"TripLocation identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated TripLocation resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/TripLocation"}}},"required":true},"deprecated":false}},"\/api\/users":{"get":{"operationId":"api_users_get_collection","tags":["User"],"responses":{"200":{"description":"User collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/User.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of User resources.","description":"Retrieves the collection of User resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"firstName","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"lastName","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"userNameSearch","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_users_post","tags":["User"],"responses":{"201":{"description":"User resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/User.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a User resource.","description":"Creates a User resource.","parameters":[],"requestBody":{"description":"The new User resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/User.jsonld"}}},"required":true},"deprecated":false}},"\/api\/users\/{id}":{"get":{"operationId":"api_users_id_get","tags":["User"],"responses":{"200":{"description":"User resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/User.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a User resource.","description":"Retrieves a User resource.","parameters":[{"name":"id","in":"path","description":"User identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_users_id_delete","tags":["User"],"responses":{"204":{"description":"User resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the User resource.","description":"Removes the User resource.","parameters":[{"name":"id","in":"path","description":"User identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_users_id_patch","tags":["User"],"responses":{"200":{"description":"User resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/User.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the User resource.","description":"Updates the User resource.","parameters":[{"name":"id","in":"path","description":"User identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated User resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/User"}}},"required":true},"deprecated":false}},"\/api\/user_trips":{"get":{"operationId":"api_user_trips_get_collection","tags":["UserTrip"],"responses":{"200":{"description":"UserTrip collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/UserTrip.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of UserTrip resources.","description":"Retrieves the collection of UserTrip resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"trip","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"trip[]","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"array","items":{"type":"string"}},"style":"form","explode":true,"allowReserved":false},{"name":"user","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"user[]","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"array","items":{"type":"string"}},"style":"form","explode":true,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_user_trips_post","tags":["UserTrip"],"responses":{"201":{"description":"UserTrip resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTrip.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a UserTrip resource.","description":"Creates a UserTrip resource.","parameters":[],"requestBody":{"description":"The new UserTrip resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTrip.jsonld"}}},"required":true},"deprecated":false}},"\/api\/user_trips\/{id}":{"get":{"operationId":"api_user_trips_id_get","tags":["UserTrip"],"responses":{"200":{"description":"UserTrip resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTrip.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a UserTrip resource.","description":"Retrieves a UserTrip resource.","parameters":[{"name":"id","in":"path","description":"UserTrip identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_user_trips_id_delete","tags":["UserTrip"],"responses":{"204":{"description":"UserTrip resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the UserTrip resource.","description":"Removes the UserTrip resource.","parameters":[{"name":"id","in":"path","description":"UserTrip identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_user_trips_id_patch","tags":["UserTrip"],"responses":{"200":{"description":"UserTrip resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTrip.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the UserTrip resource.","description":"Updates the UserTrip resource.","parameters":[{"name":"id","in":"path","description":"UserTrip identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated UserTrip resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/UserTrip"}}},"required":true},"deprecated":false}},"\/api\/user_trip_events":{"get":{"operationId":"api_user_trip_events_get_collection","tags":["UserTripEvent"],"responses":{"200":{"description":"UserTripEvent collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/UserTripEvent.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of UserTripEvent resources.","description":"Retrieves the collection of UserTripEvent resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_user_trip_events_post","tags":["UserTripEvent"],"responses":{"201":{"description":"UserTripEvent resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTripEvent.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a UserTripEvent resource.","description":"Creates a UserTripEvent resource.","parameters":[],"requestBody":{"description":"The new UserTripEvent resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTripEvent.jsonld"}}},"required":true},"deprecated":false}},"\/api\/user_trip_events\/{id}":{"get":{"operationId":"api_user_trip_events_id_get","tags":["UserTripEvent"],"responses":{"200":{"description":"UserTripEvent resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTripEvent.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a UserTripEvent resource.","description":"Retrieves a UserTripEvent resource.","parameters":[{"name":"id","in":"path","description":"UserTripEvent identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_user_trip_events_id_patch","tags":["UserTripEvent"],"responses":{"200":{"description":"UserTripEvent resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/UserTripEvent.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the UserTripEvent resource.","description":"Updates the UserTripEvent resource.","parameters":[{"name":"id","in":"path","description":"UserTripEvent identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated UserTripEvent resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/UserTripEvent"}}},"required":true},"deprecated":false}},"\/api\/vessels":{"get":{"operationId":"api_vessels_get_collection","tags":["Vessel"],"responses":{"200":{"description":"Vessel collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/Vessel.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of Vessel resources.","description":"Retrieves the collection of Vessel resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"name","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_vessels_post","tags":["Vessel"],"responses":{"201":{"description":"Vessel resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Vessel.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a Vessel resource.","description":"Creates a Vessel resource.","parameters":[],"requestBody":{"description":"The new Vessel resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Vessel.jsonld"}}},"required":true},"deprecated":false}},"\/api\/vessels\/{id}":{"get":{"operationId":"api_vessels_id_get","tags":["Vessel"],"responses":{"200":{"description":"Vessel resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Vessel.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a Vessel resource.","description":"Retrieves a Vessel resource.","parameters":[{"name":"id","in":"path","description":"Vessel identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_vessels_id_delete","tags":["Vessel"],"responses":{"204":{"description":"Vessel resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the Vessel resource.","description":"Removes the Vessel resource.","parameters":[{"name":"id","in":"path","description":"Vessel identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_vessels_id_patch","tags":["Vessel"],"responses":{"200":{"description":"Vessel resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Vessel.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the Vessel resource.","description":"Updates the Vessel resource.","parameters":[{"name":"id","in":"path","description":"Vessel identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated Vessel resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/Vessel"}}},"required":true},"deprecated":false}},"\/api\/zones":{"get":{"operationId":"api_zones_get_collection","tags":["Zone"],"responses":{"200":{"description":"Zone collection","content":{"application\/ld+json":{"schema":{"type":"object","properties":{"member":{"type":"array","items":{"$ref":"#\/components\/schemas\/Zone.jsonld"}},"totalItems":{"type":"integer","minimum":0},"view":{"type":"object","properties":{"@id":{"type":"string","format":"iri-reference"},"@type":{"type":"string"},"first":{"type":"string","format":"iri-reference"},"last":{"type":"string","format":"iri-reference"},"previous":{"type":"string","format":"iri-reference"},"next":{"type":"string","format":"iri-reference"}},"example":{"@id":"string","type":"string","first":"string","last":"string","previous":"string","next":"string"}},"search":{"type":"object","properties":{"@type":{"type":"string"},"template":{"type":"string"},"variableRepresentation":{"type":"string"},"mapping":{"type":"array","items":{"type":"object","properties":{"@type":{"type":"string"},"variable":{"type":"string"},"property":{"type":["string","null"]},"required":{"type":"boolean"}}}}}}},"required":["member"]}}}}},"summary":"Retrieves the collection of Zone resources.","description":"Retrieves the collection of Zone resources.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":1},"style":"form","explode":false,"allowReserved":false},{"name":"itemsPerPage","in":"query","description":"The number of items per page","required":false,"deprecated":false,"allowEmptyValue":true,"schema":{"type":"integer","default":50,"minimum":0,"maximum":200},"style":"form","explode":false,"allowReserved":false},{"name":"name","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_filter","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false},{"name":"custom_json_order","in":"query","description":"","required":false,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"form","explode":false,"allowReserved":false}],"deprecated":false},"post":{"operationId":"api_zones_post","tags":["Zone"],"responses":{"201":{"description":"Zone resource created","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Zone.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"}},"summary":"Creates a Zone resource.","description":"Creates a Zone resource.","parameters":[],"requestBody":{"description":"The new Zone resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Zone.jsonld"}}},"required":true},"deprecated":false}},"\/api\/zones\/{id}":{"get":{"operationId":"api_zones_id_get","tags":["Zone"],"responses":{"200":{"description":"Zone resource","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Zone.jsonld"}}}},"404":{"description":"Resource not found"}},"summary":"Retrieves a Zone resource.","description":"Retrieves a Zone resource.","parameters":[{"name":"id","in":"path","description":"Zone identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"delete":{"operationId":"api_zones_id_delete","tags":["Zone"],"responses":{"204":{"description":"Zone resource deleted"},"404":{"description":"Resource not found"}},"summary":"Removes the Zone resource.","description":"Removes the Zone resource.","parameters":[{"name":"id","in":"path","description":"Zone identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"deprecated":false},"patch":{"operationId":"api_zones_id_patch","tags":["Zone"],"responses":{"200":{"description":"Zone resource updated","content":{"application\/ld+json":{"schema":{"$ref":"#\/components\/schemas\/Zone.jsonld"}}},"links":{}},"400":{"description":"Invalid input"},"422":{"description":"Unprocessable entity"},"404":{"description":"Resource not found"}},"summary":"Updates the Zone resource.","description":"Updates the Zone resource.","parameters":[{"name":"id","in":"path","description":"Zone identifier","required":true,"deprecated":false,"allowEmptyValue":false,"schema":{"type":"string"},"style":"simple","explode":false,"allowReserved":false}],"requestBody":{"description":"The updated Zone resource","content":{"application\/merge-patch+json":{"schema":{"$ref":"#\/components\/schemas\/Zone"}}},"required":true},"deprecated":false}}},"components":{"schemas":{"Event.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"identifier":{"type":"string"},"sequence":{"type":"integer"},"mandatory":{"type":"boolean"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}}},"Location":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"zone":{"readOnly":true,"type":"string","format":"iri-reference","example":"https:\/\/example.com\/"},"zoneIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"name":{"type":"string"},"code":{"type":"string"},"isZone":{"type":"boolean"},"isPlace":{"type":"boolean"},"isPort":{"type":"boolean"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["zoneIri","name","code"]},"Location.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"zone":{"readOnly":true,"$ref":"#\/components\/schemas\/Zone.jsonld"},"zoneIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"name":{"type":"string"},"code":{"type":"string"},"isZone":{"type":"boolean"},"isPlace":{"type":"boolean"},"isPort":{"type":"boolean"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["zoneIri","name","code"]},"MediaObject":{"type":"object","description":"","deprecated":false,"properties":{"id":{"readOnly":true,"type":"integer"},"file":{"type":["string","null"],"format":"binary"},"filePath":{"type":["string","null"]},"createdBy":{"$ref":"#\/components\/schemas\/User"},"createdAt":{"readOnly":true,"type":"string","format":"date-time"}},"required":["file"]},"MediaObject.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"contentUrl":{"externalDocs":{"url":"https:\/\/schema.org\/contentUrl"},"type":["string","null"]},"filePath":{"readOnly":true,"type":["string","null"]},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}}},"ShippingCompany":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"code":{"type":"string"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name","code"]},"ShippingCompany.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"code":{"type":"string"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name","code"]},"Trip":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"vessel":{"readOnly":true,"type":"string","format":"iri-reference","example":"https:\/\/example.com\/"},"vesselIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"pilotageReference":{"readOnly":true,"type":["string","null"]},"customerReference":{"type":["string","null"]},"captainName":{"type":["string","null"]},"startLocation":{"readOnly":true,"type":"string","format":"iri-reference","example":"https:\/\/example.com\/"},"startLocationIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"endLocation":{"readOnly":true,"type":"string","format":"iri-reference","example":"https:\/\/example.com\/"},"endLocationIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"startDate":{"type":"string","format":"date-time"},"endDate":{"type":"string","format":"date-time"},"note":{"type":["string","null"]},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["vesselIri","startLocationIri","endLocationIri","startDate","endDate"]},"Trip.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"vessel":{"readOnly":true,"$ref":"#\/components\/schemas\/Vessel.jsonld"},"vesselIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"pilotageReference":{"readOnly":true,"type":["string","null"]},"customerReference":{"type":["string","null"]},"captainName":{"type":["string","null"]},"startLocation":{"readOnly":true,"$ref":"#\/components\/schemas\/Location.jsonld"},"startLocationIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"endLocation":{"readOnly":true,"$ref":"#\/components\/schemas\/Location.jsonld"},"endLocationIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"startDate":{"type":"string","format":"date-time"},"endDate":{"type":"string","format":"date-time"},"note":{"type":["string","null"]},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["vesselIri","startLocationIri","endLocationIri","startDate","endDate"]},"TripLocation":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"trip":{"$ref":"#\/components\/schemas\/Trip"},"tripIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"location":{"$ref":"#\/components\/schemas\/Location"},"locationIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"isArrival":{"type":"boolean"},"date":{"type":"string","format":"date-time"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["tripIri","locationIri","date"]},"TripLocation.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"trip":{"$ref":"#\/components\/schemas\/Trip.jsonld"},"tripIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"location":{"$ref":"#\/components\/schemas\/Location.jsonld"},"locationIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"isArrival":{"type":"boolean"},"date":{"type":"string","format":"date-time"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["tripIri","locationIri","date"]},"User":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"email":{"format":"email","externalDocs":{"url":"https:\/\/schema.org\/email"},"type":"string"},"firstName":{"type":"string"},"referenceId":{"type":"string"},"lastName":{"type":"string"},"image":{"anyOf":[{"$ref":"#\/components\/schemas\/MediaObject"},{"type":"null"}]},"imageUrl":{"readOnly":true,"type":["string","null"]},"fullName":{"readOnly":true,"type":["string","null"]},"password":{"writeOnly":true,"description":"The plaintext password when being set or changed.","type":"string"},"active":{"type":"boolean"},"roles":{"readOnly":true,"type":"array","items":{"type":"string"}},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["email","firstName","referenceId","lastName"]},"User.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"email":{"format":"email","externalDocs":{"url":"https:\/\/schema.org\/email"},"type":"string"},"firstName":{"type":"string"},"referenceId":{"type":"string"},"lastName":{"type":"string"},"image":{"anyOf":[{"$ref":"#\/components\/schemas\/MediaObject.jsonld"},{"type":"null"}]},"imageUrl":{"readOnly":true,"type":["string","null"]},"fullName":{"readOnly":true,"type":["string","null"]},"password":{"writeOnly":true,"description":"The plaintext password when being set or changed.","type":"string"},"active":{"type":"boolean"},"roles":{"readOnly":true,"type":"array","items":{"type":"string"}},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["email","firstName","referenceId","lastName"]},"UserTrip":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"trip":{"readOnly":true,"type":"string","format":"iri-reference","example":"https:\/\/example.com\/"},"tripIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"user":{"readOnly":true,"type":"string","format":"iri-reference","example":"https:\/\/example.com\/"},"userIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"captainName":{"type":["string","null"]},"completed":{"type":"boolean"},"signature":{"readOnly":true,"type":"string","format":"iri-reference","example":"https:\/\/example.com\/"},"signatureIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"signatureUrl":{"readOnly":true,"type":["string","null"]},"completedDate":{"type":["string","null"],"format":"date-time"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["tripIri","userIri","completed"]},"UserTrip.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"trip":{"readOnly":true,"$ref":"#\/components\/schemas\/Trip.jsonld"},"tripIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"user":{"readOnly":true,"$ref":"#\/components\/schemas\/User.jsonld"},"userIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"captainName":{"type":["string","null"]},"completed":{"type":"boolean"},"signature":{"readOnly":true,"$ref":"#\/components\/schemas\/MediaObject.jsonld"},"signatureIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"signatureUrl":{"readOnly":true,"type":["string","null"]},"completedDate":{"type":["string","null"],"format":"date-time"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["tripIri","userIri","completed"]},"UserTripEvent":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"userTrip":{"readOnly":true,"$ref":"#\/components\/schemas\/UserTrip"},"userTripIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"event":{"readOnly":true,"type":"string","format":"iri-reference","example":"https:\/\/example.com\/"},"eventIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"date":{"type":"string","format":"date-time"},"note":{"type":["string","null"]},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["userTripIri","eventIri","date"]},"UserTripEvent.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"userTrip":{"readOnly":true,"$ref":"#\/components\/schemas\/UserTrip.jsonld"},"userTripIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"event":{"readOnly":true,"$ref":"#\/components\/schemas\/Event.jsonld"},"eventIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"date":{"type":"string","format":"date-time"},"note":{"type":["string","null"]},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["userTripIri","eventIri","date"]},"Vessel":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"code":{"type":"string"},"company":{"readOnly":true,"type":"string","format":"iri-reference","example":"https:\/\/example.com\/"},"companyIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name","code","companyIri"]},"Vessel.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"code":{"type":"string"},"company":{"readOnly":true,"$ref":"#\/components\/schemas\/ShippingCompany.jsonld"},"companyIri":{"type":["string","null"],"format":"iri-reference","example":"https:\/\/example.com\/"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name","code","companyIri"]},"Zone":{"type":"object","description":"","deprecated":false,"properties":{"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name"]},"Zone.jsonld":{"type":"object","description":"","deprecated":false,"properties":{"@context":{"readOnly":true,"oneOf":[{"type":"string"},{"type":"object","properties":{"@vocab":{"type":"string"},"hydra":{"type":"string","enum":["http:\/\/www.w3.org\/ns\/hydra\/core#"]}},"required":["@vocab","hydra"],"additionalProperties":true}]},"@id":{"readOnly":true,"type":"string"},"@type":{"readOnly":true,"type":"string"},"dbId":{"readOnly":true,"type":["integer","null"]},"name":{"type":"string"},"createdAt":{"readOnly":true,"type":["string","null"],"format":"date-time"}},"required":["name"]},"Credentials":{"type":"object","properties":{"email":{"type":"string","example":"user@example.com"},"password":{"type":"string","example":"password123"}}},"AuthResponse":{"type":"object","properties":{"@id":{"type":"string","example":"\/api\/users\/1"},"dbId":{"type":"integer","example":1},"token":{"type":"string","example":"JWT_TOKEN"}}}},"responses":{},"parameters":{},"examples":{},"requestBodies":{},"headers":{},"securitySchemes":{"JWT":{"type":"http","scheme":"bearer","bearerFormat":"JWT"}}},"security":[{"JWT":[]}],"tags":[],"webhooks":{}} \ No newline at end of file diff --git a/angular/openapi.yaml b/angular/openapi.yaml index fd7e406..586a7ed 100644 --- a/angular/openapi.yaml +++ b/angular/openapi.yaml @@ -2238,7 +2238,16 @@ components: - integer - 'null' zone: - $ref: '#/components/schemas/Zone' + readOnly: true + type: string + format: iri-reference + example: 'https://example.com/' + zoneIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' name: type: string code: @@ -2256,6 +2265,7 @@ components: - 'null' format: date-time required: + - zoneIri - name - code Location.jsonld: @@ -2292,7 +2302,14 @@ components: - integer - 'null' zone: + readOnly: true $ref: '#/components/schemas/Zone.jsonld' + zoneIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' name: type: string code: @@ -2310,6 +2327,7 @@ components: - 'null' format: date-time required: + - zoneIri - name - code MediaObject: @@ -2467,7 +2485,16 @@ components: - integer - 'null' vessel: - $ref: '#/components/schemas/Vessel' + readOnly: true + type: string + format: iri-reference + example: 'https://example.com/' + vesselIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' pilotageReference: readOnly: true type: @@ -2482,9 +2509,27 @@ components: - string - 'null' startLocation: - $ref: '#/components/schemas/Location' + readOnly: true + type: string + format: iri-reference + example: 'https://example.com/' + startLocationIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' endLocation: - $ref: '#/components/schemas/Location' + readOnly: true + type: string + format: iri-reference + example: 'https://example.com/' + endLocationIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' startDate: type: string format: date-time @@ -2502,6 +2547,9 @@ components: - 'null' format: date-time required: + - vesselIri + - startLocationIri + - endLocationIri - startDate - endDate Trip.jsonld: @@ -2538,7 +2586,14 @@ components: - integer - 'null' vessel: + readOnly: true $ref: '#/components/schemas/Vessel.jsonld' + vesselIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' pilotageReference: readOnly: true type: @@ -2553,9 +2608,23 @@ components: - string - 'null' startLocation: + readOnly: true $ref: '#/components/schemas/Location.jsonld' + startLocationIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' endLocation: + readOnly: true $ref: '#/components/schemas/Location.jsonld' + endLocationIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' startDate: type: string format: date-time @@ -2573,6 +2642,9 @@ components: - 'null' format: date-time required: + - vesselIri + - startLocationIri + - endLocationIri - startDate - endDate TripLocation: @@ -2587,8 +2659,20 @@ components: - 'null' trip: $ref: '#/components/schemas/Trip' + tripIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' location: $ref: '#/components/schemas/Location' + locationIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' isArrival: type: boolean date: @@ -2601,6 +2685,8 @@ components: - 'null' format: date-time required: + - tripIri + - locationIri - date TripLocation.jsonld: type: object @@ -2637,8 +2723,20 @@ components: - 'null' trip: $ref: '#/components/schemas/Trip.jsonld' + tripIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' location: $ref: '#/components/schemas/Location.jsonld' + locationIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' isArrival: type: boolean date: @@ -2651,6 +2749,8 @@ components: - 'null' format: date-time required: + - tripIri + - locationIri - date User: type: object @@ -2804,9 +2904,27 @@ components: - integer - 'null' trip: - $ref: '#/components/schemas/Trip' + readOnly: true + type: string + format: iri-reference + example: 'https://example.com/' + tripIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' user: - $ref: '#/components/schemas/User' + readOnly: true + type: string + format: iri-reference + example: 'https://example.com/' + userIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' captainName: type: - string @@ -2814,7 +2932,16 @@ components: completed: type: boolean signature: - $ref: '#/components/schemas/MediaObject' + readOnly: true + type: string + format: iri-reference + example: 'https://example.com/' + signatureIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' signatureUrl: readOnly: true type: @@ -2832,8 +2959,8 @@ components: - 'null' format: date-time required: - - trip - - user + - tripIri + - userIri - completed UserTrip.jsonld: type: object @@ -2869,9 +2996,23 @@ components: - integer - 'null' trip: + readOnly: true $ref: '#/components/schemas/Trip.jsonld' + tripIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' user: + readOnly: true $ref: '#/components/schemas/User.jsonld' + userIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' captainName: type: - string @@ -2879,7 +3020,14 @@ components: completed: type: boolean signature: + readOnly: true $ref: '#/components/schemas/MediaObject.jsonld' + signatureIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' signatureUrl: readOnly: true type: @@ -2897,8 +3045,8 @@ components: - 'null' format: date-time required: - - trip - - user + - tripIri + - userIri - completed UserTripEvent: type: object @@ -2913,11 +3061,23 @@ components: userTrip: readOnly: true $ref: '#/components/schemas/UserTrip' + userTripIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' event: readOnly: true type: string format: iri-reference example: 'https://example.com/' + eventIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' date: type: string format: date-time @@ -2932,6 +3092,8 @@ components: - 'null' format: date-time required: + - userTripIri + - eventIri - date UserTripEvent.jsonld: type: object @@ -2969,9 +3131,21 @@ components: userTrip: readOnly: true $ref: '#/components/schemas/UserTrip.jsonld' + userTripIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' event: readOnly: true $ref: '#/components/schemas/Event.jsonld' + eventIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' date: type: string format: date-time @@ -2986,6 +3160,8 @@ components: - 'null' format: date-time required: + - userTripIri + - eventIri - date Vessel: type: object @@ -3002,7 +3178,16 @@ components: code: type: string company: - $ref: '#/components/schemas/ShippingCompany' + readOnly: true + type: string + format: iri-reference + example: 'https://example.com/' + companyIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' createdAt: readOnly: true type: @@ -3012,6 +3197,7 @@ components: required: - name - code + - companyIri Vessel.jsonld: type: object description: '' @@ -3050,7 +3236,14 @@ components: code: type: string company: + readOnly: true $ref: '#/components/schemas/ShippingCompany.jsonld' + companyIri: + type: + - string + - 'null' + format: iri-reference + example: 'https://example.com/' createdAt: readOnly: true type: @@ -3060,6 +3253,7 @@ components: required: - name - code + - companyIri Zone: type: object description: '' diff --git a/angular/src/app/_components/_abstract/abstract-data-form-component.ts b/angular/src/app/_components/_abstract/abstract-data-form-component.ts index 4b62d6e..e0acc1e 100644 --- a/angular/src/app/_components/_abstract/abstract-data-form-component.ts +++ b/angular/src/app/_components/_abstract/abstract-data-form-component.ts @@ -64,6 +64,7 @@ export abstract class AbstractDataFormComponent { + this.data = response; this.submit.emit({ status: ModalStatus.Submitted, data: response diff --git a/angular/src/app/_forms/apiForms.ts b/angular/src/app/_forms/apiForms.ts index eaff39d..baad65a 100644 --- a/angular/src/app/_forms/apiForms.ts +++ b/angular/src/app/_forms/apiForms.ts @@ -12,6 +12,7 @@ export const eventJsonldForm = new FormGroup({ export const locationForm = new FormGroup({ dbId: new FormControl(null, []), zone: new FormControl(null, []), + zoneIri: new FormControl(null, [Validators.required]), name: new FormControl(null, [Validators.required]), code: new FormControl(null, [Validators.required]), isZone: new FormControl(null, []), @@ -23,6 +24,7 @@ export const locationForm = new FormGroup({ export const locationJsonldForm = new FormGroup({ dbId: new FormControl(null, []), zone: new FormControl(null, []), + zoneIri: new FormControl(null, [Validators.required]), name: new FormControl(null, [Validators.required]), code: new FormControl(null, [Validators.required]), isZone: new FormControl(null, []), @@ -63,11 +65,14 @@ export const shippingCompanyJsonldForm = new FormGroup({ export const tripForm = new FormGroup({ dbId: new FormControl(null, []), vessel: new FormControl(null, []), + vesselIri: new FormControl(null, [Validators.required]), pilotageReference: new FormControl(null, []), customerReference: new FormControl(null, []), captainName: new FormControl(null, []), startLocation: new FormControl(null, []), + startLocationIri: new FormControl(null, [Validators.required]), endLocation: new FormControl(null, []), + endLocationIri: new FormControl(null, [Validators.required]), startDate: new FormControl(null, [Validators.required]), endDate: new FormControl(null, [Validators.required]), note: new FormControl(null, []), @@ -77,11 +82,14 @@ export const tripForm = new FormGroup({ export const tripJsonldForm = new FormGroup({ dbId: new FormControl(null, []), vessel: new FormControl(null, []), + vesselIri: new FormControl(null, [Validators.required]), pilotageReference: new FormControl(null, []), customerReference: new FormControl(null, []), captainName: new FormControl(null, []), startLocation: new FormControl(null, []), + startLocationIri: new FormControl(null, [Validators.required]), endLocation: new FormControl(null, []), + endLocationIri: new FormControl(null, [Validators.required]), startDate: new FormControl(null, [Validators.required]), endDate: new FormControl(null, [Validators.required]), note: new FormControl(null, []), @@ -91,7 +99,9 @@ export const tripJsonldForm = new FormGroup({ export const tripLocationForm = new FormGroup({ dbId: new FormControl(null, []), trip: new FormControl(null, []), + tripIri: new FormControl(null, [Validators.required]), location: new FormControl(null, []), + locationIri: new FormControl(null, [Validators.required]), isArrival: new FormControl(null, []), date: new FormControl(null, [Validators.required]), createdAt: new FormControl(null, []) @@ -100,7 +110,9 @@ export const tripLocationForm = new FormGroup({ export const tripLocationJsonldForm = new FormGroup({ dbId: new FormControl(null, []), trip: new FormControl(null, []), + tripIri: new FormControl(null, [Validators.required]), location: new FormControl(null, []), + locationIri: new FormControl(null, [Validators.required]), isArrival: new FormControl(null, []), date: new FormControl(null, [Validators.required]), createdAt: new FormControl(null, []) @@ -138,11 +150,14 @@ export const userJsonldForm = new FormGroup({ export const userTripForm = new FormGroup({ dbId: new FormControl(null, []), - trip: new FormControl(null, [Validators.required]), - user: new FormControl(null, [Validators.required]), + trip: new FormControl(null, []), + tripIri: new FormControl(null, [Validators.required]), + user: new FormControl(null, []), + userIri: new FormControl(null, [Validators.required]), captainName: new FormControl(null, []), completed: new FormControl(null, [Validators.required]), signature: new FormControl(null, []), + signatureIri: new FormControl(null, []), signatureUrl: new FormControl(null, []), completedDate: new FormControl(null, []), createdAt: new FormControl(null, []) @@ -150,11 +165,14 @@ export const userTripForm = new FormGroup({ export const userTripJsonldForm = new FormGroup({ dbId: new FormControl(null, []), - trip: new FormControl(null, [Validators.required]), - user: new FormControl(null, [Validators.required]), + trip: new FormControl(null, []), + tripIri: new FormControl(null, [Validators.required]), + user: new FormControl(null, []), + userIri: new FormControl(null, [Validators.required]), captainName: new FormControl(null, []), completed: new FormControl(null, [Validators.required]), signature: new FormControl(null, []), + signatureIri: new FormControl(null, []), signatureUrl: new FormControl(null, []), completedDate: new FormControl(null, []), createdAt: new FormControl(null, []) @@ -163,7 +181,9 @@ export const userTripJsonldForm = new FormGroup({ export const userTripEventForm = new FormGroup({ dbId: new FormControl(null, []), userTrip: new FormControl(null, []), + userTripIri: new FormControl(null, [Validators.required]), event: new FormControl(null, []), + eventIri: new FormControl(null, [Validators.required]), date: new FormControl(null, [Validators.required]), note: new FormControl(null, []), createdAt: new FormControl(null, []) @@ -172,7 +192,9 @@ export const userTripEventForm = new FormGroup({ export const userTripEventJsonldForm = new FormGroup({ dbId: new FormControl(null, []), userTrip: new FormControl(null, []), + userTripIri: new FormControl(null, [Validators.required]), event: new FormControl(null, []), + eventIri: new FormControl(null, [Validators.required]), date: new FormControl(null, [Validators.required]), note: new FormControl(null, []), createdAt: new FormControl(null, []) @@ -183,6 +205,7 @@ export const vesselForm = new FormGroup({ name: new FormControl(null, [Validators.required]), code: new FormControl(null, [Validators.required]), company: new FormControl(null, []), + companyIri: new FormControl(null, [Validators.required]), createdAt: new FormControl(null, []) }); @@ -191,6 +214,7 @@ export const vesselJsonldForm = new FormGroup({ name: new FormControl(null, [Validators.required]), code: new FormControl(null, [Validators.required]), company: new FormControl(null, []), + companyIri: new FormControl(null, [Validators.required]), createdAt: new FormControl(null, []) }); diff --git a/angular/src/app/_helpers/app-helper.service.ts b/angular/src/app/_helpers/app-helper.service.ts index 49ee190..9e31f3b 100644 --- a/angular/src/app/_helpers/app-helper.service.ts +++ b/angular/src/app/_helpers/app-helper.service.ts @@ -84,4 +84,33 @@ export class AppHelperService { return JSON.stringify(obj, null, 2); // Das `null, 2` formatiert das JSON mit Einrückungen } + public convertJsonldToJson(jsonldObj: any): T { + + // Erstelle ein neues Objekt ohne die JSON-LD spezifischen Eigenschaften + const result: any = {}; + + // Kopiere alle Eigenschaften außer context, id und type + for (const key in jsonldObj) { + if ( + jsonldObj.hasOwnProperty(key) && + key !== 'context' && + key !== 'id' && + key !== 'type' + ) { + // Wenn der Wert ein Objekt ist und JSON-LD Metadaten enthält, konvertiere es rekursiv + if ( + typeof jsonldObj[key] === 'object' && + jsonldObj[key] !== null && + (jsonldObj[key].context || jsonldObj[key].id || jsonldObj[key].type) + ) { + result[key] = this.convertJsonldToJson(jsonldObj[key]); + } else { + result[key] = jsonldObj[key]; + } + } + } + + return result as T; + } + } \ No newline at end of file diff --git a/angular/src/app/_views/location/location-form/location-form.component.html b/angular/src/app/_views/location/location-form/location-form.component.html index 525ce0e..20dcbad 100644 --- a/angular/src/app/_views/location/location-form/location-form.component.html +++ b/angular/src/app/_views/location/location-form/location-form.component.html @@ -13,18 +13,18 @@
- + - +
diff --git a/angular/src/app/_views/location/location-form/location-form.component.ts b/angular/src/app/_views/location/location-form/location-form.component.ts index 603db88..a087932 100644 --- a/angular/src/app/_views/location/location-form/location-form.component.ts +++ b/angular/src/app/_views/location/location-form/location-form.component.ts @@ -8,6 +8,7 @@ import { ListGetDataFunctionType } from "@app/_components/list/list-get-data-fun import { TranslateService } from "@ngx-translate/core"; import { Router } from "@angular/router"; import { ROUTE_BASE_DATA } from "@app/app-routing.module"; +import {AppHelperService} from "@app/_helpers/app-helper.service"; @Component({ selector: 'app-location-form', @@ -21,13 +22,17 @@ export class LocationFormComponent extends AbstractDataFormComponent this.locationService.locationsPost(data), - (id: string | number, data: LocationJsonld) => this.locationService.locationsIdPatch(id.toString(), data), + (id: string | number, data: LocationJsonld) => this.locationService.locationsIdPatch( + id.toString(), + this.appHelperService.convertJsonldToJson(data) + ), (id: string | number) => this.locationService.locationsIdDelete(id.toString()), translateService, router diff --git a/angular/src/app/_views/trip/trip-detail/trip-detail.component.html b/angular/src/app/_views/trip/trip-detail/trip-detail.component.html index c671581..9033ed9 100644 --- a/angular/src/app/_views/trip/trip-detail/trip-detail.component.html +++ b/angular/src/app/_views/trip/trip-detail/trip-detail.component.html @@ -22,13 +22,13 @@
@@ -104,7 +104,7 @@ [getDataFunction]="getUsers" [displayedDataField]="'fullName'" [listColDefinitions]="userColDefinitions" - [dataSet]="userTrip.user" + [dataSet]="userTrip.userIri" (change)="onUserSelectChange(i)" > diff --git a/angular/src/app/_views/trip/trip-detail/trip-detail.component.ts b/angular/src/app/_views/trip/trip-detail/trip-detail.component.ts index ed6c9ff..740aa69 100644 --- a/angular/src/app/_views/trip/trip-detail/trip-detail.component.ts +++ b/angular/src/app/_views/trip/trip-detail/trip-detail.component.ts @@ -111,7 +111,7 @@ export class TripDetailComponent implements OnInit, AfterViewInit { // IDs aus bestehenden UserTrips (mit gültiger ID) this.userTrips .filter(ut => ut.user && ut.user.id) - .forEach(ut => assignedUserIds.push(this.appHelperService.extractId(ut.user.id!))); + .forEach(ut => assignedUserIds.push(this.appHelperService.extractId(ut.user?.id!))); // IDs aus aktuellen Formularwerten (auch für noch nicht gespeicherte Einträge) this.userForms.forEach(form => { @@ -120,7 +120,6 @@ export class TripDetailComponent implements OnInit, AfterViewInit { assignedUserIds.push(this.appHelperService.extractId(userValue)); } }); - console.log(assignedUserIds); // Filtere Benutzer, die bereits ausgewählt sind (gespeichert oder nicht) return this.userService.usersGetCollection(page, pageSize, undefined, term).pipe( @@ -191,11 +190,10 @@ export class TripDetailComponent implements OnInit, AfterViewInit { addNewTripLocation() { // Create a new empty trip location const newTripLocation: TripLocationJsonld = { - trip: { - 'id': this.trip.id // Ensure we send the trip ID in the correct format - } as TripJsonld, + tripIri: this.trip.id!, date: new Date().toISOString(), - isArrival: false + isArrival: false, + locationIri: null }; this.tripLocations.push(newTripLocation); @@ -321,7 +319,7 @@ export class TripDetailComponent implements OnInit, AfterViewInit { // Update existing return firstValueFrom(this.tripLocationService.tripLocationsIdPatch( this.appHelperService.extractId(tripLocation.id), - tripLocation + this.appHelperService.convertJsonldToJson(tripLocation) )); } else { // Create new @@ -348,9 +346,7 @@ export class TripDetailComponent implements OnInit, AfterViewInit { if (userFormValue) { // If just an ID was set, create a proper user object if (typeof userFormValue === 'string') { - userTrip.user = { - 'id': userFormValue - } as UserJsonld; + userTrip.userIri = userFormValue; } } }); @@ -370,7 +366,7 @@ export class TripDetailComponent implements OnInit, AfterViewInit { // Update existing return firstValueFrom(this.userTripService.userTripsIdPatch( this.appHelperService.extractId(userTrip.id), - userTrip + this.appHelperService.convertJsonldToJson(userTrip) )); } else { // Create new diff --git a/angular/src/app/_views/trip/trip-form/trip-form.component.html b/angular/src/app/_views/trip/trip-form/trip-form.component.html index 323abbf..4e40723 100644 --- a/angular/src/app/_views/trip/trip-form/trip-form.component.html +++ b/angular/src/app/_views/trip/trip-form/trip-form.component.html @@ -7,46 +7,46 @@
- + - +
- + - +
- + - +
diff --git a/angular/src/app/_views/trip/trip-form/trip-form.component.ts b/angular/src/app/_views/trip/trip-form/trip-form.component.ts index 7a56115..b588d09 100644 --- a/angular/src/app/_views/trip/trip-form/trip-form.component.ts +++ b/angular/src/app/_views/trip/trip-form/trip-form.component.ts @@ -15,6 +15,7 @@ import {Router} from "@angular/router"; import {ROUTE_BASE_DATA} from "@app/app-routing.module"; import {ListColDefinition} from "@app/_components/list/list-col-definition"; import {ListGetDataFunctionType} from "@app/_components/list/list-get-data-function-type"; +import {AppHelperService} from "@app/_helpers/app-helper.service"; @Component({ selector: 'app-trip-form', @@ -32,13 +33,18 @@ export class TripFormComponent extends AbstractDataFormComponent { private tripService: TripService, private vesselService: VesselService, private locationService: LocationService, + private appHelperService: AppHelperService, translateService: TranslateService, router: Router ) { super( tripForm, (data: TripJsonld) => this.tripService.tripsPost(data), - (id: string | number, data: TripJsonld) => this.tripService.tripsIdPatch(id.toString(), data), + (id: string | number, data: TripJsonld) => + this.tripService.tripsIdPatch( + id.toString(), + this.appHelperService.convertJsonldToJson(data) + ), (id: string | number) => this.tripService.tripsIdDelete(id.toString()), translateService, router diff --git a/angular/src/app/_views/user-trip/user-trip-detail/user-trip-detail.component.html b/angular/src/app/_views/user-trip/user-trip-detail/user-trip-detail.component.html index 9af4595..11d13d5 100644 --- a/angular/src/app/_views/user-trip/user-trip-detail/user-trip-detail.component.html +++ b/angular/src/app/_views/user-trip/user-trip-detail/user-trip-detail.component.html @@ -2,7 +2,7 @@

{{ ('basic.edit') | translate }} {{ 'model.user_trip' | translate }} - {{ userTrip.trip.pilotageReference }} ({{ userTrip.user.fullName }})

+ {{ userTrip.trip?.pilotageReference }} ({{ userTrip.user?.fullName }})
diff --git a/angular/src/app/_views/user-trip/user-trip-form/user-trip-form.component.html b/angular/src/app/_views/user-trip/user-trip-form/user-trip-form.component.html index 039d4cf..4eede62 100644 --- a/angular/src/app/_views/user-trip/user-trip-form/user-trip-form.component.html +++ b/angular/src/app/_views/user-trip/user-trip-form/user-trip-form.component.html @@ -3,9 +3,9 @@ @if (data !== undefined) { - - - + + +
@@ -21,13 +21,22 @@
- + + + + @if (selectedFile) { {{ selectedFile.name }} } - @if (data.signatureUrl) { -
+ + @if (data.signatureUrl && showSignatureImage) { +
Signatur +
}
@@ -37,7 +46,8 @@
- diff --git a/angular/src/app/_views/user-trip/user-trip-form/user-trip-form.component.ts b/angular/src/app/_views/user-trip/user-trip-form/user-trip-form.component.ts index d2a8e03..0bbf478 100644 --- a/angular/src/app/_views/user-trip/user-trip-form/user-trip-form.component.ts +++ b/angular/src/app/_views/user-trip/user-trip-form/user-trip-form.component.ts @@ -1,21 +1,18 @@ import { Component } from '@angular/core'; import { - AbstractDataFormComponent, - FormMode, - FormSubmitEvent + AbstractDataFormComponent, FormSubmitEvent, } from "@app/_components/_abstract/abstract-data-form-component"; import { - LocationService, MediaObjectJsonld, MediaObjectService, TripJsonld, UserTrip, + MediaObjectService, UserTripJsonld, UserTripService, - VesselService } from "@app/core/api/v1"; -import { tripForm, userTripForm } from "@app/_forms/apiForms"; +import { userTripForm } from "@app/_forms/apiForms"; import { TranslateService } from "@ngx-translate/core"; import { Router } from "@angular/router"; import { ROUTE_USER_TRIPS } from "@app/app-routing.module"; import { ModalStatus } from "@app/_helpers/modal.states"; -import { firstValueFrom } from 'rxjs'; +import {AppHelperService} from "@app/_helpers/app-helper.service"; @Component({ selector: 'app-user-trip-form', @@ -26,17 +23,24 @@ export class UserTripFormComponent extends AbstractDataFormComponent this.userTripService.userTripsIdPatch(id.toString(), data), + (id: string | number, data: UserTripJsonld) => + this.userTripService.userTripsIdPatch( + id.toString(), + this.appHelperService.convertJsonldToJson(data) + ), (id: string | number) => this.userTripService.userTripsIdDelete(id.toString()), translateService, router @@ -47,18 +51,24 @@ export class UserTripFormComponent extends AbstractDataFormComponent { - console.log('Form status:', status); - console.log('Form errors:', this.form.errors); - - Object.keys(this.form.controls).forEach(key => { - const control = this.form.get(key); - if (control?.invalid) { - console.log(`Control '${key}' is invalid:`, control.errors); - } - }); + this.submit.subscribe((event: FormSubmitEvent) => { + if (event.status === ModalStatus.Submitted) { + this.updateImageStatus(); + } }); + + // Debug-Ausgabe für Formularvalidierung + // this.form.statusChanges.subscribe(status => { + // console.log('Form status:', status); + // console.log('Form errors:', this.form.errors); + // + // Object.keys(this.form.controls).forEach(key => { + // const control = this.form.get(key); + // if (control?.invalid) { + // console.log(`Control '${key}' is invalid:`, control.errors); + // } + // }); + // }); } onFileSelected(event: Event): void { @@ -73,29 +83,105 @@ export class UserTripFormComponent extends AbstractDataFormComponent { + // const control = this.form.get(key); + // if (control?.invalid) { + // console.log(`Control '${key}' is invalid:`, control.errors); + // } + // }); + return; + } - if (!this.selectedFile) { - const currentValue = this.form.get('signature')?.value; - if (currentValue === null) { - this.form.patchValue({ - signature: undefined + // Drei Fälle: + // 1. Ein neues Bild wurde ausgewählt + // 2. Ein bestehendes Bild soll gelöscht werden + // 3. Keine Änderungen am Bild + + if (this.selectedFile && this.signatureToDelete) { + // Fall 1a: Ein neues Bild wurde ausgewählt UND ein altes soll gelöscht werden + // Zuerst das alte Bild löschen, dann das neue hochladen + if (this.data?.signature?.dbId) { + this.mediaObjectService.mediaObjectsIdDelete(this.data?.signature?.dbId?.toString()).subscribe({ + next: () => { + // Altes Bild wurde gelöscht, jetzt neues hochladen + this.uploadNewFile(); + }, + error: (error) => { + console.error('Error deleting signature:', error); + // Trotz Fehler neues Bild hochladen + this.uploadNewFile(); + } }); } + + } else if (this.selectedFile) { + // Fall 1b: Nur ein neues Bild wurde ausgewählt (kein altes vorhanden) + this.uploadNewFile(); + } else if (this.signatureToDelete && this.data?.signature?.dbId) { + // Fall 2: Nur ein bestehendes Bild soll gelöscht werden + this.mediaObjectService.mediaObjectsIdDelete(this.data?.signature?.dbId?.toString()).subscribe({ + next: () => { + this.signatureToDelete = null; + super.onSubmit(); + }, + error: (error) => { + console.error('Error deleting signature:', error); + super.onSubmit(); + } + }); + } else { + // Fall 3: Keine Änderungen am Bild super.onSubmit(); - return; } + } + + private uploadNewFile(): void { + if (!this.selectedFile) return; - // 1. Handle file upload if a file is selected this.mediaObjectService.mediaObjectsPost(this.selectedFile).subscribe({ next: (mediaObject) => { - // 2. Update the form data with the new mediaObject - console.log(mediaObject.id); + // Aktualisiere die Formulardaten mit dem neuen mediaObject this.form.patchValue({ - signature: mediaObject.id + signatureIri: mediaObject.id }); - // 3. Call the parent method to handle the standard save process + // Rufe die übergeordnete Methode auf, um den Standard-Speicherprozess zu verarbeiten super.onSubmit(); }, error: (error) => { diff --git a/angular/src/app/_views/vessel/vessel-form/vessel-form.component.html b/angular/src/app/_views/vessel/vessel-form/vessel-form.component.html index 374ae84..d48b4a3 100644 --- a/angular/src/app/_views/vessel/vessel-form/vessel-form.component.html +++ b/angular/src/app/_views/vessel/vessel-form/vessel-form.component.html @@ -23,17 +23,17 @@
- + + [dataSet]="data?.companyIri"> - +
diff --git a/angular/src/app/_views/vessel/vessel-form/vessel-form.component.ts b/angular/src/app/_views/vessel/vessel-form/vessel-form.component.ts index 432a122..4522c5e 100644 --- a/angular/src/app/_views/vessel/vessel-form/vessel-form.component.ts +++ b/angular/src/app/_views/vessel/vessel-form/vessel-form.component.ts @@ -8,6 +8,7 @@ import { AbstractDataFormComponent } from "@app/_components/_abstract/abstract-d import { TranslateService } from "@ngx-translate/core"; import { Router } from "@angular/router"; import { ROUTE_BASE_DATA } from "@app/app-routing.module"; +import {AppHelperService} from "@app/_helpers/app-helper.service"; @Component({ selector: 'app-vessel-form', @@ -20,13 +21,18 @@ export class VesselFormComponent extends AbstractDataFormComponent constructor( private vesselService: VesselService, private shippingCompanyService: ShippingCompanyService, + private appHelperService: AppHelperService, translateService: TranslateService, router: Router ) { super( vesselForm, (data: VesselJsonld) => this.vesselService.vesselsPost(data), - (id: string | number, data: VesselJsonld) => this.vesselService.vesselsIdPatch(id.toString(), data), + (id: string | number, data: VesselJsonld) => + this.vesselService.vesselsIdPatch( + id.toString(), + this.appHelperService.convertJsonldToJson(data) + ), (id: string | number) => this.vesselService.vesselsIdDelete(id.toString()), translateService, router diff --git a/angular/src/app/core/api/v1/model/location.ts b/angular/src/app/core/api/v1/model/location.ts index 882cf6c..76f7f56 100644 --- a/angular/src/app/core/api/v1/model/location.ts +++ b/angular/src/app/core/api/v1/model/location.ts @@ -9,7 +9,6 @@ * https://openapi-generator.tech * Do not edit the class manually. */ -import { Zone } from './zone'; /** @@ -17,7 +16,8 @@ import { Zone } from './zone'; */ export interface Location { readonly dbId?: number | null; - zone?: Zone; + readonly zone?: string; + zoneIri: string | null; name: string; code: string; isZone?: boolean; diff --git a/angular/src/app/core/api/v1/model/locationJsonld.ts b/angular/src/app/core/api/v1/model/locationJsonld.ts index 2cbe90c..ed7c37c 100644 --- a/angular/src/app/core/api/v1/model/locationJsonld.ts +++ b/angular/src/app/core/api/v1/model/locationJsonld.ts @@ -21,7 +21,8 @@ export interface LocationJsonld { readonly id?: string; readonly type?: string; readonly dbId?: number | null; - zone?: ZoneJsonld; + readonly zone?: ZoneJsonld; + zoneIri: string | null; name: string; code: string; isZone?: boolean; diff --git a/angular/src/app/core/api/v1/model/trip.ts b/angular/src/app/core/api/v1/model/trip.ts index e02fb15..a0d6a08 100644 --- a/angular/src/app/core/api/v1/model/trip.ts +++ b/angular/src/app/core/api/v1/model/trip.ts @@ -9,8 +9,6 @@ * https://openapi-generator.tech * Do not edit the class manually. */ -import { Vessel } from './vessel'; -import { Location } from './location'; /** @@ -18,12 +16,15 @@ import { Location } from './location'; */ export interface Trip { readonly dbId?: number | null; - vessel?: Vessel; + readonly vessel?: string; + vesselIri: string | null; readonly pilotageReference?: string | null; customerReference?: string | null; captainName?: string | null; - startLocation?: Location; - endLocation?: Location; + readonly startLocation?: string; + startLocationIri: string | null; + readonly endLocation?: string; + endLocationIri: string | null; startDate: string; endDate: string; note?: string | null; diff --git a/angular/src/app/core/api/v1/model/tripJsonld.ts b/angular/src/app/core/api/v1/model/tripJsonld.ts index b6714cf..911490f 100644 --- a/angular/src/app/core/api/v1/model/tripJsonld.ts +++ b/angular/src/app/core/api/v1/model/tripJsonld.ts @@ -22,12 +22,15 @@ export interface TripJsonld { readonly id?: string; readonly type?: string; readonly dbId?: number | null; - vessel?: VesselJsonld; + readonly vessel?: VesselJsonld; + vesselIri: string | null; readonly pilotageReference?: string | null; customerReference?: string | null; captainName?: string | null; - startLocation?: LocationJsonld; - endLocation?: LocationJsonld; + readonly startLocation?: LocationJsonld; + startLocationIri: string | null; + readonly endLocation?: LocationJsonld; + endLocationIri: string | null; startDate: string; endDate: string; note?: string | null; diff --git a/angular/src/app/core/api/v1/model/tripLocation.ts b/angular/src/app/core/api/v1/model/tripLocation.ts index bce4946..364cc83 100644 --- a/angular/src/app/core/api/v1/model/tripLocation.ts +++ b/angular/src/app/core/api/v1/model/tripLocation.ts @@ -19,7 +19,9 @@ import { Location } from './location'; export interface TripLocation { readonly dbId?: number | null; trip?: Trip; + tripIri: string | null; location?: Location; + locationIri: string | null; isArrival?: boolean; date: string; readonly createdAt?: string | null; diff --git a/angular/src/app/core/api/v1/model/tripLocationJsonld.ts b/angular/src/app/core/api/v1/model/tripLocationJsonld.ts index 4ac46eb..e9a48ca 100644 --- a/angular/src/app/core/api/v1/model/tripLocationJsonld.ts +++ b/angular/src/app/core/api/v1/model/tripLocationJsonld.ts @@ -23,7 +23,9 @@ export interface TripLocationJsonld { readonly type?: string; readonly dbId?: number | null; trip?: TripJsonld; + tripIri: string | null; location?: LocationJsonld; + locationIri: string | null; isArrival?: boolean; date: string; readonly createdAt?: string | null; diff --git a/angular/src/app/core/api/v1/model/userTrip.ts b/angular/src/app/core/api/v1/model/userTrip.ts index 880a96e..76832ab 100644 --- a/angular/src/app/core/api/v1/model/userTrip.ts +++ b/angular/src/app/core/api/v1/model/userTrip.ts @@ -9,9 +9,6 @@ * https://openapi-generator.tech * Do not edit the class manually. */ -import { Trip } from './trip'; -import { User } from './user'; -import { MediaObject } from './mediaObject'; /** @@ -19,11 +16,14 @@ import { MediaObject } from './mediaObject'; */ export interface UserTrip { readonly dbId?: number | null; - trip: Trip; - user: User; + readonly trip?: string; + tripIri: string | null; + readonly user?: string; + userIri: string | null; captainName?: string | null; completed: boolean; - signature?: MediaObject; + readonly signature?: string; + signatureIri?: string | null; readonly signatureUrl?: string | null; completedDate?: string | null; readonly createdAt?: string | null; diff --git a/angular/src/app/core/api/v1/model/userTripEvent.ts b/angular/src/app/core/api/v1/model/userTripEvent.ts index 7f77a57..47fa422 100644 --- a/angular/src/app/core/api/v1/model/userTripEvent.ts +++ b/angular/src/app/core/api/v1/model/userTripEvent.ts @@ -18,7 +18,9 @@ import { UserTrip } from './userTrip'; export interface UserTripEvent { readonly dbId?: number | null; readonly userTrip?: UserTrip; + userTripIri: string | null; readonly event?: string; + eventIri: string | null; date: string; note?: string | null; readonly createdAt?: string | null; diff --git a/angular/src/app/core/api/v1/model/userTripEventJsonld.ts b/angular/src/app/core/api/v1/model/userTripEventJsonld.ts index c37c977..c104d3e 100644 --- a/angular/src/app/core/api/v1/model/userTripEventJsonld.ts +++ b/angular/src/app/core/api/v1/model/userTripEventJsonld.ts @@ -23,7 +23,9 @@ export interface UserTripEventJsonld { readonly type?: string; readonly dbId?: number | null; readonly userTrip?: UserTripJsonld; + userTripIri: string | null; readonly event?: EventJsonld; + eventIri: string | null; date: string; note?: string | null; readonly createdAt?: string | null; diff --git a/angular/src/app/core/api/v1/model/userTripJsonld.ts b/angular/src/app/core/api/v1/model/userTripJsonld.ts index 169965b..3acecf9 100644 --- a/angular/src/app/core/api/v1/model/userTripJsonld.ts +++ b/angular/src/app/core/api/v1/model/userTripJsonld.ts @@ -23,11 +23,14 @@ export interface UserTripJsonld { readonly id?: string; readonly type?: string; readonly dbId?: number | null; - trip: TripJsonld; - user: UserJsonld; + readonly trip?: TripJsonld; + tripIri: string | null; + readonly user?: UserJsonld; + userIri: string | null; captainName?: string | null; completed: boolean; - signature?: MediaObjectJsonld; + readonly signature?: MediaObjectJsonld; + signatureIri?: string | null; readonly signatureUrl?: string | null; completedDate?: string | null; readonly createdAt?: string | null; diff --git a/angular/src/app/core/api/v1/model/vessel.ts b/angular/src/app/core/api/v1/model/vessel.ts index ba59e0e..b9b3c7c 100644 --- a/angular/src/app/core/api/v1/model/vessel.ts +++ b/angular/src/app/core/api/v1/model/vessel.ts @@ -9,7 +9,6 @@ * https://openapi-generator.tech * Do not edit the class manually. */ -import { ShippingCompany } from './shippingCompany'; /** @@ -19,7 +18,8 @@ export interface Vessel { readonly dbId?: number | null; name: string; code: string; - company?: ShippingCompany; + readonly company?: string; + companyIri: string | null; readonly createdAt?: string | null; } diff --git a/angular/src/app/core/api/v1/model/vesselJsonld.ts b/angular/src/app/core/api/v1/model/vesselJsonld.ts index bc50be4..a81da77 100644 --- a/angular/src/app/core/api/v1/model/vesselJsonld.ts +++ b/angular/src/app/core/api/v1/model/vesselJsonld.ts @@ -23,7 +23,8 @@ export interface VesselJsonld { readonly dbId?: number | null; name: string; code: string; - company?: ShippingCompanyJsonld; + readonly company?: ShippingCompanyJsonld; + companyIri: string | null; readonly createdAt?: string | null; } diff --git a/httpdocs/src/ApiResource/LocationApi.php b/httpdocs/src/ApiResource/LocationApi.php index daeb8c9..a22d290 100644 --- a/httpdocs/src/ApiResource/LocationApi.php +++ b/httpdocs/src/ApiResource/LocationApi.php @@ -19,6 +19,7 @@ use App\State\EntityClassDtoStateProcessor; use App\State\EntityToDtoStateProvider; use Symfony\Component\Validator\Constraints as Assert; use Symfony\Component\PropertyInfo\Type; +use Symfony\Component\Validator\Constraints\NotBlank; #[ApiResource( shortName: 'Location', @@ -61,9 +62,9 @@ class LocationApi * @var ZoneApi */ #[ApiProperty( - writable: true, + writable: false, readableLink: true, - writableLink: true, + writableLink: false, builtinTypes: [ new Type( 'object', @@ -73,6 +74,10 @@ class LocationApi )] public ?ZoneApi $zone = null; + #[NotBlank] + #[ApiProperty(writable: true)] + public ?ZoneApi $zoneIri = null; + #[Assert\NotBlank] public string $name; diff --git a/httpdocs/src/ApiResource/TripApi.php b/httpdocs/src/ApiResource/TripApi.php index 0565b97..84cd421 100644 --- a/httpdocs/src/ApiResource/TripApi.php +++ b/httpdocs/src/ApiResource/TripApi.php @@ -19,6 +19,7 @@ use App\State\EntityClassDtoStateProcessor; use App\State\EntityToDtoStateProvider; use Symfony\Component\Validator\Constraints as Assert; use Symfony\Component\PropertyInfo\Type; +use Symfony\Component\Validator\Constraints\NotBlank; #[ApiResource( shortName: 'Trip', @@ -57,22 +58,26 @@ class TripApi #[ApiProperty(writable: false)] public ?int $dbId = null; -// /** -// * @var VesselApi -// */ -// #[ApiProperty( -// writable: true, -// readableLink: true, -// writableLink: false, -// builtinTypes: [ -// new Type( -// 'object', -// class: VesselApi::class, -// ) -// ] -// )] + /** + * @var VesselApi + */ + #[ApiProperty( + writable: false, + readableLink: true, + writableLink: false, + builtinTypes: [ + new Type( + 'object', + class: VesselApi::class, + ) + ] + )] public ?VesselApi $vessel = null; + #[NotBlank] + #[ApiProperty(writable: true)] + public ?VesselApi $vesselIri = null; + #[ApiProperty(writable: false)] public ?string $pilotageReference = null; @@ -80,38 +85,46 @@ class TripApi public ?string $captainName = null; -// /** -// * @var LocationApi -// */ -// #[ApiProperty( -// writable: true, -// readableLink: true, -// writableLink: false, -// builtinTypes: [ -// new Type( -// 'object', -// class: LocationApi::class, -// ) -// ] -// )] + /** + * @var LocationApi + */ + #[ApiProperty( + writable: false, + readableLink: true, + writableLink: false, + builtinTypes: [ + new Type( + 'object', + class: LocationApi::class, + ) + ] + )] public ?LocationApi $startLocation = null; -// /** -// * @var LocationApi -// */ -// #[ApiProperty( -// writable: true, -// readableLink: true, -// writableLink: false, -// builtinTypes: [ -// new Type( -// 'object', -// class: LocationApi::class, -// ) -// ] -// )] + #[NotBlank] + #[ApiProperty(writable: true)] + public ?LocationApi $startLocationIri = null; + + /** + * @var LocationApi + */ + #[ApiProperty( + writable: false, + readableLink: true, + writableLink: false, + builtinTypes: [ + new Type( + 'object', + class: LocationApi::class, + ) + ] + )] public ?LocationApi $endLocation = null; + #[NotBlank] + #[ApiProperty(writable: true)] + public ?LocationApi $endLocationIri = null; + #[Assert\NotBlank] public \DateTimeImmutable $startDate; diff --git a/httpdocs/src/ApiResource/TripLocationApi.php b/httpdocs/src/ApiResource/TripLocationApi.php index 013e860..eb76051 100644 --- a/httpdocs/src/ApiResource/TripLocationApi.php +++ b/httpdocs/src/ApiResource/TripLocationApi.php @@ -19,6 +19,7 @@ use App\State\EntityClassDtoStateProcessor; use App\State\EntityToDtoStateProvider; use Symfony\Component\Validator\Constraints as Assert; use Symfony\Component\PropertyInfo\Type; +use Symfony\Component\Validator\Constraints\NotBlank; #[ApiResource( shortName: 'TripLocation', @@ -73,6 +74,10 @@ class TripLocationApi )] public ?TripApi $trip = null; + #[NotBlank] + #[ApiProperty(writable: true)] + public ?TripApi $tripIri = null; + /** * @var LocationApi */ @@ -89,6 +94,10 @@ class TripLocationApi )] public ?LocationApi $location = null; + #[NotBlank] + #[ApiProperty(writable: true)] + public ?LocationApi $locationIri = null; + public bool $isArrival; #[Assert\NotBlank] diff --git a/httpdocs/src/ApiResource/UserTripApi.php b/httpdocs/src/ApiResource/UserTripApi.php index 0b5be8e..42ba19b 100644 --- a/httpdocs/src/ApiResource/UserTripApi.php +++ b/httpdocs/src/ApiResource/UserTripApi.php @@ -20,6 +20,7 @@ use App\State\EntityClassDtoStateProcessor; use App\State\EntityToDtoStateProvider; use Symfony\Component\Validator\Constraints as Assert; use Symfony\Component\PropertyInfo\Type; +use Symfony\Component\Validator\Constraints\NotBlank; #[ApiResource( shortName: 'UserTrip', @@ -63,9 +64,9 @@ class UserTripApi * @var TripApi */ #[ApiProperty( - writable: true, + writable: false, readableLink: true, - writableLink: true, + writableLink: false, builtinTypes: [ new Type( 'object', @@ -73,16 +74,19 @@ class UserTripApi ) ] )] - #[Assert\NotBlank] public ?TripApi $trip = null; + #[NotBlank] + #[ApiProperty(writable: true)] + public ?TripApi $tripIri = null; + /** * @var UserApi */ #[ApiProperty( - writable: true, + writable: false, readableLink: true, - writableLink: true, + writableLink: false, builtinTypes: [ new Type( 'object', @@ -90,9 +94,12 @@ class UserTripApi ) ] )] - #[Assert\NotBlank] public ?UserApi $user = null; + #[NotBlank] + #[ApiProperty(writable: true)] + public ?UserApi $userIri = null; + public ?string $captainName = null; #[Assert\NotNull] @@ -102,9 +109,9 @@ class UserTripApi * @var MediaObjectApi */ #[ApiProperty( - writable: true, + writable: false, readableLink: true, - writableLink: true, + writableLink: false, builtinTypes: [ new Type( 'object', @@ -114,6 +121,9 @@ class UserTripApi )] public ?MediaObjectApi $signature = null; + #[ApiProperty(writable: true)] + public ?MediaObjectApi $signatureIri = null; + #[ApiProperty(writable: false)] public ?string $signatureUrl = null; diff --git a/httpdocs/src/ApiResource/UserTripEventApi.php b/httpdocs/src/ApiResource/UserTripEventApi.php index 9fcf1c3..4432f9a 100644 --- a/httpdocs/src/ApiResource/UserTripEventApi.php +++ b/httpdocs/src/ApiResource/UserTripEventApi.php @@ -15,6 +15,7 @@ use App\State\EntityClassDtoStateProcessor; use App\State\EntityToDtoStateProvider; use Symfony\Component\Validator\Constraints as Assert; use Symfony\Component\PropertyInfo\Type; +use Symfony\Component\Validator\Constraints\NotBlank; #[ApiResource( shortName: 'UserTripEvent', @@ -61,6 +62,10 @@ class UserTripEventApi )] public ?UserTripApi $userTrip = null; + #[NotBlank] + #[ApiProperty(writable: true)] + public ?UserTripApi $userTripIri = null; + /** * @var EventApi */ @@ -77,6 +82,10 @@ class UserTripEventApi )] public ?EventApi $event = null; + #[NotBlank] + #[ApiProperty(writable: true)] + public ?EventApi $eventIri = null; + #[Assert\NotBlank] public \DateTimeImmutable $date; diff --git a/httpdocs/src/ApiResource/VesselApi.php b/httpdocs/src/ApiResource/VesselApi.php index 1064708..28e361b 100644 --- a/httpdocs/src/ApiResource/VesselApi.php +++ b/httpdocs/src/ApiResource/VesselApi.php @@ -19,6 +19,7 @@ use App\State\EntityClassDtoStateProcessor; use App\State\EntityToDtoStateProvider; use Symfony\Component\Validator\Constraints as Assert; use Symfony\Component\PropertyInfo\Type; +use Symfony\Component\Validator\Constraints\NotBlank; #[ApiResource( shortName: 'Vessel', @@ -67,9 +68,9 @@ class VesselApi * @var ShippingCompanyApi */ #[ApiProperty( - writable: true, + writable: false, readableLink: true, - writableLink: true, + writableLink: false, builtinTypes: [ new Type( 'object', @@ -79,6 +80,10 @@ class VesselApi )] public ?ShippingCompanyApi $company = null; + #[NotBlank] + #[ApiProperty(writable: true)] + public ?ShippingCompanyApi $companyIri = null; + #[ApiProperty(writable: false)] public ?\DateTimeImmutable $createdAt = null; } \ No newline at end of file diff --git a/httpdocs/src/Mapper/LocationEntityToApiMapper.php b/httpdocs/src/Mapper/LocationEntityToApiMapper.php index d97fbc7..a90adaa 100644 --- a/httpdocs/src/Mapper/LocationEntityToApiMapper.php +++ b/httpdocs/src/Mapper/LocationEntityToApiMapper.php @@ -43,7 +43,7 @@ class LocationEntityToApiMapper implements MapperInterface $dto->isPort = $entity->isPort(); $dto->createdAt = $entity->getCreatedAt(); - $dto->zone = $this->microMapper->map($entity->getZone(), ZoneApi::class, [ + $dto->zoneIri = $dto->zone = $this->microMapper->map($entity->getZone(), ZoneApi::class, [ MicroMapperInterface::MAX_DEPTH => 1, ]); diff --git a/httpdocs/src/Mapper/UserTripApiToEntityMapper.php b/httpdocs/src/Mapper/UserTripApiToEntityMapper.php index 1f1956b..3e96da6 100644 --- a/httpdocs/src/Mapper/UserTripApiToEntityMapper.php +++ b/httpdocs/src/Mapper/UserTripApiToEntityMapper.php @@ -4,6 +4,7 @@ namespace App\Mapper; use App\ApiResource\UserTripApi; use App\Entity\UserTrip; +use App\Repository\MediaObjectRepository; use App\Repository\UserTripRepository; use App\Repository\TripRepository; use App\Repository\UserRepository; @@ -18,6 +19,7 @@ class UserTripApiToEntityMapper implements MapperInterface private UserTripRepository $repository, private TripRepository $tripRepository, private UserRepository $userRepository, + private MediaObjectRepository $mediaObjectRepository ) { } @@ -64,16 +66,19 @@ class UserTripApiToEntityMapper implements MapperInterface $entity->setCaptainName($dto->captainName); - if ($dto->completed && !$entity->isCompleted()) { - - if ($entity->getSignature() === null) { - if ($dto->signatureUrl === null) { + if ($dto->completed && $entity->getCompletedDate() === null) { + $entity->setCompletedDate(new \DateTimeImmutable()); + } + $entity->setCompleted($dto->completed); - } + if ($dto->signatureIri) { + $signature = $this->mediaObjectRepository->find($dto->signatureIri->id); + if (!$signature) { + throw new \Exception('Signature not found'); } - - $entity->setCompleted($dto->completed); - $entity->setCompletedDate(new \DateTimeImmutable()); + $entity->setSignature($signature); + } else { + $entity->setSignature(null); } return $entity; diff --git a/httpdocs/src/Mapper/UserTripEntityToApiMapper.php b/httpdocs/src/Mapper/UserTripEntityToApiMapper.php index 0c3787a..514712f 100644 --- a/httpdocs/src/Mapper/UserTripEntityToApiMapper.php +++ b/httpdocs/src/Mapper/UserTripEntityToApiMapper.php @@ -46,17 +46,17 @@ class UserTripEntityToApiMapper implements MapperInterface $dto->completedDate = $entity->getCompletedDate(); $dto->createdAt = $entity->getCreatedAt(); - $dto->trip = $this->microMapper->map($entity->getTrip(), TripApi::class, [ + $dto->tripIri = $dto->trip = $this->microMapper->map($entity->getTrip(), TripApi::class, [ MicroMapperInterface::MAX_DEPTH => 1, ]); - $dto->user = $this->microMapper->map($entity->getUser(), UserApi::class, [ + $dto->userIri = $dto->user = $this->microMapper->map($entity->getUser(), UserApi::class, [ MicroMapperInterface::MAX_DEPTH => 1, ]); - $dto->signature = null; + $dto->signatureIri = $dto->signature = null; if ($entity->getSignature() !== null) { - $dto->signature = $this->microMapper->map($entity->getSignature(), MediaObjectApi::class, [ + $dto->signatureIri = $dto->signature = $this->microMapper->map($entity->getSignature(), MediaObjectApi::class, [ MicroMapperInterface::MAX_DEPTH => 1, ]); } diff --git a/httpdocs/src/State/EntityClassDtoStateProcessor.php b/httpdocs/src/State/EntityClassDtoStateProcessor.php index 4187f26..a93d088 100644 --- a/httpdocs/src/State/EntityClassDtoStateProcessor.php +++ b/httpdocs/src/State/EntityClassDtoStateProcessor.php @@ -46,11 +46,17 @@ class EntityClassDtoStateProcessor implements ProcessorInterface $this->persistProcessor->process($entity, $operation, $uriVariables, $context); $data->id = $entity->getId(); - return $data; + $resourceClass = $operation->getClass(); + return $this->mapEntityToDto($entity, $resourceClass); } private function mapDtoToEntity(object $dto, string $entityClass): object { return $this->microMapper->map($dto, $entityClass); } + + private function mapEntityToDto(object $entity, string $resourceClass): object + { + return $this->microMapper->map($entity, $resourceClass); + } }