Changeset fbb362a for asadb/template


Ignore:
Timestamp:
Aug 25, 2011, 10:53:03 PM (14 years ago)
Author:
Alex Dehnert <adehnert@…>
Branches:
master, space-access, stable, stage, test-hooks
Children:
9b391ce, 165e5aa
Parents:
d3167b9
git-author:
Alex Dehnert <adehnert@…> (08/25/11 22:53:03)
git-committer:
Alex Dehnert <adehnert@…> (08/25/11 22:53:03)
Message:

Rearrange URLs

This factors out the common "groups" prefix, makes "groups" be used even for
single-group things, and puts group-related stuff in a single namespace.
(Django is lame, and while nested namespaces work, namespaces with wildcards
in the prefix don't, so I can't make a groups:group namespace, which would be
cute.)

Location:
asadb/template
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • asadb/template/base.html

    r386ea2a rfbb362a  
    1212    <ul class='tab-navigation'>
    1313        <li{% ifequal pagename "homepage" %} class='selected'{% endifequal %}><a href="{% url homepage   %}">Home</a></li>
    14         <li{% ifequal pagename "groups"   %} class='selected'{% endifequal %}><a href="{% url group-list %}">Groups</a></li>
     14        <li{% ifequal pagename "groups"   %} class='selected'{% endifequal %}><a href="{% url groups:list %}">Groups</a></li>
    1515        <li{% ifequal pagename "fysm"     %} class='selected'{% endifequal %}><a href="{% url fysm       %}">FYSM</a></li>
    1616        {% if user.is_staff %}<li><a href='{% url admin:index %}'>Admin</a></li>{% endif %}
  • asadb/template/groups/group_change_main.html

    rf27faaf rfbb362a  
    2020
    2121<ul>
    22     <li><a href='{% url group-manage-history group.pk %}'>View update history</a></li>
    23     <li><a href='{% url group-manage-officers group.pk %}'>Update officers, signatories, etc.</a></li>
     22    <li><a href='{% url groups:group-manage-history group.pk %}'>View update history</a></li>
     23    <li><a href='{% url groups:group-manage-officers group.pk %}'>Update officers, signatories, etc.</a></li>
    2424</ul>
    2525
  • asadb/template/groups/group_change_officers.html

    r2abe1dc rfbb362a  
    8787
    8888<ul>
    89     <li><a href='{% url group-manage-main group.pk %}'>View main update page</a></li>
    90     <li><a href='{% url group-manage-officers group.pk %}'>Reload this page</a></li>
     89    <li><a href='{% url groups:group-manage-main group.pk %}'>View main update page</a></li>
     90    <li><a href='{% url groups:group-manage-officers group.pk %}'>Reload this page</a></li>
    9191</ul>
    9292
  • asadb/template/groups/group_detail.html

    r3107c52 rfbb362a  
    55
    66<h1>{{group.name}}{% if group.abbreviation %} ({{group.abbreviation}}){%endif%}
    7 {% if adminpriv %}<a href='{%url group-manage-main group.pk %}'>[update]</a></p>{%endif%}
     7{% if adminpriv %}<a href='{%url groups:group-manage-main group.pk %}'>[update]</a></p>{%endif%}
    88</h1>
    99
  • asadb/template/groups/group_list.html

    r1de230f rfbb362a  
    3232        <th>{{group.name}}</th>
    3333        <td>{% if group.website_url %}<a href='{{group.website_url}}'>Website</a>{%endif%}</td>
    34         <td><a href='{% url group-detail group.pk %}'>DB Entry</a></td>
     34        <td><a href='{% url groups:group-detail group.pk %}'>DB Entry</a></td>
    3535        <td>{{group.description}}</td>
    3636        <td>{{group.meeting_times}}</td>
  • asadb/template/groups/group_version.html

    r9f9aa21 rfbb362a  
    1717<tr>
    1818    <td>{{version.object_id}}</td>
    19     <td><a href='{% url group-detail version.object_id %}'>{{version.object_repr}}</a></td>
     19    <td><a href='{% url groups:group-detail version.object_id %}'>{{version.object_repr}}</a></td>
    2020    <td>{{version.revision.date_created}}</td>
    2121    <td>{% if version.revision.user %}{{version.revision.user}}{%else%}<i>System</i>{%endif%}</td>
  • asadb/template/groups/groups_signatories.html

    r9ea4909 rfbb362a  
    4646{%for group, role_list in officers %}
    4747<tr>
    48     <th><a href='{% url group-detail group.pk %}'>{{group}}</a></th>
     48    <th><a href='{% url groups:group-detail group.pk %}'>{{group}}</a></th>
    4949    {%for holders in role_list%}
    5050    <td>{% if holders %}<ul>{% for person in holders %}<li>{{person}}</li>{%endfor%}</ul>{% endif %}</td>
  • asadb/template/index.html

    r6a646ce rfbb362a  
    77
    88<ul>
    9     <li><a href='{%url group-search%}'>Search groups</a></li>
    10     <li><a href='{%url group-list%}'>List of groups</a></li>
     9    <li><a href='{%url groups:search%}'>Search groups</a></li>
     10    <li><a href='{%url groups:list%}'>List of groups</a></li>
    1111    <li>First Year Summer Mailing<ul>
    1212        <li><a href='{%url fysm%}'>View the entries</a></li>
    1313        <li><a href='{%url fysm-select%}'>Submit an entry</a></li>
    1414    </ul></li>
    15     {%if perms.groups.view_signatories %}<li><a href='{% url groups-signatories %}'>View Signatories</a></li>{%endif%}
     15    {%if perms.groups.view_signatories %}<li><a href='{% url groups:signatories %}'>View Signatories</a></li>{%endif%}
    1616</ul>
    1717
     
    2929<ul>
    3030{% for group in groups %}
    31     <li><a href='{% url group-detail group.pk %}'>{{group}}</a></li>
     31    <li><a href='{% url groups:group-detail group.pk %}'>{{group}}</a></li>
    3232{%endfor%}
    3333</ul>
Note: See TracChangeset for help on using the changeset viewer.