#36067: Ambiguity of the 'DELETE' text when a TabularInline object does not 
exist
--------------------------------------+------------------------------------
     Reporter:  Antoliny              |                    Owner:  Antoliny
         Type:  Cleanup/optimization  |                   Status:  assigned
    Component:  contrib.admin         |                  Version:  dev
     Severity:  Normal                |               Resolution:
     Keywords:  TabularInline         |             Triage Stage:  Accepted
    Has patch:  0                     |      Needs documentation:  0
  Needs tests:  0                     |  Patch needs improvement:  0
Easy pickings:  0                     |                    UI/UX:  0
--------------------------------------+------------------------------------
Comment (by Antoliny):

 Replying to [comment:4 Natalia Bidart]:
 > I share your concern with your initial diff. There is one extra query
 being issued which feels unnecessary. I played a bit with this and settled
 on having something like this, which nicely reduces logic in the template
 for calculating the header and checkbox row, and it also uses the existing
 information in the formset: ...

 That's correct. My suggestion added unnecessary queries. I think it's
 great that this can be resolved through repetition.
 (`any(inlineadminform.original is not None for inlineadminform in self)`)
 Also, the part about simplifying the logic in the template is very
 beneficial. Thank you so much for your excellent suggestion.
-- 
Ticket URL: <https://code.djangoproject.com/ticket/36067#comment:5>
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 [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/django-updates/0107019443127cd4-d76a388b-c878-41e1-8081-e2580de64006-000000%40eu-central-1.amazonses.com.

Reply via email to