#19617: mixins on ModelForms
-----------------------------+------------------------------------
     Reporter:  EvilDMP      |                    Owner:  loic84
         Type:  New feature  |                   Status:  assigned
    Component:  Forms        |                  Version:  master
     Severity:  Normal       |               Resolution:
     Keywords:               |             Triage Stage:  Accepted
    Has patch:  1            |      Needs documentation:  0
  Needs tests:  0            |  Patch needs improvement:  0
Easy pickings:  0            |                    UI/UX:  0
-----------------------------+------------------------------------

Comment (by Tim Graham <timograham@…>):

 In [changeset:"54cd930baf49c45e3e91338a9f4a56d19090ff25"]:
 {{{
 #!CommitTicketReference repository=""
 revision="54cd930baf49c45e3e91338a9f4a56d19090ff25"
 Clarfied the ModelForm docs with respect to generated vs. declared fields.

 The ModelForm docs suggested that fields defined declaratively override
 default fields generated from the form Meta.

 This is conceptually wrong, especially with inheritance in mind. Meta is
 usually defined on the topmost ModelForm subclass, while fields can come
 from anywhere in the MRO, especially base classes; therefore we suggested
 that something defined in a base class override something from a subclass.

 This patch rephrases the docs around the idea that Meta is used to
 generate
 *missing* fields.

 Refs #8620, #19617.

 Thanks @mjtamlyn and @timgraham for the review.
 }}}

-- 
Ticket URL: <https://code.djangoproject.com/ticket/19617#comment:4>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.370a70868e40fc51873de3b93de4037a%40djangoproject.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to