mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Fixed #22135 -- Added ModelAdmin.get_changeform_initial_data().
Allows custom behavior for setting initial form data in ModelAdmin. By default, initial data is set via GET params. The new method allows this behavior to be overridden. Thanks egasimus for the suggestion.
This commit is contained in:
@@ -308,6 +308,10 @@ Minor features
|
||||
<django.contrib.admin.ModelAdmin.list_display>` value by prefixing the
|
||||
``admin_order_field`` value with a hyphen.
|
||||
|
||||
* The :meth:`ModelAdmin.get_changeform_initial_data()
|
||||
<django.contrib.admin.ModelAdmin.get_changeform_initial_data>` method may be
|
||||
overridden to define custom behavior for setting initial change form data.
|
||||
|
||||
:mod:`django.contrib.auth`
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
|
||||
Reference in New Issue
Block a user