move templates to separate file

This commit is contained in:
Henrique Dias
2017-06-25 22:43:43 +01:00
parent cca2d9c4c6
commit b466ad616c
3 changed files with 90 additions and 85 deletions

View File

@@ -103,6 +103,8 @@ func (p page) PreviousLink() string {
// PrintAsHTML formats the page in HTML and executes the template
func (p page) PrintAsHTML(w http.ResponseWriter, m *FileManager, templates ...string) (int, error) {
templates = append(templates, "templates")
if p.minimal {
templates = append(templates, "minimal")
} else {