[Answer]-Correct Django template url variable to use with the Generic View list_detail

1👍

if you use the url style

urlpatterns = patterns('',
    url(r'^index/$', index_view, name="main-view"),
    ...
)

you can give your url a custom name to use to refer to it

👤second

0👍

From the documentation, you can clearly mention the name of the view method and in the file.

{% url 'path.to.some_view' v1 v2 %}

So, for your case, you should be able to do:

{% url 'list_detail.object_list' 'firm_list' %}
👤lprsd

Leave a comment