|
@@ -12,7 +12,11 @@ file that was distributed with this source code.
|
|
|
{% extends base_template %}
|
|
|
|
|
|
{% block actions %}
|
|
|
- <li>{% include 'SonataAdminBundle:Core:create_button.html.twig' %}</li>
|
|
|
+{% spaceless %}
|
|
|
+ {% if admin.hasRoute('create') and admin.isGranted('CREATE')%}
|
|
|
+ <li>{% include 'SonataAdminBundle:Core:create_button.html.twig' %}</li>
|
|
|
+ {% endif %}
|
|
|
+{% endspaceless %}
|
|
|
{% endblock %}
|
|
|
|
|
|
{% block tab_menu %}{{ knp_menu_render(admin.sidemenu(action), {'currentClass' : 'active', 'template': admin_pool.getTemplate('tab_menu_template')}, 'twig') }}{% endblock %}
|