blob: 299f0b7f2b672a2e3d026401e3f4987d3e9c4bc6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
// Used to show the landing page of the application
package admin
import (
"html/template"
"net/http"
)
// Show renders a template to show the landing page of the application
func Show(w http.ResponseWriter, r *http.Request) {
templates := template.Must(
template.Must(
template.New("Show").
Funcs(getFuncMap()).
ParseGlob("web/templates/layout/*.tmpl")).
ParseGlob("web/templates/admin/*.tmpl"))
templates.ExecuteTemplate(w, "show.tmpl", getPageData(w, r))
}
|