Commit e229d966 authored by Arkadiusz Hiler's avatar Arkadiusz Hiler
Browse files

templates/series: Add tags counts on the series' patches



Like on the project's patches list we can present tag counts (acked-by,
tested-by, etc.) on the series' patches lists too.
Signed-off-by: default avatarArkadiusz Hiler <arkadiusz.hiler@intel.com>
parent b933157d
Pipeline #49610 passed with stages
in 4 minutes and 56 seconds
......@@ -144,17 +144,26 @@ table.pw-list > thead {
background-color: white;
}
table#patchlist > tbody > tr > td.tag-A {
table > thead > tr > th.tag-header {
text-align: center;
}
table > tbody > tr > td.tag-A {
text-align: center;
background-color: #ffe771;
}
table#patchlist > tbody > tr > td.tag-R {
table > tbody > tr > td.tag-F {
text-align: center;
background-color: #71e7ff;
}
table > tbody > tr > td.tag-R {
text-align: center;
background-color: #c3fd98;
}
table#patchlist > tbody > tr > td.tag-T {
table > tbody > tr > td.tag-T {
text-align: center;
background-color: #b4cfec;
}
......
{% extends "base.html" %}
{% load person %}
{% load patch %}
{% block title %}{{project.name}}{% endblock %}
{% block headers %}
......@@ -173,6 +174,11 @@ $(document).ready(function() {
<th>Name</th>
<th>Submitter</th>
<th>State</th>
{% for tag in project.tags %}
<th class="tag-header">
<span title="{{tag.name}}">{{tag.abbrev}}</span>
</th>
{% endfor %}
</tr>
</thead>
<tbody>
......@@ -183,6 +189,9 @@ $(document).ready(function() {
>{{ patch.name|default:"[no subject]"|truncatechars:100 }}</a></td>
<td>{{ patch.submitter|personify:project }}</td>
<td>{{ patch.state }}</td>
{% for tag in project.tags %}
{{ patch|patch_tags:tag }}
{% endfor %}
<tr>
{% endfor %}
</tbody>
......
......@@ -44,7 +44,7 @@ class SeriesView(View):
project = series.project
for revision in revisions:
revision.patch_list = revision.ordered_patches().\
select_related('state', 'submitter')
select_related('state', 'submitter').with_tag_counts(project)
revision.test_results = TestResult.objects \
.filter(revision=revision, patch=None) \
.order_by('test__name').select_related('test')
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment