source: django_apps/running/admin.py@ 298

Last change on this file since 298 was 291, checked in by Rick van der Zwet, 14 years ago

Project import and intial application 'running' import, which combines django with protovis.

File size: 500 bytes
Line 
1from running.models import *
2from django.contrib import admin
3class ResultInline(admin.TabularInline):
4 model = Result
5 fields = [ 'date', 'distance', 'time' ]
6
7class UserAdmin(admin.ModelAdmin):
8 inlines = [ ResultInline, ]
9 class Media:
10 css = { "all" : ("css/hide_admin_original.css",) }
11admin.site.register(User, UserAdmin)
12
13
14class ResultAdmin(admin.ModelAdmin):
15 list_display = [ 'user', 'distance' ,'time' , 'date' ]
16 list_filter = [ 'user' ]
17admin.site.register(Result, ResultAdmin)
18
Note: See TracBrowser for help on using the repository browser.