blob: d23855a1238832821c114382a08566b765ae3abb (
plain) (
tree)
|
|
package main
import "net/http"
func (app *application) routes() *http.ServeMux {
mux := http.NewServeMux()
fileServer := http.FileServer(http.Dir("./ui/static/"))
mux.Handle("/static/", http.StripPrefix("/static", fileServer))
mux.HandleFunc("/", app.home)
mux.HandleFunc("/organisation/list", app.listOrganisations)
mux.HandleFunc("/organisation/view", app.organisationView)
mux.HandleFunc("/organisation/create", app.organisationCreate)
mux.HandleFunc("/operation/list", app.listOperations)
return mux
}
|