#28587: ListView cleaning ar
-------------------------------------+-------------------------------------
Reporter: Adrian | Owner: nobody
Type: Bug | Status: new
Component: Generic | Version: 1.11
views | Keywords: ListView, CBV,
Severity: Normal | generic,
Triage Stage: | Has patch: 0
Unreviewed |
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-------------------------------------+-------------------------------------
When I have in my urlpatterns args and kwargs the ListView is loosing args
(it's returning empty tuple)
{{{
url(r"^(\w+)/test1/(?P<pk>[0-9]+)/list/$", SamplesListView.as_view(),
name='list_view'),
}}}
Simple code for my view:
{{{
class SamplesListView(ListView):
model = Sample
template_name = 'samples/samples_list.html'
def get(self, request, project_name, *args, **kwargs):
print("project_name", project_name)
return super().get(self, request, project_name, *args, **kwargs)
}}}
It works ok when I pass only args or kwargs into url.
--
Ticket URL: <https://code.djangoproject.com/ticket/28587>
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 post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/048.e7cb32b1743930a4f8fd54515ed8ee8b%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.