50 lines
2.0 KiB
Twig
50 lines
2.0 KiB
Twig
{% extends 'base.html.twig' %}
|
|
|
|
{% block title %} = {{title}}{% endblock %}
|
|
|
|
{% block body %}
|
|
<h1>{{title}}</h1>
|
|
<a href="{{ path(routesubmit) }}" class="btn btn-success">Ajouter</a>
|
|
|
|
<div class="dataTable_wrapper">
|
|
<table class="table table-striped table-bordered table-hover" id="dataTables" style="width:100%">
|
|
<thead>
|
|
<tr>
|
|
<th width="70px" class="no-sort">Action</th>
|
|
<th width="120px">Icône</th>
|
|
<th width="120px">Compte</th>
|
|
<th width="150px">Catégorie</th>
|
|
<th>Titre</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for accounting in accountings %}
|
|
<tr>
|
|
<td><a href="{{ path(routeupdate,{id:accounting.id}) }}"><i class="fas fa-file fa-2x"></i></a></td>
|
|
<td class="text-center">
|
|
{% if accounting.icon %}
|
|
<i class="fas {{accounting.icon}} fa-2x"></i>
|
|
{% endif %}
|
|
<td>{{accounting.num01}}-{{accounting.num02}}</td>
|
|
<td>{{accounting.category}}</td>
|
|
<td>{{accounting.title}}</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
{% endblock %}
|
|
|
|
{% block localscript %}
|
|
<script>
|
|
$(document).ready(function() {
|
|
$('#dataTables').DataTable({
|
|
columnDefs: [ { "targets": "no-sort", "orderable": false }, { "targets": "no-string", "type" : "num" } ],
|
|
responsive: true,
|
|
iDisplayLength: 100,
|
|
order: [[ 1, "asc" ]]
|
|
});
|
|
});
|
|
</script>
|
|
{% endblock %}
|