Factorize automatic alias creation

This commit is contained in:
Alexandre Iooss 2019-07-24 22:03:07 +02:00
parent f865a6ac7c
commit 32a37eae29
No known key found for this signature in database
GPG key ID: 6C79278F3FCDCC02
2 changed files with 46 additions and 55 deletions

View file

@ -28,7 +28,7 @@ class NoteAdmin(PolymorphicParentModelAdmin):
list_filter = (PolymorphicChildModelFilter, 'is_active',)
# Use a polymorphic list
list_display = ('__str__', 'balance', 'is_active')
list_display = ('pretty', 'balance', 'is_active')
polymorphic_list = True
# Organize notes by registration date