annotate gpp/templates/core/admin_dashboard.html @ 145:71cb4208dc98

Tweak to #30, admin dashboard. Because of a bug in Django (9568), my dashboard appears on the login page. To get around this, pass in the user to the templatetag, so it can do a 'if user.is_staff' check. Also tweaked the HTML and CSS to show non-zero pending items in red. Shortened the pending item titles for readability.
author Brian Neal <bgneal@gmail.com>
date Wed, 09 Dec 2009 00:03:10 +0000
parents 861f7d5f1b23
children 023132c90021
rev   line source
bgneal@145 1 {% if user.is_staff %}
bgneal@141 2 <ul id="dashboard-list">
bgneal@145 3 <li><a href="/admin/forums/flaggedpost/">Posts</a>:
bgneal@145 4 <span {% if flagged_posts %}class="alert"{% endif %}>{{ flagged_posts }}</span></li>
bgneal@145 5 <li><a href="/admin/comments/commentflag/">Comments</a>:
bgneal@145 6 <span {% if flagged_comments %}class="alert"{% endif %}>{{ flagged_comments }}</span></li>
bgneal@145 7 <li><a href="/admin/bio/userprofileflag/">Profiles</a>:
bgneal@145 8 <span {% if flagged_profiles %}class="alert"{% endif %}>{{ flagged_profiles }}</span></li>
bgneal@145 9 <li><a href="/admin/gcalendar/event/">Calendar</a>:
bgneal@145 10 <span {% if event_requests %}class="alert"{% endif %}>{{ event_requests }}</span></li>
bgneal@145 11 <li><a href="/admin/news/pendingstory/">News</a>:
bgneal@145 12 <span {% if new_stories %}class="alert"{% endif %}>{{ new_stories }}</span></li>
bgneal@145 13 <li><a href="/admin/downloads/download/">Downloads</a>:
bgneal@145 14 <span {% if new_downloads %}class="alert"{% endif %}>{{ new_downloads }}</span></li>
bgneal@145 15 <li><a href="/admin/weblinks/link/">Links</a>:
bgneal@145 16 <span {% if new_links %}class="alert"{% endif %}>{{ new_links }}</span></li>
bgneal@141 17 </ul>
bgneal@145 18 {% endif %}