admin.ModelAdmin.get_readonly_fields()

ModelAdmin.get_readonly_fields(request, obj=None)

The get_readonly_fields method is given the HttpRequest and the obj being edited (or None on an add form) and is expected to return a list or tuple of field names that will be displayed as read-only, as described above in the ModelAdmin.readonly_fields section.

doc_Django
2016-10-09 18:33:47
Comments
Leave a Comment

Please login to continue.