Преглед на файлове

Ensure that forms render properly withouth MopaBootstrap

Hugo Briand преди 11 години
родител
ревизия
33c391e5ca
променени са 1 файла, в които са добавени 13 реда и са изтрити 0 реда
  1. 13 0
      Resources/views/Form/form_admin_fields.html.twig

+ 13 - 0
Resources/views/Form/form_admin_fields.html.twig

@@ -8,6 +8,19 @@ For the full copyright and license information, please view the LICENSE
 file that was distributed with this source code.
 
 #}
+
+{% extends 'form_div_layout.html.twig' %}
+
+{% block form_widget_simple %}
+    {% set attr = attr|merge({'class': attr.class|default('') ~ ' form-control'}) %}
+    {{ parent() }}
+{% endblock form_widget_simple %}
+
+{% block textarea_widget %}
+    {% set attr = attr|merge({'class': attr.class|default('') ~ ' form-control'}) %}
+    {{ parent() }}
+{% endblock textarea_widget %}
+
 {# Labels #}
 {% block form_label %}
 {% spaceless %}