<?php

use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\CoreExtension;
use Twig\Extension\SandboxExtension;
use Twig\Markup;
use Twig\Sandbox\SecurityError;
use Twig\Sandbox\SecurityNotAllowedTagError;
use Twig\Sandbox\SecurityNotAllowedFilterError;
use Twig\Sandbox\SecurityNotAllowedFunctionError;
use Twig\Source;
use Twig\Template;
use Twig\TemplateWrapper;

/* admin/user_list.html.twig */
class __TwigTemplate_8f2ea11d291551203288bf440665a4cf extends Template
{
    private Source $source;
    /**
     * @var array<string, Template>
     */
    private array $macros = [];

    public function __construct(Environment $env)
    {
        parent::__construct($env);

        $this->source = $this->getSourceContext();

        $this->blocks = [
            'page_title' => [$this, 'block_page_title'],
            'page_content' => [$this, 'block_page_content'],
            'javascripts' => [$this, 'block_javascripts'],
            'stylesheets' => [$this, 'block_stylesheets'],
        ];
    }

    protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
    {
        // line 1
        return "@AdminLTE/layout/cfgodd-layout.html.twig";
    }

    protected function doDisplay(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        $this->parent = $this->load("@AdminLTE/layout/cfgodd-layout.html.twig", 1);
        yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
    }

    // line 3
    /**
     * @return iterable<null|scalar|\Stringable>
     */
    public function block_page_title(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("admin.user.title", [], "messages");
        yield from [];
    }

    // line 5
    /**
     * @return iterable<null|scalar|\Stringable>
     */
    public function block_page_content(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        // line 6
        yield "
            ";
        // line 7
        if ((($tmp = $this->extensions['Symfony\Bridge\Twig\Extension\SecurityExtension']->isGranted("ROLE_ADMIN")) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
            // line 8
            yield "            <div class=\"text-right mb-3\">
                <a href=\"";
            // line 9
            yield $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_user_new");
            yield "\" class=\"btn btn-primary text-right\">
                    <i class=\"fa fa-plus\"></i> ";
            // line 10
            yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("admin.user.add", [], "messages");
            // line 11
            yield "                </a>
            </div>
            ";
        }
        // line 14
        yield "
    ";
        // line 15
        yield from $this->load("admin/user_list.html.twig", 15, "1785098243")->unwrap()->yield($context);
        yield from [];
    }

    // line 110
    /**
     * @return iterable<null|scalar|\Stringable>
     */
    public function block_javascripts(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        // line 111
        yield "    <script src=\"";
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("plugins/datatables/French.json"), "html", null, true);
        yield "\"></script>
    <script>
        \$(function () {
            \$(\"#userTable\").DataTable({
                \"pageLength\": 25,
                \"language\": {
                    \"url\": \"";
        // line 117
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("plugins/datatables/French.json"), "html", null, true);
        yield "\"
                }
            });
        });
    </script>

    <script src=\"";
        // line 123
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("plugins/datatables/jquery.dataTables.js"), "html", null, true);
        yield "\"></script>
    <script src=\"";
        // line 124
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("plugins/datatables-bs4/js/dataTables.bootstrap4.js"), "html", null, true);
        yield "\"></script>
";
        yield from [];
    }

    // line 127
    /**
     * @return iterable<null|scalar|\Stringable>
     */
    public function block_stylesheets(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        // line 128
        yield "    <link rel=\"stylesheet\" href=\"";
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("plugins/datatables-bs4/css/dataTables.bootstrap4.css"), "html", null, true);
        yield "\">
