diff --git a/elections2021/models.py b/elections2021/models.py index 378fce477f96be2d8a4ab2dfe87628bb0b6a3a54..03b0d3fda7c7eca69b2c638c3805a2e815909a09 100644 --- a/elections2021/models.py +++ b/elections2021/models.py @@ -140,6 +140,8 @@ class MenuItemBlock(blocks.StructBlock): "elections2021.Elections2021TextPage", "elections2021.Elections2021StrategicListPage", "elections2021.Elections2021StrategicPage", + "elections2021.Elections2021MythsPage", + "elections2021.Elections2021DownloadsPage", ], ) @@ -163,6 +165,8 @@ class SlideBlock(blocks.StructBlock): "elections2021.Elections2021TextPage", "elections2021.Elections2021StrategicListPage", "elections2021.Elections2021StrategicPage", + "elections2021.Elections2021MythsPage", + "elections2021.Elections2021DownloadsPage", ], required=False, ) @@ -340,6 +344,10 @@ class Elections2021HomePage(MetadataPageMixin, RoutablePageMixin, Page): def strategic_list_page_url(self): return get_subpage_url(self, Elections2021StrategicListPage) + @cached_property + def downloads_page_url(self): + return get_subpage_url(self, Elections2021DownloadsPage) + @cached_property def gdpr_and_cookies_url(self): if self.gdpr_and_cookies_page: diff --git a/elections2021/templates/elections2021/base.html b/elections2021/templates/elections2021/base.html index 4ef1eba6eb6fc0c389c19f5bfb03aa4fb99736d1..4c1989208a149147c0a674ce70d6f1042d5344ed 100644 --- a/elections2021/templates/elections2021/base.html +++ b/elections2021/templates/elections2021/base.html @@ -87,6 +87,9 @@ <a href="{{ page.root_page.strategic_list_page_url }}" class="navbar-menu__link">Strategické dokumenty</a> </li> {% endcomment %} + <li class="navbar-menu__item"> + <a href="{{ page.root_page.downloads_page_url }}" class="navbar-menu__link">Ke stažení</a> + </li> </ul> </div> <div class="navbar__actions navbar__section lg:container-padding--auto self-start flex flex-col sm:flex-row lg:flex-col sm:space-x-4 space-y-2 sm:space-y-0 lg:space-y-2 xl:flex-row xl:space-x-2 xl:space-y-0 h-full justify-center">