#28357: Prepopulated_fields doesn't work for admin.StackedInline
-------------------------------------+-------------------------------------
     Reporter:  ChristosKon          |                    Owner:  nobody
         Type:  Bug                  |                   Status:  new
    Component:  contrib.admin        |                  Version:  2.1
     Severity:  Normal               |               Resolution:
     Keywords:  admin,               |             Triage Stage:
  stackedinline,                     |  Unreviewed
  prepopulated_fields                |
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by Ryan Siemens):

 * cc: Ryan Siemens (added)
 * status:  closed => new
 * version:  1.11 => 2.1
 * resolution:  worksforme =>


Comment:

 Reopening as I ran into this issue (at least similar) today. Some
 additional info:

 The `prepopulated_fields` will work for the `extra` forms specified, in
 the inline, but any additional forms added via "Add another <Model>" will
 not run the js that pre populates the field.

 Verified this issue is happening in 2.1 and 1.11 and attached a minimal
 project that reproduces the issue.

 To reproduce:
 1. extract the attached project
 2. run the migrations
 3. create a superuser
 4. navigate to `admin/myapp/blog/add/`
 5. adding a title to extra forms in the the stacked inline articles
 prepopulates the slug field
 6. click "Add another Article"
 7. ASSERT adding a title the newly added stacked inline article form does
 **not** prepopulate the slug field

 Here is a screen grab showing the results of steps 5-7
 https://zappy.zapier.com/22F716E5-1D64-4763-B731-DE62D24F8FC0.mp4

-- 
Ticket URL: <https://code.djangoproject.com/ticket/28357#comment:2>
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/069.ac369cecc709559676a05c63853a6684%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to