From b6903cb912bf0332e12736a1e272cc7901206f87 Mon Sep 17 00:00:00 2001 From: Sanj Date: Fri, 2 Dec 2011 02:41:11 +0530 Subject: [PATCH] markitup for festival + new emailer --- itf/festival/admin.py | 5 +++++ itf/settings.py | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/itf/festival/admin.py b/itf/festival/admin.py index fe8dd7c..d2abdda 100755 --- a/itf/festival/admin.py +++ b/itf/festival/admin.py @@ -1,5 +1,6 @@ from django.contrib import admin from models import * +from markitup.widgets import MarkItUpWidget class AudioInline(admin.StackedInline): model = Audio @@ -26,6 +27,7 @@ class TalkAdmin(admin.ModelAdmin): list_display = ('__unicode__', 'presenter', 'session',) list_filter = ['session'] search_fields = ('title', 'intro', 'presenter',) + formfield_overrides = {models.TextField: {'widget': MarkItUpWidget}} #hide meeting field class MeetingDayInline(admin.StackedInline): @@ -37,11 +39,13 @@ class ParticipantInline(admin.StackedInline): extra = 3 class MeetingAdmin(admin.ModelAdmin): + formfield_overrides = {models.TextField: {'widget': MarkItUpWidget}} inlines = [MeetingDayInline, ImageInline, DocumentInline, ParticipantInline] prepopulated_fields = {"slug": ("title",)} save_on_top = True class ProjectAdmin(admin.ModelAdmin): + formfield_overrides = {models.TextField: {'widget': MarkItUpWidget}} prepopulated_fields = {"slug": ("title",)} save_on_top = True @@ -49,6 +53,7 @@ class SessionAdmin(admin.ModelAdmin): search_fields = ('title', 'intro',) list_filter = ['day'] list_display = ('__unicode__',) + formfield_overrides = {models.TextField: {'widget': MarkItUpWidget}} class ParticipantAdmin(admin.ModelAdmin): search_fields = ('title', 'short_bio',) diff --git a/itf/settings.py b/itf/settings.py index d005f3e..7a820a2 100755 --- a/itf/settings.py +++ b/itf/settings.py @@ -155,10 +155,11 @@ INSTALLED_APPS = ( # 'itfcore', 'festival', 'insidepages', - 'erang', +# 'erang', 'erang_organised', 'scriptbank', 'bestpractices', + 'emailer', 'tagging', 'app', 'api', @@ -179,6 +180,7 @@ INSTALLED_APPS = ( ) ACCOUNT_ACTIVATION_DAYS = 30 + #overwrite default settings with local settings try: from local_settings import *