2009-08-10 12:47:02 -07:00
{% extends "admin/base_site.html" %}
2012-03-23 16:23:17 -07:00
{% load i18n admin_static %}
2009-08-10 12:47:02 -07:00
2012-03-23 16:23:17 -07:00
{% block extrastyle %}{{ block.super }}< link rel = "stylesheet" type = "text/css" href = "{% static " admin / css / dashboard . css " % } " / > {% endblock %}
2009-08-10 12:47:02 -07:00
{% block coltype %}colMS{% endblock %}
2014-06-28 10:41:18 -07:00
{% block bodyclass %}{{ block.super }} dashboard{% endblock %}
2009-08-10 12:47:02 -07:00
{% block breadcrumbs %}{% endblock %}
{% block content %}
< div id = "content-main" >
< div class = "module" >
< table >
< caption > Custom Admin Pages< / caption >
2011-01-04 06:45:15 -08:00
{% if perms.auth.add_user %}
2009-08-10 12:47:02 -07:00
< tr >
< th scope = "row" > < a href = "/devel/newuser/" > Create New User< / a > < / th >
< td > < / td > < td > < / td >
< / tr >
2011-01-04 06:45:15 -08:00
{% endif %}
{% if user.is_superuser %}
< tr >
< th scope = "row" > < a href = "/devel/admin_log/" > Admin Actions Log< / a > < / th >
< td > < / td > < td > < / td >
< / tr >
{% endif %}
2009-08-10 12:47:02 -07:00
< / table >
< / div >
{% if app_list %}
{% for app in app_list %}
2013-12-15 10:23:50 -08:00
< div class = "app-{{ app.app_label }} module" >
< table >
< caption >
2014-06-28 10:41:18 -07:00
< a href = "{{ app.app_url }}" class = "section" title = "{% blocktrans with name=app.name %}Models in the {{ name }} application{% endblocktrans %}" > {{ app.name }}< / a >
2013-12-15 10:23:50 -08:00
< / caption >
2009-08-10 12:47:02 -07:00
{% for model in app.models %}
2013-12-15 10:23:50 -08:00
< tr class = "model-{{ model.object_name|lower }}" >
2012-03-23 16:23:17 -07:00
{% if model.admin_url %}
2009-08-10 12:47:02 -07:00
< th scope = "row" > < a href = "{{ model.admin_url }}" > {{ model.name }}< / a > < / th >
{% else %}
< th scope = "row" > {{ model.name }}< / th >
{% endif %}
2012-03-23 16:23:17 -07:00
{% if model.add_url %}
2011-12-07 12:15:15 -08:00
< td > < a href = "{{ model.add_url }}" class = "addlink" > {% trans 'Add' %}< / a > < / td >
2009-08-10 12:47:02 -07:00
{% else %}
< td > < / td >
{% endif %}
2012-03-23 16:23:17 -07:00
{% if model.admin_url %}
2009-08-10 12:47:02 -07:00
< td > < a href = "{{ model.admin_url }}" class = "changelink" > {% trans 'Change' %}< / a > < / td >
{% else %}
< td > < / td >
{% endif %}
< / tr >
{% endfor %}
< / table >
< / div >
{% endfor %}
{% else %}
< p > {% trans "You don't have permission to edit anything." %}< / p >
{% endif %}
< / div >
{% endblock %}
{% block sidebar %}
< div id = "content-related" >
< div class = "module" id = "recent-actions-module" >
< h2 > {% trans 'Recent Actions' %}< / h2 >
< h3 > {% trans 'My Actions' %}< / h3 >
{% load log %}
{% get_admin_log 10 as admin_log for_user user %}
{% if not admin_log %}
< p > {% trans 'None available' %}< / p >
{% else %}
< ul class = "actionlist" >
{% for entry in admin_log %}
< li class = "{% if entry.is_addition %}addlink{% endif %}{% if entry.is_change %}changelink{% endif %}{% if entry.is_deletion %}deletelink{% endif %}" >
2011-12-07 12:15:15 -08:00
{% if entry.is_deletion or not entry.get_admin_url %}
2009-08-10 12:47:02 -07:00
{{ entry.object_repr }}
{% else %}
< a href = "{{ entry.get_admin_url }}" > {{ entry.object_repr }}< / a >
{% endif %}
< br / >
{% if entry.content_type %}
< span class = "mini quiet" > {% filter capfirst %}{% trans entry.content_type.name %}{% endfilter %}< / span >
{% else %}
< span class = "mini quiet" > {% trans 'Unknown content' %}< / span >
{% endif %}
< / li >
{% endfor %}
< / ul >
{% endif %}
< / div >
< / div >
{% endblock %}