diff options
Diffstat (limited to 'cmd/web')
-rw-r--r-- | cmd/web/handlers.go | 4 | ||||
-rw-r--r-- | cmd/web/routes.go | 2 |
2 files changed, 2 insertions, 4 deletions
diff --git a/cmd/web/handlers.go b/cmd/web/handlers.go index 40ca509..e27b39b 100644 --- a/cmd/web/handlers.go +++ b/cmd/web/handlers.go @@ -4,7 +4,6 @@ import ( "errors" "fmt" "html/template" - "log" "net/http" "strconv" @@ -34,7 +33,6 @@ func (app *application) listOperations(w http.ResponseWriter, r *http.Request) { data := operationsTemplateData{ Operations: ops, } - log.Println(data) err = ts.ExecuteTemplate(w, "base", data) if err != nil { @@ -42,7 +40,7 @@ func (app *application) listOperations(w http.ResponseWriter, r *http.Request) { } } -func (app *application) listOrganisation(w http.ResponseWriter, r *http.Request) { +func (app *application) listOrganisations(w http.ResponseWriter, r *http.Request) { files := []string{ "./ui/html/base.tmpl.html", "./ui/html/pages/organisations/list.tmpl.html", diff --git a/cmd/web/routes.go b/cmd/web/routes.go index e21b25d..d23855a 100644 --- a/cmd/web/routes.go +++ b/cmd/web/routes.go @@ -9,7 +9,7 @@ func (app *application) routes() *http.ServeMux { mux.Handle("/static/", http.StripPrefix("/static", fileServer)) mux.HandleFunc("/", app.home) - mux.HandleFunc("/organisation/list", app.listOrganisation) + mux.HandleFunc("/organisation/list", app.listOrganisations) mux.HandleFunc("/organisation/view", app.organisationView) mux.HandleFunc("/organisation/create", app.organisationCreate) mux.HandleFunc("/operation/list", app.listOperations) |