From 72226b065d7c3a51e7df5debb28023925016d5ee Mon Sep 17 00:00:00 2001 From: Matt Baer Date: Thu, 31 Mar 2016 14:45:48 -0400 Subject: [PATCH] Support `rank` property in reports This presents the items as an ordered list, rather than an unordered list. --- lifereport.go | 1 + report.tmpl | 3 +++ 2 files changed, 4 insertions(+) diff --git a/lifereport.go b/lifereport.go index d6fd6e6..cedbab5 100644 --- a/lifereport.go +++ b/lifereport.go @@ -32,6 +32,7 @@ type ( Title string `json:"title"` Summary []template.HTML `json:"summary"` Details []template.HTML `json:"details"` + Rank []template.HTML `json:"rank"` } ) diff --git a/report.tmpl b/report.tmpl index 03afc41..f73f90c 100644 --- a/report.tmpl +++ b/report.tmpl @@ -15,6 +15,9 @@ {{if .Details}}{{end}} + {{if .Rank}}
    + {{range .Rank}}
  1. {{.}}
  2. {{end}} +
{{end}}
{{end}}