diff options
Diffstat (limited to 'pkg/app/list/utils.go')
-rw-r--r-- | pkg/app/list/utils.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/pkg/app/list/utils.go b/pkg/app/list/utils.go index 8a9e964..7899a88 100644 --- a/pkg/app/list/utils.go +++ b/pkg/app/list/utils.go @@ -4,8 +4,10 @@ package list import ( "archives/pkg/models" + "archives/pkg/utils" "html/template" "net/http" + "strconv" ) type ListData struct { @@ -68,6 +70,10 @@ func renderBrowseTemplate(w http.ResponseWriter, lists interface{}) { templates := template.Must( template.Must( template.New("Show"). + Funcs(template.FuncMap{ + "toString" : strconv.Itoa, + "formatCount" : utils.FormatMessageCount, + }). ParseGlob("web/templates/layout/*.tmpl")). ParseGlob("web/templates/list/*.tmpl")) |