1
0
Fork 0

Hide original body from email message display in admin; bumping version number.

This commit is contained in:
Adam Coddington 2013-06-11 22:32:13 -07:00
parent c94e2c62a3
commit 156b6fb418
3 changed files with 11 additions and 1 deletions

View file

@ -65,6 +65,12 @@ class MessageAdmin(admin.ModelAdmin):
raw_id_fields = ( raw_id_fields = (
'in_reply_to', 'in_reply_to',
) )
exclude = (
'body',
)
readonly_fields = (
'text',
)
actions = [resend_message_received_signal] actions = [resend_message_received_signal]
if getattr(settings, 'DJANGO_MAILBOX_ADMIN_ENABLED', True): if getattr(settings, 'DJANGO_MAILBOX_ADMIN_ENABLED', True):

View file

@ -365,6 +365,10 @@ class Message(models.Model):
) )
) )
@property
def text(self):
return self.get_text_body()
def get_text_body(self): def get_text_body(self):
def get_body_from_message(message): def get_body_from_message(message):
body = '' body = ''

View file

@ -7,7 +7,7 @@ tests_require=[
setup( setup(
name='django-mailbox', name='django-mailbox',
version='1.10.4', version='1.10.5',
url='http://bitbucket.org/latestrevision/django-mailbox/', url='http://bitbucket.org/latestrevision/django-mailbox/',
description='Import mail from POP3, IMAP, local mailboxes or directly from Postfix or Exim4 into your Django application automatically.', description='Import mail from POP3, IMAP, local mailboxes or directly from Postfix or Exim4 into your Django application automatically.',
author='Adam Coddington', author='Adam Coddington',