Changeset f6982d4
- Timestamp:
- Jan 29, 2013, 8:15:17 PM (13 years ago)
- Branches:
- master, space-access, stable, stage
- Children:
- 1484698
- Parents:
- e2ceffa
- git-author:
- Alex Dehnert <adehnert@…> (01/29/13 20:14:13)
- git-committer:
- Alex Dehnert <adehnert@…> (01/29/13 20:15:17)
- Location:
- asadb
- Files:
-
- 1 added
- 4 edited
-
space/views.py (modified) (2 diffs)
-
template/index.html (modified) (1 diff)
-
template/space/lock_types.html (added)
-
template/space/summary.html (modified) (2 diffs)
-
urls.py (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
asadb/space/views.py
r67dd640 rf6982d4 112 112 'locker_num', 113 113 'group__name', 114 ).select_related('space', ' group')114 ).select_related('space', 'space__lock_type', 'group') 115 115 office_assignments = assignments.filter(locker_num='') 116 116 … … 130 130 } 131 131 return render_to_response('space/summary.html', context, context_instance=RequestContext(request), ) 132 133 def lock_types(request, ): 134 lock_types = space.models.LockType.objects.order_by('name') 135 context = { 136 'lock_types': lock_types, 137 'pagename': 'groups', 138 } 139 return render_to_response('space/lock_types.html', context, context_instance=RequestContext(request), ) -
asadb/template/index.html
rde2f0ac rf6982d4 57 57 </ul></li> 58 58 <li><a href='{% url space-summary %}'>Space assignments</a> 59 <ul> 60 <li><a href='{% url space-lock-type %}'>Lock Types</a></li> 59 61 {% if perms.groups.view_group_private_info %} 60 <ul>61 62 <li><a href='{% url space-dump-locker-access %}'>Locker access (CSV)</a></li> 62 63 <li><a href='{% url space-dump-office-access %}'>Office access (CSV)</a></li> 64 {% endif %} 63 65 </ul> 64 {% endif %}65 66 </li> 66 67 <li><a href='{% url about %}'>About the ASA Database</a><ul> -
asadb/template/space/summary.html
rde2f0ac rf6982d4 27 27 <th>Room</th> 28 28 <th>Group</th> 29 <th><a href='{% url space-lock-type %}'>Lock Type</a></th> 29 30 <th>Access</th> 30 31 </tr> … … 33 34 <td>{{office.space.number}}</td> 34 35 <td><a href='{% url groups:group-detail office.group.pk %}'>{{office.group}}</a></td> 36 <td>{{office.space.lock_type.name}}</td> 35 37 <td><a href='{% url groups:group-space-access office.group.pk %}'>Access</a></td> 36 38 </tr> -
asadb/urls.py
rde2f0ac rf6982d4 81 81 url(r'^space/dump/office-access.csv$', space.views.dump_office_access, name='space-dump-office-access', ), 82 82 url(r'^space/$', space.views.summary, name='space-summary', ), 83 url(r'^space/lock_types.html$', space.views.lock_types, name='space-lock-type', ), 83 84 84 85 # Uncomment the admin/doc line below and add 'django.contrib.admindocs'
Note: See TracChangeset
for help on using the changeset viewer.