Mercurial > public > sg101
comparison gpp/potd/admin.py @ 535:4021ea1045f7
Adding import commands for the 1.0 POTD & comments.
author | Brian Neal <bgneal@gmail.com> |
---|---|
date | Sat, 31 Dec 2011 21:34:17 +0000 |
parents | 3c951521e0ec |
children |
comparison
equal
deleted
inserted
replaced
534:98f5facc0030 | 535:4021ea1045f7 |
---|---|
11 | 11 |
12 IMG_TAG = '<img src="%s" alt="thumbnail" />' | 12 IMG_TAG = '<img src="%s" alt="thumbnail" />' |
13 | 13 |
14 | 14 |
15 class PhotoAdmin(admin.ModelAdmin): | 15 class PhotoAdmin(admin.ModelAdmin): |
16 fields = ('photo', 'caption', 'description', 'user', 'potd_count') | 16 fields = ['photo', 'caption', 'description', 'user', 'potd_count'] |
17 raw_id_fields = ('user', ) | 17 raw_id_fields = ['user'] |
18 list_display = ('__unicode__', 'thumbnail') | 18 list_display = ['__unicode__', 'thumbnail'] |
19 actions = ('regen_thumbnail', ) | 19 actions = ['regen_thumbnail'] |
20 search_fields = ['caption', 'description'] | |
20 | 21 |
21 class Media: | 22 class Media: |
22 js = settings.GPP_THIRD_PARTY_JS['tiny_mce'] | 23 js = settings.GPP_THIRD_PARTY_JS['tiny_mce'] |
23 | 24 |
24 def thumbnail(self, obj): | 25 def thumbnail(self, obj): |