diff options
author | supriya <supriya@dragbox.(none)> | 2012-07-03 15:33:13 +0530 |
---|---|---|
committer | supriya <supriya@dragbox.(none)> | 2012-07-03 15:33:13 +0530 |
commit | 6ed2dedb9b8e06683a4d9ea4765043559abab048 (patch) | |
tree | 810bb577997fca99128ea28b719b0a7877023a7d /gstudio/admin | |
parent | 83e72aedffa53245d6083a7654302460e6774876 (diff) | |
download | gnowsys-6ed2dedb9b8e06683a4d9ea4765043559abab048.tar.gz |
orgitdown added to admin interface
Diffstat (limited to 'gstudio/admin')
-rw-r--r-- | gstudio/admin/attributetype.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/gstudio/admin/attributetype.py b/gstudio/admin/attributetype.py index c44db82b..7ad36ba5 100644 --- a/gstudio/admin/attributetype.py +++ b/gstudio/admin/attributetype.py @@ -21,6 +21,7 @@ from gstudio.managers import PUBLISHED from gstudio.ping import DirectoryPinger from gstudio.admin.forms import AttributetypeAdminForm from gstudio.settings import GSTUDIO_VERSIONING +from markitup.widgets import AdminMarkItUpWidget if GSTUDIO_VERSIONING == True: @@ -77,6 +78,11 @@ types','dataType','verbose_name','null','blank','help_text','max_digits','decima self.form.admin_site = admin_site super(AttributetypeAdmin, self).__init__(model, admin_site) + def formfield_for_dbfield(self, db_field, **kwargs): + if db_field.name == 'content': + kwargs['widget'] = AdminMarkItUpWidget() + return super(AttributetypeAdmin, self).formfield_for_dbfield(db_field, **kwargs) + # Custom Display def get_title(self, attributetype): """Return the title with word count and number of comments""" |