Merge pull request #1290 from openclassify/vedatakd

update navigation
This commit is contained in:
Fatih Alp 2022-02-16 16:24:21 +03:00 committed by GitHub
commit f79f373eaf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 30 additions and 7 deletions

View File

@ -11,6 +11,7 @@
},
"require": {
"fruitcake/laravel-cors": "^2.0",
"visiosoft/style_selector-module": "*"
"visiosoft/style_selector-module": "*",
"visiosoft/submenu-plugin": "*"
}
}

View File

@ -31,5 +31,4 @@ class CatsModule extends Module
]
]
];
}

View File

@ -1,11 +1,34 @@
{% import "visiosoft.theme.defaultadmin::macros/sections.twig" as menu %}
<aside id="menu" class="scrollbar">
<ul>
{% for section in template.cp.sections.root().visible() %}
{{ menu.sections(template.cp.sections, section) }}
{% endfor %}
</ul>
{% if not template.module.parent %}
{% for section in template.cp.sections.root().visible() %}
{{ menu.sections(template.cp.sections, section) }}
{% endfor %}
{% for navigation in getSubmenus(template.module.namespace) %}
<li>
<a href="{{ url(navigation.href) }}">
{{ trans(navigation.title) }}
</a>
</li>
{% endfor %}
{% else %}
{% for navigation in getSections(template.module.parent) %}
<li>
<a href="{{ url(navigation.href) }}">
{{ trans(navigation.title) }}
</a>
</li>
{% endfor %}
{% for navigation in getSections(template.module.namespace) %}
<li>
<a href="{{ url(navigation.href) }}">
{{ trans(navigation.title) }}
</a>
</li>
{% endfor %}
{% endif %}
</ul>
</aside>