diff options
Diffstat (limited to 'src/templates/coins-mintages.html.tmpl')
-rw-r--r-- | src/templates/coins-mintages.html.tmpl | 27 |
1 files changed, 16 insertions, 11 deletions
diff --git a/src/templates/coins-mintages.html.tmpl b/src/templates/coins-mintages.html.tmpl index 8c60248..1cf7c70 100644 --- a/src/templates/coins-mintages.html.tmpl +++ b/src/templates/coins-mintages.html.tmpl @@ -71,15 +71,17 @@ <table class="mintage-table" role="grid"> <thead> <th>{{ .T "Year" }}</th> - {{ with $p := .Printer }} - {{ range denoms }} - <th>{{ $p.M . }}</th> - {{ end }} - {{ end }} + <th>{{ .M 0.01 }}</th> + <th>{{ .M 0.02 }}</th> + <th>{{ .M 0.05 }}</th> + <th>{{ .M 0.10 }}</th> + <th>{{ .M 0.20 }}</th> + <th>{{ .M 0.50 }}</th> + <th>{{ .M 1.00 }}</th> + <th>{{ .M 2.00 }}</th> </thead> <tbody> {{ $p := .Printer }} - {{ $type := .Type }} {{ range .Mintages.Standard }} <tr> <th scope="col"> @@ -88,9 +90,11 @@ <sub><small>{{ .Mintmark }}</small></sub> {{- end -}} </th> - {{ range (index .Mintages (strToCtype $type)) }} + {{ range .Mintages }} {{ if eq . -1 }} <td>{{ $p.T "Unknown" }}</td> + {{ else if eq . -2 }} + <td class="error">{{ $p.T "Error" }}</td> {{ else if eq . 0 }} <td>—</td> {{ else }} @@ -114,7 +118,6 @@ </thead> <tbody> {{ $p := .Printer }} - {{ $type := .Type }} {{ range .Mintages.Commemorative }} <tr> <th scope="col"> @@ -125,9 +128,11 @@ </th> <!-- TODO: Translate commemorative names --> <td>{{ .Name }}</td> - {{ with (index .Mintage (strToCtype $type)) }} + {{ with .Mintage }} {{ if eq . -1 }} <td>{{ $p.T "Unknown" }}</td> + {{ else if eq . -2 }} + <td class="error">{{ $p.T "Error" }}</td> {{ else if eq . 0 }} <td>—</td> {{ else }} @@ -145,9 +150,9 @@ {{ end }} {{ define "coin-type-radio" }} -<label for=compact-{{ index . 1 }}> +<label for={{ index . 1 }}> <input - id=compact-{{ index . 1 }} + id={{ index . 1 }} name="type" type="radio" value={{ index . 1 }} |