summaryrefslogtreecommitdiff
path: root/app/jrnl/admin.py
diff options
context:
space:
mode:
authorluxagraf <sng@luxagraf.net>2016-11-02 12:44:30 -0400
committerluxagraf <sng@luxagraf.net>2016-11-02 12:44:30 -0400
commitdf8c450c5ee993bf997e3ae9de52e8b1c91e91d6 (patch)
tree9c7f22bfda9ac2508ef49b02c053f969262f6f29 /app/jrnl/admin.py
parent9a044c66c5f2e201ac4d264909e8f8b62e288818 (diff)
launched new homepage and misc improvements
Diffstat (limited to 'app/jrnl/admin.py')
-rw-r--r--app/jrnl/admin.py26
1 files changed, 3 insertions, 23 deletions
diff --git a/app/jrnl/admin.py b/app/jrnl/admin.py
index b49837a..e71b733 100644
--- a/app/jrnl/admin.py
+++ b/app/jrnl/admin.py
@@ -3,30 +3,14 @@ from django import forms
from django.contrib.gis.admin import OSMGeoAdmin
from utils.widgets import AdminImageWidget, LGEntryForm
-from .models import Entry, EntryAside, HomepageCurrator, EntryTitleSong
+from .models import Entry, HomepageCurrator
from photos.forms import GalleryForm
-class EntryAsideInline(admin.TabularInline):
- model = EntryAside
- extra = 1
-
-
-class EntryAsideAdmin(admin.ModelAdmin):
- pass
-
-
-@admin.register(EntryTitleSong)
-class EntryTitleSongAdmin(admin.ModelAdmin):
- list_display = ('title', 'band', 'album', 'song')
- list_filter = ('band',)
- exclude = ('title', 'body_html', 'slug', 'pub_date')
-
-
+@admin.register(Entry)
class EntryAdmin(OSMGeoAdmin):
form = LGEntryForm
- inlines = [EntryAsideInline]
def formfield_for_dbfield(self, db_field, **kwargs):
if db_field.name == 'thumbnail' or db_field.name == 'image':
@@ -78,12 +62,8 @@ class EntryAdmin(OSMGeoAdmin):
openlayers_url = '/static/admin/js/OpenLayers.js'
+@admin.register(HomepageCurrator)
class HomepageCurratorAdmin(admin.ModelAdmin):
form = GalleryForm
filter_horizontal = ('popular',)
pass
-
-
-admin.site.register(EntryAside, EntryAsideAdmin)
-admin.site.register(Entry, EntryAdmin)
-admin.site.register(HomepageCurrator, HomepageCurratorAdmin)