From: Jonatan Schlag Date: Wed, 10 Jan 2018 18:00:07 +0000 (+0100) Subject: bootstrap4: correctly set colspan value in build table X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fe0e89f956143d45541a30c631db1181df0dcdcc;p=pbs.git bootstrap4: correctly set colspan value in build table Signed-off-by: Jonatan Schlag --- diff --git a/src/templates/modules/build-table.html b/src/templates/modules/build-table.html index 4df9988c..418153ef 100644 --- a/src/templates/modules/build-table.html +++ b/src/templates/modules/build-table.html @@ -4,7 +4,7 @@ {% for date, builds in dates %} - +

{% module HeadingDate(date) %} ({{ len(builds) }}) @@ -23,6 +23,12 @@ {% if show_when %} {{ _("Created") }} {% end %} + {% if show_repo_time %} + {{ _("In repository since") }} + {% end %} + {% if show_can_move_forward %} + {{ _("Can be moved forward") }} + {% end %} {% for build in builds %} diff --git a/src/web/ui_modules.py b/src/web/ui_modules.py index 40498fa3..a95270c0 100644 --- a/src/web/ui_modules.py +++ b/src/web/ui_modules.py @@ -205,6 +205,14 @@ class BuildTableModule(UIModule): ) settings.update(kwargs) + colspan = 2 + + for key in settings.iterkeys(): + if settings.get(key) == True: + colspan = colspan + 1 + + settings.setdefault("colspan", colspan) + dates = {} for b in builds: