Changes between Initial Version and Version 1 of Ticket #31729
- Timestamp:
- Jun 20, 2020, 12:38:23 PM (5 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #31729
- Property Component Uncategorized → Documentation
- Property Resolution → invalid
- Property Status new → closed
- Property Summary The documentation for ArchiveIndexView is not clear for new developers → The documentation for ArchiveIndexView is not clear for new developers.
-
Ticket #31729 – Description
initial v1 1 {{{ 1 2 path('archive/', 2 3 ArchiveIndexView.as_view(model=Article, date_field="pub_date"), 3 4 name="article_archive"), 4 5 }}} 5 6 where the only mentioned parameters are model and pub_date, and the name for the template. But using this above code does lead to an error saying template not found. Where the main problem is we are supposed to 6 7 {{{ 7 8 path('archive/', 8 9 ArchiveIndexView.as_view(model=Article, date_field="pub_date", template_name="article_archive.html"), 9 10 ), 10 11 }}} 11 12 mention the template_name as paramter for the as_view function. I know it might be silly to just look into the class and find the attribute "template_name" but for new comers trying to implement this might think they made a mistake somewhere else since the path was taking in the name of the template. 12 13 So please do mention in the documentation