forked from mirror/django-mailbox
Merge pull request #288 from xeroticikot/model-admin-fix
fixed the "attachements" string
This commit is contained in:
commit
7701701a88
1 changed files with 1 additions and 1 deletions
|
|
@ -62,7 +62,7 @@ class MessageAttachmentInline(admin.TabularInline):
|
|||
|
||||
class MessageAdmin(admin.ModelAdmin):
|
||||
def get_queryset(self, *args, **kwargs):
|
||||
return super().get_queryset(*args, **kwargs).annotate(num_attachments=Count('attachements'))
|
||||
return super().get_queryset(*args, **kwargs).annotate(num_attachments=Count('attachments'))
|
||||
|
||||
def attachment_count(self, msg):
|
||||
return msg.num_attachments
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue