Use static assets for HTML templates
authorJan Dittberner <jandd@cacert.org>
Thu, 29 Mar 2018 19:26:12 +0000 (21:26 +0200)
committerJan Dittberner <jandd@cacert.org>
Thu, 29 Mar 2018 19:26:12 +0000 (21:26 +0200)
commit94dcb5bd75faa4adaef9f56df197a42a5e978718
treed4a11fae0058f92e7629d2c7719bdefc959ce32a
parent4dd5e0982050ae92a9a37cb62e606b2807a85c27
Use static assets for HTML templates

- implement custom http.Filesystem boardvoting.AssetFS
- replace "footer" and "header" with "footer.html" and "header.html"
- change renderTemplate to use Assets
- use boardvoting.GetAssetFS() with http.Fileserver
13 files changed:
boardvoting.go
boardvoting/main.go
boardvoting/templates/create_motion_form.html
boardvoting/templates/denied.html
boardvoting/templates/direct_vote_form.html
boardvoting/templates/edit_motion_form.html
boardvoting/templates/footer.html
boardvoting/templates/header.html
boardvoting/templates/motion.html
boardvoting/templates/motion_fragments.html
boardvoting/templates/motions.html
boardvoting/templates/proxy_vote_form.html
boardvoting/templates/withdraw_motion_form.html