瀏覽代碼

Various fixes

Hugo Briand 11 年之前
父節點
當前提交
67ee44283a

+ 1 - 1
Resources/doc/reference/action_create_edit.rst

@@ -28,7 +28,7 @@ FormGroup options
 When adding a form group to your edit/create form, you may specify some options for the group itself.
 
 - ``collapsed``: unused at the moment
-- ``class``: the class for your form group in the admin; by default, the value is set to ``col-md-12`` if you have only one formgroup in your form, otherwise to ``col-md-6``.
+- ``class``: the class for your form group in the admin; by default, the value is set to ``col-md-12``.
 - ``fields``: the fields in your form group (you should NOT override this unless you know what you're doing).
 - ``description``: to complete
 - ``translation_domain``: to complete

+ 4 - 0
Resources/public/css/styles.css

@@ -49,6 +49,10 @@ footer a {
     padding: 0 10px;
 }
 
+.right-side > .content-header {
+    padding-bottom: 0;
+}
+
 .content-header .navbar {
     margin-bottom: 0;
 }

+ 1 - 2
Resources/views/CRUD/base_edit_form.html.twig

@@ -24,9 +24,8 @@
             {% endblock %}
 
             {% block sonata_tab_content %}
-                {% set default_class = admin.formgroups|length > 1 ? 'col-md-6' : 'col-md-12' %}
                 {% for name, form_group in admin.formgroups %}
-                    <div class="{{ form_group.class|default(default_class) }}">
+                    <div class="{{ form_group.class|default('col-md-12') }}">
                         <div class="box box-success">
                             <div class="box-header">
                                 <h4 class="box-title">