added no. of issues and features to column header

This commit is contained in:
Özgür Kesim 2024-09-27 12:12:55 +02:00
parent 57285c12c1
commit dec70c98a8
Signed by: oec
GPG Key ID: F136A7F922D018D7
2 changed files with 20 additions and 5 deletions

View File

@ -212,6 +212,16 @@ func (i Issues) ByCategory(cat string) (issues Issues) {
return issues
}
func (i Issues) ByTarget(tar string) (issues Issues) {
for _, is := range i {
if is.TargetVersion.Name == tar {
issues = append(issues, is)
}
}
sort.Sort(sort.Reverse(ByHandlerAndId(issues)))
return
}
func (i Issues) ByCategoryAndTarget(cat, tar string) (issues Issues) {
for _, is := range i {
if is.TargetVersion.Name == tar &&

View File

@ -83,6 +83,7 @@ details[open].issue {
background: ghostwhite;
border: 4px navajowhite solid;
}
</style></head>
<body>
<h1>GNU Taler Dashboard</h1>
@ -101,9 +102,12 @@ details[open].issue {
{{- range $version := $versions }}
<th>
<details class="version">
<summary><b>{{ $version.Name }}</b> <span class="right">({{ $version.Timestamp.Format "02 Jan 06"}})</span></summary>
<summary><b>{{ $version.Name }}</b> <span class="right">({{ $version.Timestamp.Format "02 Jan 06"}})</span>
</summary>
<div>{{ $version.Description }}</div>
</details>
<div class="right">{{ len ($issues.ByTarget $version.Name) }} issues</div>
<div class="right">{{ len ($features.ByTarget $version.Name) }} features</div>
</th>
{{- end}}
</tr>
@ -111,6 +115,7 @@ details[open].issue {
<tr>
<th class="side">{{ . }}</th>
{{- range $version := $versions }}
<td><div class="minh">{{ with $features.ByCategoryAndTarget $cat $version.Name }}
<details class="feature">
<summary>