incubator-allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From brond...@apache.org
Subject [6/9] git commit: [#5913] Fixed "and 1 others" corner-case on project header admin list
Date Wed, 29 May 2013 18:42:24 GMT
[#5913] Fixed "and 1 others" corner-case on project header admin list

Signed-off-by: Cory Johns <cjohns@slashdotmedia.com>


Project: http://git-wip-us.apache.org/repos/asf/incubator-allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-allura/commit/4307a3da
Tree: http://git-wip-us.apache.org/repos/asf/incubator-allura/tree/4307a3da
Diff: http://git-wip-us.apache.org/repos/asf/incubator-allura/diff/4307a3da

Branch: refs/heads/master
Commit: 4307a3da0ad469f1893e3382e9db0e1b3a11122d
Parents: f2af255
Author: Cory Johns <cjohns@slashdotmedia.com>
Authored: Thu May 23 20:11:22 2013 +0000
Committer: Dave Brondsema <dbrondsema@slashdotmedia.com>
Committed: Wed May 29 18:40:18 2013 +0000

----------------------------------------------------------------------
 Allura/allura/templates/jinja_master/nav_menu.html |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/4307a3da/Allura/allura/templates/jinja_master/nav_menu.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/jinja_master/nav_menu.html b/Allura/allura/templates/jinja_master/nav_menu.html
index 724ca1c..a34e20a 100644
--- a/Allura/allura/templates/jinja_master/nav_menu.html
+++ b/Allura/allura/templates/jinja_master/nav_menu.html
@@ -56,11 +56,12 @@
     <div class="brought-by{% if c.project.icon %} with-icon{% endif %}">
         Brought to you by:
         {% set admins = c.project.admins()|sort(attribute='username') %}
-        {% for admin in admins[:4] %}
-            <a href="{{ admin.url() }}">{{ admin.username }}</a>{{ ',' if not
loop.last }}
+        {% for admin in admins[:5] %}
+            {% if loop.last and admins|length > 5 -%}
+                and <a href="{{ c.project.url() }}_members/">{{ admins|length - 4 }}
others</a>
+            {% else %}
+                <a href="{{ admin.url() }}">{{ admin.username }}</a>{{ ',' if
not loop.last }}
+            {% endif %}
         {%- endfor -%}
-        {% if admins|length > 4 -%}
-            , and <a href="{{ c.project.url() }}_members/">{{ admins|length - 4 }}
others</a>
-        {% endif %}
     </div>
 {% endif %}


Mime
View raw message