";
        yield from [];
    }

    /**
     * @codeCoverageIgnore
     */
    public function getTemplateName(): string
    {
        return "admin/user_list.html.twig";
    }

    /**
     * @codeCoverageIgnore
     */
    public function isTraitable(): bool
    {
        return false;
    }

    /**
     * @codeCoverageIgnore
     */
    public function getDebugInfo(): array
    {
        return array (  143 => 128,  136 => 127,  129 => 124,  125 => 123,  116 => 117,  106 => 111,  99 => 110,  94 => 15,  91 => 14,  86 => 11,  84 => 10,  80 => 9,  77 => 8,  75 => 7,  72 => 6,  65 => 5,  54 => 3,  43 => 1,);
    }

    public function getSourceContext(): Source
    {
        return new Source("", "admin/user_list.html.twig", "/var/www/html/templates/admin/user_list.html.twig");
    }
}


/* admin/user_list.html.twig */
class __TwigTemplate_8f2ea11d291551203288bf440665a4cf___1785098243 extends Template
{
    private Source $source;
    /**
     * @var array<string, Template>
     */
    private array $macros = [];

    public function __construct(Environment $env)
    {
        parent::__construct($env);

        $this->source = $this->getSourceContext();

        $this->blocks = [
            'box_body' => [$this, 'block_box_body'],
        ];
    }

    protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
    {
        // line 15
        return "@AdminLTE/Widgets/box-widget.html.twig";
    }

    protected function doDisplay(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        $this->parent = $this->load("@AdminLTE/Widgets/box-widget.html.twig", 15);
        yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
    }

