Actualización

This commit is contained in:
Xes
2025-04-10 12:24:57 +02:00
parent 8969cc929d
commit 45420b6f0d
39760 changed files with 4303286 additions and 0 deletions

View File

@@ -0,0 +1,51 @@
{#
This file is part of the Sonata package.
(c) Thomas Rabaix <thomas.rabaix@sonata-project.org>
For the full copyright and license information, please view the LICENSE
file that was distributed with this source code.
#}
{% extends sonata_block.templates.block_base %}
{% block block %}
{% for group in groups %}
{% set display = (group.roles is empty or is_granted('ROLE_SUPER_ADMIN') ) %}
{% for role in group.roles if not display %}
{% set display = is_granted(role)%}
{% endfor %}
{% if display %}
<div class="box">
<div class="box-header">
<h3 class="box-title">{{ group.label|trans({}, group.label_catalogue) }}</h3>
</div>
<div class="box-body">
<table class="table table-hover">
<tbody>
{% for admin in group.items %}
{% if admin.dashboardActions|length > 0 %}
<tr>
<td class="sonata-ba-list-label" width="40%">
{{ admin.label|trans({}, admin.translationdomain) }}
</td>
<td>
<div class="btn-group">
{% for action in admin.dashboardActions %}
{% include action.template|default('SonataAdminBundle:CRUD:dashboard__action.html.twig') with {'action': action} %}
{% endfor %}
</div>
</td>
</tr>
{% endif %}
{% endfor %}
</tbody>
</table>
</div>
</div>
{% endif %}
{% endfor %}
{% endblock %}

View File

@@ -0,0 +1,31 @@
{#
This file is part of the Sonata package.
(c) Thomas Rabaix <thomas.rabaix@sonata-project.org>
For the full copyright and license information, please view the LICENSE
file that was distributed with this source code.
#}
{% extends "SonataBlockBundle:Block:block_core_rss.html.twig" %}
{% block block %}
<div class="box box-warning">
<div class="box-header with-border">
<h3 class="box-title sonata-feed-title"><i class="fa fa-rss" aria-hidden="true"></i> {{ settings.title }}</h3>
</div>
<div class="sonata-feeds-container list-group">
{% for feed in feeds %}
<a class="list-group-item" href="{{ feed.link}}" rel="nofollow" title="{{ feed.title }}">
<strong>{{ feed.title }}</strong>
<div>{{ feed.description|raw }}</div>
</a>
{% else %}
<div class="list-group-item">No feeds available.</div>
{% endfor %}
</div>
</div>
{% endblock %}

View File

@@ -0,0 +1,67 @@
{#
This file is part of the Sonata package.
(c) Thomas Rabaix <thomas.rabaix@sonata-project.org>
For the full copyright and license information, please view the LICENSE
file that was distributed with this source code.
#}
{% extends sonata_block.templates.block_base %}
{% block block %}
{% set show_empty_boxes = sonata_admin.adminPool.container.getParameter('sonata.admin.configuration.global_search.empty_boxes') %}
{% set visibility_class = 'sonata-search-result-' ~ show_empty_boxes %}
{% if pager and pager.getResults()|length %}
{% set visibility_class = 'sonata-search-result-show' %}
{% endif %}
<div class="col-lg-4 col-md-6 search-box-item {{ visibility_class }}">
<div class="box box-solid box-primary {{ visibility_class }}">
<div class="box-header with-border {{ visibility_class }}">
{% set icon = settings.icon|default('') %}
{{ icon|raw }}
<h3 class="box-title">
{{ admin.label|trans({}, admin.translationdomain) }}
</h3>
<div class="box-tools pull-right">
{% if pager and pager.getNbResults() > 0 %}
<span class="badge bg-light-blue">{{ pager.getNbResults() }}</span>
{% elseif admin.hasRoute('create') and admin.hasAccess('create') %}
<a href="{{ admin.generateUrl('create') }}" class="btn btn-box-tool">
<i class="fa fa-plus" aria-hidden="true"></i>
</a>
{% endif %}
{% if admin.hasRoute('list') and admin.hasAccess('list') %}
<a href="{{ admin.generateUrl('list') }}" class="btn btn-box-tool">
<i class="fa fa-list" aria-hidden="true"></i>
</a>
{% endif %}
</div>
</div>
{% if pager and pager.getResults()|length %}
<div class="box-body no-padding">
<ul class="nav nav-stacked sonata-search-result-list">
{% for result in pager.getResults() %}
{% set link = admin.getSearchResultLink(result) %}
{% if link %}
<li><a href="{{ link }}">{{ admin.toString(result) }}</a></li>
{% else %}
<li><a>{{ admin.toString(result) }}</a></li>
{% endif %}
{% endfor %}
</ul>
</div>
{% else %}
<div class="box-body">
<p>
<em>{{ 'no_results_found'|trans({}, 'SonataAdminBundle') }}</em>
</p>
</div>
{% endif %}
</div>
</div>
{% endblock %}

View File

@@ -0,0 +1,29 @@
{#
This file is part of the Sonata package.
(c) Thomas Rabaix <thomas.rabaix@sonata-project.org>
For the full copyright and license information, please view the LICENSE
file that was distributed with this source code.
#}
{% extends sonata_block.templates.block_base %}
{% block block %}
<!-- small box -->
<div class="small-box {{ settings.color }}">
<div class="inner">
<h3>{{ pager.count() }}</h3>
<p>{{ settings.text|trans({}, admin.translationDomain) }}</p>
</div>
<div class="icon">
<i class="fa {{ settings.icon }}"></i>
</div>
<a href="{{ admin.generateUrl('list', {filter: settings.filters}) }}" class="small-box-footer">
{{ 'stats_view_more'|trans({}, 'SonataAdminBundle') }} <i class="fa fa-arrow-circle-right" aria-hidden="true"></i>
</a>
</div>
{% endblock %}