diff options
Diffstat (limited to 'web/templates/maintainer/components/bugs.tmpl')
-rw-r--r-- | web/templates/maintainer/components/bugs.tmpl | 106 |
1 files changed, 48 insertions, 58 deletions
diff --git a/web/templates/maintainer/components/bugs.tmpl b/web/templates/maintainer/components/bugs.tmpl index b81c2a4..f069dad 100644 --- a/web/templates/maintainer/components/bugs.tmpl +++ b/web/templates/maintainer/components/bugs.tmpl @@ -3,28 +3,24 @@ <div class="col-md-9"> {{$security_bugs := 0}} {{$non_security_bugs := 0}} - {{range .Packages}} - {{range .AllBugs}} - {{if eq .Component "Vulnerabilities"}} - {{$security_bugs = (add $security_bugs 1)}} - {{else}} - {{$non_security_bugs = (add $non_security_bugs 1)}} - {{end}} + {{range getAllBugs .Packages}} + {{if eq .Component "Vulnerabilities"}} + {{$security_bugs = (add $security_bugs 1)}} + {{else}} + {{$non_security_bugs = (add $non_security_bugs 1)}} {{end}} {{end}} {{$general_bugs := 0}} {{$stabilization_bugs := 0}} {{$keywording_bugs := 0}} - {{range .Packages}} - {{range .AllBugs}} - {{if eq .Component "Current packages"}} - {{$general_bugs = (add $general_bugs 1)}} - {{else if eq .Component "Stabilization"}} - {{$stabilization_bugs = (add $stabilization_bugs 1)}} - {{else if eq .Component "Keywording"}} - {{$keywording_bugs = (add $keywording_bugs 1)}} - {{end}} + {{range getAllBugs .Packages}} + {{if eq .Component "Current packages"}} + {{$general_bugs = (add $general_bugs 1)}} + {{else if eq .Component "Stabilization"}} + {{$stabilization_bugs = (add $stabilization_bugs 1)}} + {{else if eq .Component "Keywording"}} + {{$keywording_bugs = (add $keywording_bugs 1)}} {{end}} {{end}} @@ -34,21 +30,19 @@ {{if $general_bugs}} <h3 id="packages" class="mb-4">Bug Reports</h3> <ul class="list-group"> - {{range .Packages}} - {{range .AllBugs}} - {{if eq .Component "Current packages"}} - <li class="list-group-item"> - <div class="row"> - <div class="col-md-12"> - <i class="fa fa-bug" aria-hidden="true"></i> - <a href="https://bugs.gentoo.org/{{.Id}}" class="text-dark"><b>{{.Summary}}</b></a> - </div> - <div class="col-md-12 text-muted"> - {{.Id}} - Assigned to {{.Assignee}} - </div> + {{range getAllBugs .Packages}} + {{if eq .Component "Current packages"}} + <li class="list-group-item"> + <div class="row"> + <div class="col-md-12"> + <i class="fa fa-bug" aria-hidden="true"></i> + <a href="https://bugs.gentoo.org/{{.Id}}" class="text-dark"><b>{{.Summary}}</b></a> </div> - </li> - {{end}} + <div class="col-md-12 text-muted"> + {{.Id}} - Assigned to {{.Assignee}} + </div> + </div> + </li> {{end}} {{end}} </ul> @@ -57,21 +51,19 @@ {{if $stabilization_bugs}} <h3 id="stabilization" class="my-4">Stabilization Bug Reports</h3> <ul class="list-group"> - {{range .Packages}} - {{range .AllBugs}} - {{if eq .Component "Stabilization"}} - <li class="list-group-item"> - <div class="row"> - <div class="col-md-12"> - <i class="fa fa-bug" aria-hidden="true"></i> - <a href="https://bugs.gentoo.org/{{.Id}}" class="text-dark"><b>{{.Summary}}</b></a> - </div> - <div class="col-md-12 text-muted"> - {{.Id}} - Assigned to {{.Assignee}} - </div> + {{range getAllBugs .Packages}} + {{if eq .Component "Stabilization"}} + <li class="list-group-item"> + <div class="row"> + <div class="col-md-12"> + <i class="fa fa-bug" aria-hidden="true"></i> + <a href="https://bugs.gentoo.org/{{.Id}}" class="text-dark"><b>{{.Summary}}</b></a> + </div> + <div class="col-md-12 text-muted"> + {{.Id}} - Assigned to {{.Assignee}} </div> - </li> - {{end}} + </div> + </li> {{end}} {{end}} </ul> @@ -80,21 +72,19 @@ {{if $keywording_bugs}} <h3 id="keywording" class="my-4">Keywording Bug Reports</h3> <ul class="list-group"> - {{range .Packages}} - {{range .AllBugs}} - {{if eq .Component "Keywording"}} - <li class="list-group-item"> - <div class="row"> - <div class="col-md-12"> - <i class="fa fa-bug" aria-hidden="true"></i> - <a href="https://bugs.gentoo.org/{{.Id}}" class="text-dark"><b>{{.Summary}}</b></a> - </div> - <div class="col-md-12 text-muted"> - {{.Id}} - Assigned to {{.Assignee}} - </div> + {{range getAllBugs .Packages}} + {{if eq .Component "Keywording"}} + <li class="list-group-item"> + <div class="row"> + <div class="col-md-12"> + <i class="fa fa-bug" aria-hidden="true"></i> + <a href="https://bugs.gentoo.org/{{.Id}}" class="text-dark"><b>{{.Summary}}</b></a> + </div> + <div class="col-md-12 text-muted"> + {{.Id}} - Assigned to {{.Assignee}} </div> - </li> - {{end}} + </div> + </li> {{end}} {{end}} </ul> |