    // line 16
    /**
     * @return iterable<null|scalar|\Stringable>
     */
    public function block_box_body(array $context, array $blocks = []): iterable
    {
        $macros = $this->macros;
        // line 17
        yield "            <table id=\"userTable\" class=\"table table-striped\">
            <thead>
                <th>";
        // line 19
        yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.familyName", [], "messages");
        yield "</th>
                <th>";
        // line 20
        yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.givenName", [], "messages");
        yield "</th>
                <th>";
        // line 21
        yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.email", [], "messages");
        yield "</th>
                <th>";
        // line 22
        yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.ministry", [], "messages");
        yield "</th>
                <th>";
        // line 23
        yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.department", [], "messages");
        yield "</th>
                <th>";
        // line 24
        yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.commune", [], "messages");
        yield "</th>
                <th class=\"text-right\">";
        // line 25
        yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.roles", [], "messages");
        yield "</th>
                ";
        // line 26
        if ((($tmp = $this->extensions['Symfony\Bridge\Twig\Extension\SecurityExtension']->isGranted("ROLE_ADMIN")) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
            // line 27
            yield "                    <th style=\"width: 100px\"></th>
                ";
        }
        // line 29
        yield "            </thead>
            <tbody>
            ";
        // line 31
        $context['_parent'] = $context;
        $context['_seq'] = CoreExtension::ensureTraversable(($context["users"] ?? null));
        $context['loop'] = [
          'parent' => $context['_parent'],
          'index0' => 0,
          'index'  => 1,
          'first'  => true,
        ];
        if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
            $length = count($context['_seq']);
            $context['loop']['revindex0'] = $length - 1;
            $context['loop']['revindex'] = $length;
            $context['loop']['length'] = $length;
            $context['loop']['last'] = 1 === $length;
        }
        foreach ($context['_seq'] as $context["_key"] => $context["user"]) {
            // line 32
            yield "                <tr>
                    <td>";
            // line 33
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["user"], "familyName", [], "any", false, false, false, 33), "html", null, true);
            yield "</td>
                    <td>";
            // line 34
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["user"], "givenName", [], "any", false, false, false, 34), "html", null, true);
            yield "</td>
                    <td>";
            // line 35
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["user"], "email", [], "any", false, false, false, 35), "html", null, true);
            yield "</td>
                    <td>";
            // line 36
            yield (((($tmp = CoreExtension::getAttribute($this->env, $this->source, $context["user"], "direction", [], "any", false, false, false, 36)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) ? ($this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["user"], "direction", [], "any", false, false, false, 36), "ministry", [], "any", false, false, false, 36), "code", [], "any", false, false, false, 36), "html", null, true)) : (""));
            yield "</td>
                    <td>";
            // line 37
            yield (((($tmp = CoreExtension::getAttribute($this->env, $this->source, $context["user"], "department", [], "any", false, false, false, 37)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) ? ($this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["user"], "department", [], "any", false, false, false, 37), "name", [], "any", false, false, false, 37), "html", null, true)) : (""));
            yield "</td>
                    <td>";
            // line 38
            yield (((($tmp = CoreExtension::getAttribute($this->env, $this->source, $context["user"], "commune", [], "any", false, false, false, 38)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) ? ($this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["user"], "commune", [], "any", false, false, false, 38), "name", [], "any", false, false, false, 38), "html", null, true)) : (""));
            yield "</td>
                    <td class=\"text-center\">
                        ";
            // line 40
            yield from $this->load("partials/roles.html.twig", 40)->unwrap()->yield($context);
            // line 41
            yield "                    </td>
                    ";
            // line 42
            if ((($tmp = $this->extensions['Symfony\Bridge\Twig\Extension\SecurityExtension']->isGranted("ROLE_ADMIN")) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
                // line 43
                yield "                        <td class=\"text-center\">
                            <div class=\"btn-group\">
                                <a href=\"";
                // line 45
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_user", ["id" => CoreExtension::getAttribute($this->env, $this->source, $context["user"], "id", [], "any", false, false, false, 45)]), "html", null, true);
                yield "\" class=\"btn btn-sm btn-default\" role=\"button\" aria-pressed=\"true\">";
                yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.update", [], "messages");
                yield "</a>
                                ";
                // line 46
                if ((($tmp = $this->extensions['Symfony\Bridge\Twig\Extension\SecurityExtension']->isGranted("ROLE_ADMIN")) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
                    // line 47
                    yield "                                <button type=\"button\" class=\"btn btn-sm btn-default dropdown-toggle\" data-toggle=\"dropdown\">
                                    <span class=\"caret\"></span>
                                    <span class=\"sr-only\">Toggle Dropdown</span>
                                </button>
                                <div class=\"dropdown-menu\" role=\"menu\">
                                    <a class=\"dropdown-item\" href=\"#\" data-toggle=\"modal\" data-target=\"#modal-reinit-";
                    // line 52
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["user"], "id", [], "any", false, false, false, 52), "html", null, true);
                    yield "\">Réinitialiser MP</a>
                                    <!--<a class=\"dropdown-item\" href=\"#\" data-toggle=\"modal\" data-target=\"#modal-delete-";
                    // line 53
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["user"], "id", [], "any", false, false, false, 53), "html", null, true);
                    yield "\">";
                    yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.delete", [], "messages");
                    yield "</a>-->
                                </div>


                                <div class=\"modal fade\" id=\"modal-reinit-";
                    // line 57
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["user"], "id", [], "any", false, false, false, 57), "html", null, true);
                    yield "\">
                                    <div class=\"modal-dialog\">
                                        <div class=\"modal-content\">
                                            <div class=\"modal-header\">
                                                <h5 class=\"modal-title\">Voulez-vous vraiment réinitialiser le mot de passe pour cet utilisateur ?</h5>
                                                <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">
                                                    <span aria-hidden=\"true\">&times;</span>
                                                </button>
                                            </div>
                                            <div class=\"modal-body\">
                                                <b> ";
                    // line 67
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["user"], "familyName", [], "any", false, false, false, 67), "html", null, true);
                    yield "  ";
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["user"], "givenName", [], "any", false, false, false, 67), "html", null, true);
                    yield "</b>
                                            </div>
                                            <div class=\"modal-footer justify-content-between\">
                                                <button type=\"button\" class=\"btn btn-default\" data-dismiss=\"modal\">";
                    // line 70
                    yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.no", [], "messages");
                    yield "</button>
                                                <a href=\"";
                    // line 71
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_user_reinit", ["id" => CoreExtension::getAttribute($this->env, $this->source, $context["user"], "id", [], "any", false, false, false, 71)]), "html", null, true);
                    yield "\" class=\"btn btn-danger\">";
                    yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.yes", [], "messages");
                    yield "</a>
                                            </div>
                                        </div>
                                    </div>
                                </div>

    
                                <div class=\"modal fade\" id=\"modal-delete-";
                    // line 78
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["user"], "id", [], "any", false, false, false, 78), "html", null, true);
                    yield "\">
                                    <div class=\"modal-dialog\">
                                        <div class=\"modal-content\">
                                            <div class=\"modal-header\">
                                                <h5 class=\"modal-title\">Voulez-vous vraiment supprimer cet utilisateur ?</h5>
                                                <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">
                                                    <span aria-hidden=\"true\">&times;</span>
                                                </button>
                                            </div>
                                            <div class=\"modal-body\">
                                                <b> ";
                    // line 88
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["user"], "familyName", [], "any", false, false, false, 88), "html", null, true);
                    yield "  ";
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["user"], "givenName", [], "any", false, false, false, 88), "html", null, true);
                    yield "</b>
                                            </div>
                                            <div class=\"modal-footer justify-content-between\">
                                                <button type=\"button\" class=\"btn btn-default\" data-dismiss=\"modal\">";
                    // line 91
                    yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.no", [], "messages");
                    yield "</button>
                                                <a href=\"";
                    // line 92
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_user_delete", ["id" => CoreExtension::getAttribute($this->env, $this->source, $context["user"], "id", [], "any", false, false, false, 92)]), "html", null, true);
                    yield "\" class=\"btn btn-danger\">";
                    yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("basics.yes", [], "messages");
                    yield "</a>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                                ";
                }
                // line 98
                yield "                            </div>
                        </td>
                    ";
            }
            // line 101
            yield "                </tr>
            ";
            ++$context['loop']['index0'];
            ++$context['loop']['index'];
            $context['loop']['first'] = false;
            if (isset($context['loop']['revindex0'], $context['loop']['revindex'])) {
                --$context['loop']['revindex0'];
                --$context['loop']['revindex'];
                $context['loop']['last'] = 0 === $context['loop']['revindex0'];
            }
        }
        $_parent = $context['_parent'];
        unset($context['_seq'], $context['_key'], $context['user'], $context['_parent'], $context['loop']);
        $context = array_intersect_key($context, $_parent) + $_parent;
        // line 103
        yield "            </tbody>
            </table>
        ";
        yield from [];
    }

    /**
     * @codeCoverageIgnore
     */
    public function getTemplateName(): string
    {
        return "admin/user_list.html.twig";
    }

    /**
     * @codeCoverageIgnore
     */
    public function isTraitable(): bool
    {
        return false;
    }

    /**
     * @codeCoverageIgnore
     */
    public function getDebugInfo(): array
    {
        return array (  441 => 103,  426 => 101,  421 => 98,  410 => 92,  406 => 91,  398 => 88,  385 => 78,  373 => 71,  369 => 70,  361 => 67,  348 => 57,  339 => 53,  335 => 52,  328 => 47,  326 => 46,  320 => 45,  316 => 43,  314 => 42,  311 => 41,  309 => 40,  304 => 38,  300 => 37,  296 => 36,  292 => 35,  288 => 34,  284 => 33,  281 => 32,  264 => 31,  260 => 29,  256 => 27,  254 => 26,  250 => 25,  246 => 24,  242 => 23,  238 => 22,  234 => 21,  230 => 20,  226 => 19,  222 => 17,  215 => 16,  204 => 15,  143 => 128,  136 => 127,  129 => 124,  125 => 123,  116 => 117,  106 => 111,  99 => 110,  94 => 15,  91 => 14,  86 => 11,  84 => 10,  80 => 9,  77 => 8,  75 => 7,  72 => 6,  65 => 5,  54 => 3,  43 => 1,);
    }

    public function getSourceContext(): Source
    {
        return new Source("", "admin/user_list.html.twig", "/var/www/html/templates/admin/user_list.html.twig");
    }
}
