diff options
author | Dan McGee <dan@archlinux.org> | 2011-12-08 14:39:30 -0600 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2011-12-08 15:02:11 -0600 |
commit | 3e094a548f409e4a87454764f6baf814464d9619 (patch) | |
tree | 1a40ef41ca8fb3042effc11a5b8e2450c061a065 /packages/admin.py | |
parent | a2317295bb4b8c52a83c9a70263fcc9cc73621f4 (diff) |
Add a new FlagRequest model
This will be used to store all of the submitted data we get via flag out
of date forms on the website.
Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'packages/admin.py')
-rw-r--r-- | packages/admin.py | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/packages/admin.py b/packages/admin.py index 01b6ed6c..14fa8960 100644 --- a/packages/admin.py +++ b/packages/admin.py @@ -1,12 +1,21 @@ from django.contrib import admin -from .models import PackageRelation +from .models import PackageRelation, FlagRequest class PackageRelationAdmin(admin.ModelAdmin): list_display = ('user', 'pkgbase', 'type', 'created') list_filter = ('type', 'user') search_fields = ('user__username', 'pkgbase') + date_hierarchy = 'created' + +class FlagRequestAdmin(admin.ModelAdmin): + list_display = ('pkgbase', 'created', 'who', 'is_spam', 'is_legitimate', + 'message') + list_filter = ('is_spam', 'is_legitimate') + search_fields = ('pkgbase', 'user_email', 'message') + date_hierarchy = 'created' admin.site.register(PackageRelation, PackageRelationAdmin) +admin.site.register(FlagRequest, FlagRequestAdmin) # vim: set ts=4 sw=4 et: |