浏览代码

Correctif visuel

develop
Fabien Normand 3 年前
父节点
当前提交
1b5be407fb
共有 4 个文件被更改,包括 59 次插入16 次删除
  1. +2
    -2
      Controller/AbstractAdminController.php
  2. +35
    -0
      Resources/assets/app/adminlte/main/scss/_common.scss
  3. +1
    -1
      Resources/views/adminlte/crud/form_theme.html.twig
  4. +21
    -13
      Resources/views/adminlte/crud/index.html.twig

+ 2
- 2
Controller/AbstractAdminController.php 查看文件

@@ -560,7 +560,7 @@ abstract class AbstractAdminController extends EaAbstractCrudController
Crud::PAGE_EDIT,
Action::SAVE_AND_RETURN,
[
'add_class' => 'float-right',
'add_class' => 'float-right ',
'icon' => 'check',
'label' => $this->get(TranslatorAdmin::class)->transAction('save_and_return'),
]
@@ -583,7 +583,7 @@ abstract class AbstractAdminController extends EaAbstractCrudController
Crud::PAGE_EDIT,
Action::SAVE_AND_CONTINUE,
[
'class' => 'btn btn-info float-right',
'class' => 'btn btn-info float-right action-save-continue',
'label' => $this->get(TranslatorAdmin::class)->transAction('save_and_continue'),
]
);

+ 35
- 0
Resources/assets/app/adminlte/main/scss/_common.scss 查看文件

@@ -28,4 +28,39 @@ nav.main-header {

.nav-treeview .nav-link {
padding: 0.2rem 0.5rem 0.2rem 1.2rem;
}

//TODO à réecrire correctement
.table.datatable-simple .highlight{background: var(--teal);}
.datatable-field-search.small{width: 50px;}

.dataTables_length, .dataTables_filter{padding: .75rem 1.25rem 0.25rem;}

table.fixedHeader-floating{margin-top: 0px !important;}

.card-body table.lc-table-list th.filtered{border-top:2px solid var(--primary);}
.card-body table.lc-table-list th.sorted, table th.sorting_asc, table th.sorting_desc{border-top:2px solid var(--success);}
.card-body table.lc-table-list th.sorted.filtered{border-top:0px; position: relative;}
.card-body table.lc-table-list th.sorted.filtered:after{ content: ''; height: 2px; position: absolute; left: 0; width: 100%; right: 0; top: -1px; background: linear-gradient(to right, var(--success) 0%, var(--success) 50%, var(--primary) 50%, var(--primary) 100%);}

.table-filters-line th {font-weight: 400; position: relative;}
.table-filters-line th input{}
#list_filter_id{width: 60px;}

.delivery-field .form-group{display: inline-block; margin-bottom: 0px; margin-right: 15px;}
.delivery-field .form-group .form-control{width: 150px;}

.table{
thead a{color: #212529}
.date-range{width: 130px;}

th, td{padding: 0.35rem;}
th input{width: 100%;}
th.filtered{border-top:2px solid var(--primary);}
th.actions, td.actions{white-space: nowrap; text-align: right;}
th .select2-container--default .select2-selection--single{padding:0.3rem 0.4rem; }
th.sorting_asc, th.sorting_desc{border-top:2px solid var(--success);}
.actions .btn-sm{
margin-right: 3px;
}
}

+ 1
- 1
Resources/views/adminlte/crud/form_theme.html.twig 查看文件

@@ -119,7 +119,7 @@
{% if not entityNameOrObject and form.parent.vars.errors.form.config.dataClass is defined %}
{% set entityNameOrObject = form.parent.vars.errors.form.config.dataClass %}
{% endif %}
x
{% if translation_domain == null %}
{% set translation_domain = 'admin' %}
{% endif %}

+ 21
- 13
Resources/views/adminlte/crud/index.html.twig 查看文件

@@ -132,26 +132,34 @@
{% block entity_actions %}
<td class="actions text-right">
{% if entity.actions.count > 0 %}
{% set has_dropdown = false %}

{% set in_dropdown_class = 'in-dropdown' %}
{% for action in entity.actions %}
{% if not (in_dropdown_class in action.cssClass) %}
{{ include(action.templatePath, { action: action, entity: entity, isIncludedInDropdown: 0 }, with_context = false) }}
{% else %}
{% set has_dropdown = true %}
{% endif %}

{% endfor %}
<div class="dropdown dropdown-actions">
<a class="dropdown-toggle btn btn-secondary btn-sm" href="#"
role="button" data-toggle="dropdown" aria-haspopup="true"
aria-expanded="false">
</a>

<div class="dropdown-menu dropdown-menu-right">
{% for action in entity.actions %}
{% if in_dropdown_class in action.cssClass %}
{{ include(action.templatePath, { action: action, isIncludedInDropdown: 1 }, with_context = false) }}
{% endif %}
{% endfor %}
{% if has_dropdown %}
<div class="dropdown dropdown-actions">
<a class="dropdown-toggle btn btn-secondary btn-sm" href="#"
role="button" data-toggle="dropdown" aria-haspopup="true"
aria-expanded="false">
</a>

<div class="dropdown-menu dropdown-menu-right">
{% for action in entity.actions %}
{% if in_dropdown_class in action.cssClass %}
{{ include(action.templatePath, { action: action, isIncludedInDropdown: 1 }, with_context = false) }}
{% endif %}
{% endfor %}
</div>
</div>
</div>
{% endif %}

{% endif %}

{% if not ea.crud.showEntityActionsAsDropdown %}

正在加载...
取消
保存