123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120 |
- {% extends base_template %}
- {% block title %}
- - {{ data.label }}
- {% endblock %}
- {% block breadcrumb %}
- {% set links = [
- {label: 'Auditoría de Entidades'|trans({}, 'AuditBundle'), class: '', link: url('entity_audit')},
- {label: data.label, class: 'active', link: ''}
- ] %}
- {% include "BaseAdminBundle:Utils:breadcrumb.html.twig" with links %}
- {% endblock %}
- {% block list_filters %}
- <fieldset class="filter_legend">
- <div class="col-xs-12 col-md-12">
- <div class="box box-primary">
- <div class="box-header">
- <h4 class="box-title"> {{ 'Resumen'|trans({}, 'AuditBundle') }}: </h4>
- </div>
- <table class="table table-bordered table-striped sonata-ba-list">
- <tbody>
- <tr class="filter inactive">
- <td class="filter-title" width="180"><b>{{ 'Revisión'|trans({}, 'AuditBundle') }}</b>:</td>
- <td class="filter-value">{{ data.rev }}</td>
- </tr>
- <tr class="filter inactive">
- <td class="filter-title"><b>{{ 'Entidad'|trans({}, 'AuditBundle') }}</b>:</td>
- <td class="filter-value">{{ data.className }}</td>
- </tr>
- <tr class="filter inactive">
- <td class="filter-title"><b>{{ 'Id'|trans({}, 'AuditBundle') }}</b>:</td>
- <td class="filter-value">{{ data.id }}</td>
- </tr>
- <tr class="filter inactive">
- <td class="filter-title"><b>{{ 'Usuario'|trans({}, 'AuditBundle') }}</b>:</td>
- <td class="filter-value">{{ data.revdata.username | default('(anonymous)')}}</td>
- </tr>
- <tr class="filter inactive">
- <td class="filter-title"><b>{{ 'Fecha'|trans({}, 'AuditBundle') }}</b>:</td>
- <td class="filter-value">{{ data.revdata.timestamp | date("d/m/Y \\a \\l\\a\\s h:m:s") }} hs</td>
- </tr>
- </tbody>
- </table>
- </div>
- </div>
- <hr>
- <div class="col-xs-12 col-md-12">
- <div class="box box-primary">
- <div class="box-header">
- <h4 class="box-title"> {{ 'Datos actuales de la entidad'|trans({}, 'AuditBundle') }}: </h4>
- </div>
- <table class="table table-bordered table-striped sonata-ba-list">
- <tbody>
- <tr class="filter inactive">
- <td class="filter-title" width="180"><b>{{ 'Campo'|trans({}, 'AuditBundle') }}</b></td>
- <td class="filter-title"><b>{{ 'Valor'|trans({}, 'AuditBundle') }}</b></td>
- </tr>
- </tbody>
- <tbody>
- {% for field, value in data.details %}
- <tr class="filter inactive">
- <td class="filter-value">{{ field }}</td>
- <td class="filter-value">
- {% if value.timestamp is defined %}
- {{ value | date("d/m/Y \\a \\l\\a\\s h:m:s") }}
- {% elseif value is iterable %}
- {{ dump(value) }}
- {% else %}
- {{ value }}
- {% endif %}
- </td>
- </tr>
- {% endfor %}
- </tbody>
- </table>
- </div>
- </div>
- <hr>
- <div class="col-xs-12 col-md-12">
- <div class="box box-primary">
- <div class="box-header">
- <h4 class="box-title"> {{ 'Revisiones efectuadas'|trans({}, 'AuditBundle') }} ({{ data.revisions|length }}): </h4>
- </div>
- <form action="{{ path('entity_audit_compare_revs', { 'className': data.className, 'id': data.id }) }}" method="get">
- <div style="display:block; height:200px; overflow:auto; margin-bottom:10px">
- <table class="table table-bordered table-striped sonata-ba-list" style="width:100%;margin-top:0px;margin-bottom:0px">
- <tbody>
- <tr class="filter inactive">
- <td class="filter-title" style="width:90px;"><b>{{ 'Revisión'|trans({}, 'AuditBundle') }}</b></td>
- <td class="filter-title" style="width:250px;"><b>{{ 'Fecha'|trans({}, 'AuditBundle') }}</b></td>
- <td class="filter-title" style="width:150px;"><b>{{ 'Usuario'|trans({}, 'AuditBundle') }}</b></td>
- <td class="filter-title" style="width:50px;"><b>{{ 'Anterior'|trans({}, 'AuditBundle') }}</b></td>
- <td class="filter-title" style="width:50px;"><b>{{ 'Actual'|trans({}, 'AuditBundle') }}</b></td>
- </tr>
- </tbody>
- <tbody>
- {% for revision in data.revisions %}
- <tr class="filter inactive">
- <td class="filter-value" style="text-align:center;"><a href="{{ path('entity_audit_view_details', { 'className': data.className, 'id': data.id, 'rev': revision.rev }) }}">{{ revision.rev }}</a></td>
- <td class="filter-value">{{ revision.timestamp | date("d/m/Y \\a \\l\\a\\s h:m:s") }}</td>
- <td class="filter-value">{{ revision.username|default('(anonymous)') }}</td>
- <td class="filter-value" style="text-align:center"><input type="radio" name="oldRev" value="{{ revision.rev }}"{% if loop.index == 2 %} checked="checked"{% endif %} /></td>
- <td class="filter-value" style="text-align:center"><input type="radio" name="newRev" value="{{ revision.rev }}"{% if loop.index == 1 %} checked="checked"{% endif %} /></td>
- </tr>
- {% endfor %}
- </tbody>
- </table>
- </div>
- <input class="btn btn-small btn-primary" type="submit" value="{{ 'Comparar'|trans({}, 'AuditBundle') }}" />
- <a class="btn btn-small btn-default" href="{{ path('entity_audit') }}">{{ 'Regresar'|trans({}, 'AuditBundle') }}</a>
- </div>
- </div>
- </form>
- </fieldset>
- {% endblock %}
- {% block content %}{% endblock %}
|