15 lines
527 B
Go
15 lines
527 B
Go
package web
|
|
|
|
import (
|
|
"github.com/gorilla/mux"
|
|
)
|
|
|
|
func (ws *WebServer) setupJourneysRoutes(appRouter *mux.Router) {
|
|
journeys := appRouter.PathPrefix("/journeys").Subrouter()
|
|
journeys.HandleFunc("/", ws.appHandler.JourneysSearchHTTPHandler())
|
|
journeys.HandleFunc("/search", ws.appHandler.JourneysSearchCompactHTTPHandler())
|
|
journeys.HandleFunc("/save", ws.appHandler.SaveSearchHTTPHandler()).Methods("GET")
|
|
journeys.HandleFunc("/saved-searches/{id}/delete", ws.appHandler.DeleteSavedSearchHTTPHandler()).Methods("GET")
|
|
}
|
|
|