Adding form save hooks to newforms admin
|Reported by:||Stas Shtin <antisvin@…>||Owned by:||nobody|
|Cc:||Triage Stage:||Design decision needed|
|Has patch:||yes||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
Sometimes it's necessary to set DB fields bypassing user input with values based on request object or state of the world. Specific use cases would be saving object creator, last editor, expiration date (i.e. current date + some period of time).
I haven't found any other way for setting DB fields that are not editable with admin application.
Also please notice that ticket #4312 has the same motives as this one, but targeting form_for_model and form_for_instance. Accepting that one would make overloading form save hooks even easier.
Change History (9)
Changed 8 years ago by Stas Shtin <antisvin@…>
comment:1 Changed 8 years ago by SmileyChris
- Needs documentation unset
- Needs tests unset
- Patch needs improvement unset
- Triage Stage changed from Unreviewed to Design decision needed