Initial cloud-services repo - gateway service + pkg modules
This commit is contained in:
47
pkg/common/map_sequencing.go
Normal file
47
pkg/common/map_sequencing.go
Normal file
@@ -0,0 +1,47 @@
|
||||
package common
|
||||
|
||||
type MapDestinationRequest struct {
|
||||
VIN string `json:"vin" validate:"vin"`
|
||||
Name string `json:"name"`
|
||||
Address *TomTomAddress `json:"address,omitempty"`
|
||||
Coordinates MapCoordinates `json:"coordinates"`
|
||||
}
|
||||
|
||||
type MapDestinationSource struct {
|
||||
DriverID string `json:"driver_id"`
|
||||
Name string `json:"name"`
|
||||
Address *TomTomAddress `json:"address,omitempty"`
|
||||
Coordinates MapCoordinates `json:"coordinates"`
|
||||
}
|
||||
|
||||
type MapRouteRequest struct {
|
||||
VIN string `json:"vin" validate:"vin"`
|
||||
Waypoints []MapWaypoint `json:"waypoints"`
|
||||
Route []MapCoordinates `json:"route"`
|
||||
}
|
||||
|
||||
type MapRouteSource struct {
|
||||
DriverID string `json:"driver_id"`
|
||||
Waypoints []MapWaypoint `json:"waypoints"`
|
||||
Route []MapCoordinates `json:"route"`
|
||||
}
|
||||
|
||||
type MapCoordinates struct {
|
||||
Latitude float64 `json:"latitude"`
|
||||
Longitude float64 `json:"longitude"`
|
||||
}
|
||||
|
||||
type MapWaypoint struct {
|
||||
Type string `json:"type"`
|
||||
Title string `json:"title"`
|
||||
MapCoordinates
|
||||
}
|
||||
|
||||
type TomTomAddress struct {
|
||||
StreetNumber string `json:"street_number"`
|
||||
StreetName string `json:"street_name"`
|
||||
LocalName string `json:"local_name"`
|
||||
PostalCode string `json:"postal_code"`
|
||||
CountrySubdivisionName string `json:"country_subdivision_name"`
|
||||
CountryCodeIso3 string `json:"country_code_iso3"`
|
||||
}
|
||||
Reference in New Issue
Block a user