From 6d44e8e1c2c9cef390e900ce6056f41ec0712422 Mon Sep 17 00:00:00 2001 From: j Date: Tue, 19 Dec 2017 15:02:34 +0100 Subject: [PATCH] support py2/3 --- content/admin.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/content/admin.py b/content/admin.py index b010f3d..0718973 100644 --- a/content/admin.py +++ b/content/admin.py @@ -4,12 +4,11 @@ from django import forms from django.contrib import admin from markdownx.admin import MarkdownxModelAdmin from markdownx.widgets import AdminMarkdownxWidget -# Register your models here. -from models import * from photologue.admin import GalleryAdmin as GalleryAdminDefault from photologue.models import Gallery +from .models import * class ContentParentsInline(admin.TabularInline): model = ContentContent @@ -53,7 +52,7 @@ class GalleryAdmin(GalleryAdminDefault): class ContentAdmin(admin.ModelAdmin): save_on_top = True - list_display = ('__unicode__', 'datestart', 'shortname', 'type') + list_display = ('__str__', 'datestart', 'shortname', 'type') list_filter = ['datestart', 'type'] search_fields = ['title', 'body', 'header', 'shortname'] inlines = [ContentParentsInline, FileInline, LinkInline]