]> Raphaƫl G. Git Repositories - airbundle/blobdiff - Resources/views/form/_toolbox.html.twig
Remove useless css class
[airbundle] / Resources / views / form / _toolbox.html.twig
index 12e61915b9e0a299d1929325b00d573b972c7a97..916093e37449c59a4e6dd7e0ee6d82b8588ee701 100644 (file)
@@ -1,10 +1,25 @@
-{# Display application or login form #}
-{% if is_granted('ROLE_GUEST') %}
-       <div class="form">
-               {{ include('@RapsysAir/form/_application.html.twig') }}
-       </div>
-{% elseif not is_granted('IS_AUTHENTICATED_REMEMBERED') %}
-       <div class="form">
-               {{ include('@RapsysAir/form/_login.html.twig') }}
-       </div>
+{# Display login or application form #}
+{% if forms is defined and forms %}
+       <aside class="form">
+               {# <header><h2>Toolbox</h2></header> #}
+               {% if forms.register is defined and forms.register %}
+                       {{ include('@RapsysAir/form/_register.html.twig') }}
+               {% endif %}
+               {% if forms.login is defined and forms.login %}
+                       {{ include('@RapsysAir/form/_login.html.twig') }}
+               {% else %}
+                       {% if forms.application is defined %}
+                               {{ include('@RapsysAir/form/_application.html.twig') }}
+                       {% endif %}
+                       {% if forms.location is defined %}
+                               {{ include('@RapsysAir/form/_location.html.twig') }}
+                       {% endif %}
+                       {% if forms.session is defined %}
+                               {{ include('@RapsysAir/form/_session.html.twig') }}
+                       {% endif %}
+                       {% if forms.user is defined %}
+                               {{ include('@RapsysAir/form/_user.html.twig') }}
+                       {% endif %}
+               {% endif %}
+       </aside>
 {% endif %}
 {% endif %}