{% set menuLeft = getRouteName() %}
{% do setAriane(0, 'Gestion des types de filtre' | trad, {
	countNotif: pagination.nbrArticle
}) %}

{% extends 'refreshdiv-layout.twig' %}

{% block body %}
<section class="contenu">
	<header class="bs-row flex-y-center">
		<h1 class="bs-col">{{ 'Gestion des types de filtre' | trad }}</h1>
		<div class="bs-col text-right">
			<a class="button principal"
				href="{{ path('EtatStatistique.FiltreUtil.formCreate') }}"
			>{{ 'Créer un filtre' | trad }}</a>
		</div>
	</header>
	{{ ariane() }}

	{% embed '@EtatStatistiques/Tableau/_gestable.twig' with {
		table: {
			listCol: [
				{
					name: 'FENT_CODE_FILTRE',
					label: 'Code' | trad,
					filter: {type: 'text'},
					sortable: true,
				},
				{
					name: 'FENT_LIB_FILTRE',
					label: 'Libellé' | trad,
					filter: {type: 'text'},
					sortable: true,
				},
				{
					name: 'FENT_TYPE_AFFICHAGE',
					label: 'Type d’affichage' | trad,
				}
			],
			listRow: listRow,
			pagination: pagination,
			action: true,
		},
		post: post,
	} only %}
		{% block cell_FENT_TYPE_AFFICHAGE %}
		<td>{{ {
			L: 'Liste' | trad,
			R: 'Requête' | trad,
		}[ item.FENT_TYPE_AFFICHAGE ] }}</td>
		{% endblock %}
	{% endembed %}
</section>

{% endblock %}