#6396: [newforms-admin] Customization-unfriendly admin template tags should die
---------------------------------------------+------------------------------
Reporter: korpios | Owner: nobody
Status: new | Milestone:
Component: django.contrib.admin | Version: SVN
Resolution: | Keywords: nfa-someday
Stage: Design decision needed | Has_patch: 1
Needs_docs: 0 | Needs_tests: 0
Needs_better_patch: 0 |
---------------------------------------------+------------------------------
Comment (by mwdiers):
I would argue that the template tag is not the problem. The real problem
is that the row results themselves are not being rendered in a template at
all - meaning that there is no way to tweak the result list row items.
Moving the code out of the template tag, as the first patch does, does not
solve the problem. It only moves it to a new location.
It is easy to see why a custom tag was chosen here: Because the
change_list template becomes especially cumbersome without it. Using the
tag has encapsulated a chunk of code.
By doing nothing other than moving the row rendering into the admin_list
template tag itself, the problem is solved. It is trivial to create your
own version of the admin_list template tag, and use it in your own
overridden change_list template.
This is still the ''one and only'' patch I apply to my Django
installations. It is also backward-compatible. I hope it gets some
attention soon.
--
Ticket URL: <http://code.djangoproject.com/ticket/6396#comment:18>
Django <http://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 post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---