Changes between Initial Version and Version 1 of Ticket #26369
- Timestamp:
- Mar 17, 2016, 5:40:39 AM (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #26369 – Description
initial v1 1 Currently, the model field defines the default form field that's used2 by the modelform metaclass . It would be nice if we could override this.1 Currently, the model field builds the default form field that's used 2 by the modelform metaclass in Field.formfield(). It uses hardcoded defaults which it would be nice to be able to override with attributes. 3 3 4 For example, if a Radio widget should be used by default for a OneToOne field: 4 Example patch: https://github.com/jpic/django/commit/d102f362f3c1ceaf2d5224d71f788c0821a481ae 5 6 This patch allows to use Radio widget by default for a OneToOne field: 5 7 6 8 {{{ … … 19 21 ) 20 22 }}} 21 22 Example (incomplete) patch: https://github.com/jpic/django/commit/d102f362f3c1ceaf2d5224d71f788c0821a481ae