#28048: Allow generic date views to use related fields as date_field
-------------------------------------+-------------------------------------
     Reporter:  Lefteris Nikoltsios  |                    Owner:  Lefteris
                                     |  Nikoltsios
         Type:  New feature          |                   Status:  assigned
    Component:  Generic views        |                  Version:  1.11
     Severity:  Normal               |               Resolution:
     Keywords:                       |             Triage Stage:  Accepted
    Has patch:  1                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  1
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by Jaap Roes):

 * cc: Jaap Roes (added)


Comment:

 I created issue #32846 which was marked as a duplicate. Looking at the
 patch provided for this ticket is seems that the most difficult part is
 the lack of an "official" way of resolving "field paths" like
 `blog__pub_date` to fields. Django admin provides some utility methods,
 but since it is a contrib app it cannot be used in other "core" Django
 code.

 Is there a separate ticket that tracks this? (I couldn't find one.) The
 addition of a canonical way to resolve field paths could also be helpful
 for 3rd party apps, for example django-filter has it's own implementation:
 https://github.com/carltongibson/django-
 
filter/blob/f507201addfb7f105e722573f3ced4b4a9870526/django_filters/utils.py#L143,
 and I'm certain there are others.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/28048#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 on the web visit 
https://groups.google.com/d/msgid/django-updates/069.89a0df685eda5176ee378581c0e40ce8%40djangoproject.com.

Reply via email to