-
Notifications
You must be signed in to change notification settings - Fork 0
/
routes.go
28 lines (20 loc) · 897 Bytes
/
routes.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
package main
import (
"net/http"
"github.com/hculpan/travtools/cmd/web/embed"
"github.com/hculpan/travtools/cmd/web/handlers"
)
func routes() {
// Serve static files from "assets" directory
http.Handle("/assets/", http.FileServer(http.FS(embed.GetEmbeddedFS())))
http.HandleFunc("/", handlers.HomePage)
http.HandleFunc("/message", handlers.MessagePage)
http.HandleFunc("/planet-generator", handlers.PlanetGeneratorPage)
http.HandleFunc("/trade-generator", handlers.TradeGeneratorPage)
http.HandleFunc("/search-systems", handlers.SearchSystemsHandler)
http.HandleFunc("/passengers", handlers.PassengersHandler)
http.HandleFunc("/cargolots", handlers.CargoLotsHandler)
http.HandleFunc("/generate-trade", handlers.GenerateTradePage)
http.HandleFunc("/spec-trade-purchase", handlers.SpecTradePurchaseHandler)
http.HandleFunc("/spec-trade-sell", handlers.SpecTradeSellHandler)
}