organize issue list as table (#77825)

This commit is contained in:
Lauréline Guérin 2023-05-23 10:35:34 +02:00
parent b8e93014f5
commit 7306558867
No known key found for this signature in database
GPG Key ID: 1FAB9B9B4F93D473
3 changed files with 27 additions and 22 deletions

View File

@ -1,13 +1,11 @@
<ul class="issues">
<table class="main pk-compact-table issues">
{% for issue in issues %}
<li><a href="{{ issue.url }}">#{{ issue.id }}</a> : {{ issue.subject }}
{% spaceless %}
<span class="modules">[
{% for module in issue.modules.keys %}
{{ module }}{% if not forloop.last %}, {% endif %}
{% endfor %}
]</span>
{% endspaceless %}
</li>
<tr>
<td class="issue"><a href="{{ issue.url }}">#{{ issue.id }}</a></td>
<td class="subject">{{ issue.subject }}</td>
<td class="modules">
<span class="modules">[&nbsp;{% for module in issue.modules.keys %}{{ module }}{% if not forloop.last %},&nbsp;{% endif %}{% endfor %}&nbsp;]</span>
</td>
</tr>
{% endfor %}
</ul>

View File

@ -21,9 +21,11 @@
</span>
{% if not forloop.last %}, {%endif %}
{% endfor %}
<ul class="issues loading">
<li><i>(récupération des tickets en cours)</i></li>
</ul>
<table class="main pk-compact-table issues loading">
<tbody>
<tr><td>(récupération des tickets en cours)</td></tr>
</tbody>
</table>
{% endif %}
</div>
{% endfor %}
@ -37,7 +39,7 @@
<script>
$(function() {
$('[data-issues-url-content]').each(function(idx, elem) {
var ul_issues = $(elem).find('ul.issues');
var table_issues = $(elem).find('table.issues');
var url = $(elem).data('issues-url-content');
var modules = Object();
$(elem).find('[data-module-name]').each(function(idx2, elem2) {
@ -54,7 +56,7 @@
data: JSON.stringify(modules),
dataType: 'html',
success: function(data) {
$(ul_issues).replaceWith(data);
$(table_issues).replaceWith(data);
}
});
});

View File

@ -95,12 +95,9 @@ td.version.dim {
color: #ccc;
}
#history-summary ul.issues {
line-height: 130%;
}
#history-summary span.modules {
font-size: 80%;
color: #ccc;
color: #666;
}
@-webkit-keyframes cell-loading-pulse {
@ -111,19 +108,19 @@ td.version.dim {
to { width: 100%; }
}
ul.loading li {
table.loading td {
position: relative;
z-index: 10;
display: block;
width: 100%;
}
ul.loading li::after {
table.loading td::after {
content: "";
width: 100%;
position: absolute;
z-index: 0;
left: 0;
top: 0;
width: 0px;
background: rgba(200, 200, 200, 0.5);
height: 100%;
@ -131,6 +128,14 @@ ul.loading li::after {
animation: cell-loading-pulse 10s linear infinite alternate;
}
table.issues td.issue {
width: 50px;
}
table.issues td.modules {
width: 100px;
text-align: right;
}
ul.user-info {
display: none;
}