Add priority group dividers (#183)

This commit is contained in:
Mark Carlson authored and GitHub committed 2024-01-09 14:09:34 -05:00
1 parent 77d34a71f7
commit 2363e7a517
3 files changed
+23 -6

No files matched your search

+6
View File
@@ -161,6 +161,12 @@ body, html, main{
background-color: #171717;
}
#content .table-small-header th {
color: var(--color-font3);
font-size: small;
background-color: #171717;
}
/* Table Spacer for chaining Tables as a hack */
#content .table-spacer th, #content .table-spacer tr {
+10 -2
View File
@@ -251,6 +251,14 @@ def profile_config(request):
# TEST LIST VIEWS #
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
def priority_grouped(active):
active_grouped = []
for t in active:
if len(active_grouped) == 0 or active_grouped[-1]["priority"] != t.priority:
active_grouped.append({"priority": t.priority, "tests": []})
active_grouped[-1]["tests"].append(t)
return active_grouped
def index(request, page=1):
pending = OpenBench.utils.get_pending_tests()
@@ -262,7 +270,7 @@ def index(request, page=1):
data = {
'pending' : pending,
'active' : active,
'active' : priority_grouped(active),
'completed' : completed[start:end],
'awaiting' : awaiting,
'paging' : paging,
@@ -282,7 +290,7 @@ def user(request, username, page=1):
data = {
'pending' : pending,
'active' : active,
'active' : priority_grouped(active),
'completed' : completed[start:end],
'awaiting' : awaiting,
'paging' : paging,