Add PIS and ReasonCode types

This commit is contained in:
Fred Boniface 2024-05-02 14:37:18 +01:00
parent 023c82472d
commit ab34be5063
4 changed files with 37 additions and 0 deletions

8
pkg/database/pis.go Normal file
View File

@ -0,0 +1,8 @@
package database
type PIS struct {
Code string `json:"code"`
Stops []string `json:"stops"`
Tiplocs []string `json:"tiplocs"`
Operator string `json:"operator"`
}

View File

@ -0,0 +1,7 @@
package database
type ReasonCode struct {
Code string `json:"code"`
Late string `json:"lateReason"`
Cancel string `json:"cancReason"`
}

7
pkg/upstreamApi/pis.go Normal file
View File

@ -0,0 +1,7 @@
package upstreamApi
type PIS struct {
Code string `json:"code"`
Stops []string `json:"stops"`
Operator string `json:"operator,omitempty"`
}

View File

@ -0,0 +1,15 @@
package upstreamApi
type ReasonCodeObject struct {
GetReasonCodeListResult Reasons `json:"GetReasonCodeListResult"`
}
type Reasons struct {
ReasonList []ReasonCode `json:"reason"`
}
type ReasonCode struct {
Code string `json:"code"`
Late string `json:"lateReason"`
Cancel string `json:"cancReason"`
}