1
0
mirror of https://github.com/django/django.git synced 2025-10-26 07:06:08 +00:00

Fixed #19536 -- Included object-tools when ModelAdmin.has_add_permission() is False.

This commit is contained in:
Nick Sandford
2015-11-07 11:31:06 +00:00
committed by Tim Graham
parent d9e150b311
commit ff19df9c2d
4 changed files with 27 additions and 5 deletions

View File

@@ -22,6 +22,9 @@ class EventAdmin(admin.ModelAdmin):
def event_date_func(self, event):
return event.date
def has_add_permission(self, request):
return False
site.register(Event, EventAdmin)