|
@@ -4,10 +4,12 @@
|
|
from django.contrib import admin
|
|
from django.contrib import admin
|
|
from models import *
|
|
from models import *
|
|
|
|
|
|
|
|
+PER_PAGE = 50
|
|
|
|
+
|
|
class MovieAdmin(admin.ModelAdmin):
|
|
class MovieAdmin(admin.ModelAdmin):
|
|
list_display = ('title', 'slug', 'created', 'published')
|
|
list_display = ('title', 'slug', 'created', 'published')
|
|
list_filter = ['created', 'published']
|
|
list_filter = ['created', 'published']
|
|
- list_per_page = 10
|
|
|
|
|
|
+ list_per_page = PER_PAGE
|
|
|
|
|
|
admin.site.register(Movie, MovieAdmin)
|
|
admin.site.register(Movie, MovieAdmin)
|
|
|
|
|
|
@@ -20,12 +22,12 @@ class GalleryAdmin(admin.ModelAdmin):
|
|
class PhotographerAdmin(admin.ModelAdmin):
|
|
class PhotographerAdmin(admin.ModelAdmin):
|
|
list_display = ('name',)
|
|
list_display = ('name',)
|
|
list_filter = ['created']
|
|
list_filter = ['created']
|
|
- list_per_page = 10
|
|
|
|
|
|
+ list_per_page = PER_PAGE
|
|
|
|
|
|
class PhotoAdmin(admin.ModelAdmin):
|
|
class PhotoAdmin(admin.ModelAdmin):
|
|
list_display = ('title', 'slug', 'created', 'published', 'view_count', 'admin_thumbnail')
|
|
list_display = ('title', 'slug', 'created', 'published', 'view_count', 'admin_thumbnail')
|
|
list_filter = ['created', 'published']
|
|
list_filter = ['created', 'published']
|
|
- list_per_page = 10
|
|
|
|
|
|
+ list_per_page = PER_PAGE
|
|
search_fields=('title','description','photographer__name',)
|
|
search_fields=('title','description','photographer__name',)
|
|
filter_horizontal = ('towns','sites',)
|
|
filter_horizontal = ('towns','sites',)
|
|
fieldsets = (
|
|
fieldsets = (
|
|
@@ -76,7 +78,7 @@ class WatermarkAdmin(admin.ModelAdmin):
|
|
class GraphicAdmin(admin.ModelAdmin):
|
|
class GraphicAdmin(admin.ModelAdmin):
|
|
list_display = ('title', 'slug', 'created', 'published', 'view_count', 'admin_thumbnail')
|
|
list_display = ('title', 'slug', 'created', 'published', 'view_count', 'admin_thumbnail')
|
|
list_filter = ['created', 'published']
|
|
list_filter = ['created', 'published']
|
|
- list_per_page = 10
|
|
|
|
|
|
+ list_per_page = PER_PAGE
|
|
|
|
|
|
admin.site.register(Graphic, GraphicAdmin)
|
|
admin.site.register(Graphic, GraphicAdmin)
|
|
|
|
|