Fab 3 anni fa
parent
commit
db892f83e0
3 ha cambiato i file con 9 aggiunte e 9 eliminazioni
  1. +3
    -3
      config/routes.yaml
  2. +4
    -4
      templates/base.html.twig
  3. +2
    -2
      templates/block/nav.html.twig

+ 3
- 3
config/routes.yaml Vedi File

@@ -12,10 +12,10 @@ admin_dashboard:
path: /admin
controller: App\Controller\Admin\DashboardController::index

home:
path: /
app_homepage:
path: /
defaults: { _controller: App\Controller\IndexController::index , _locale: fr}

page:
app_page:
path: /page/{pageSlug}
controller: App\Controller\IndexController::page

+ 4
- 4
templates/base.html.twig Vedi File

@@ -26,10 +26,10 @@
<meta property="og:url" content="{{ app.request.uri }}"/>

<link rel="icon" type="image/png" href="{{ asset('assets/img/favicon.png') }}"/>
{#
{% block stylesheets %}
{{ encore_entry_link_tags('tabler') }}
{% endblock %}
{% endblock %}#}
</head>
<body>
{% block body %}
@@ -51,8 +51,8 @@

{% endblock %}

{% block javascripts %}
{#{% block javascripts %}
{{ encore_entry_script_tags('tabler') }}
{% endblock %}
{% endblock %}#}
</body>
</html>

+ 2
- 2
templates/block/nav.html.twig Vedi File

@@ -1,10 +1,10 @@
<ul id="menu">
<li class="elm-menu">
<a class="{{ app.request.attributes.get('_route') == '_homepage' ? 'selected' : '' }}" href="{{ path('_homepage') }}">{{ 'menu.home'|trans }}</a>
<a class="{{ app.request.attributes.get('_route') == 'app_homepage' ? 'selected' : '' }}" href="{{ path('app_homepage') }}">{{ 'menu.home'|trans }}</a>
</li>
{% for page in getPagesNav() %}
<li class="elm-menu">
<a class="{{ app.request.get('pageSlug') == page.slug ? 'selected' : '' }}" href="{{ path('_page', {'pageSlug' : page.slug}) }}">{{ page.title }}</a>
<a class="{{ app.request.get('pageSlug') == page.slug ? 'selected' : '' }}" href="{{ path('app_page', {'pageSlug' : page.slug}) }}">{{ page.title }}</a>
</li>
{% endfor %}
</ul>

Loading…
Annulla
Salva