<?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;

/* tchat/_tchat_groupe_config.html.twig */
class __TwigTemplate_3813a0f09eec256783e616c3877a043c456be92d9d892635431715715d76b5a4 extends Template
{
    private $source;
    private $macros = [];

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

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

        $this->parent = false;

        $this->blocks = [
        ];
    }

    protected function doDisplay(array $context, array $blocks = [])
    {
        $macros = $this->macros;
        $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
        $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "tchat/_tchat_groupe_config.html.twig"));

        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "tchat/_tchat_groupe_config.html.twig"));

        // line 1
        yield "
<div class=\"p-3\">
    <div class=\"messages\">
        ";
        // line 4
        if (array_key_exists("message", $context)) {
            // line 5
            yield "            ";
            // line 6
            yield "            <div class=\"alert alert-dismissible alert-success fade show\" role=\"alert\">
                ";
            // line 7
            yield (isset($context["message"]) || array_key_exists("message", $context) ? $context["message"] : (function () { throw new RuntimeError('Variable "message" does not exist.', 7, $this->source); })());
            yield "
                <button type=\"button\" class=\"btn-close\" data-bs-dismiss=\"alert\" aria-label=\"Close\" style=\"opacity:1\"></button>
            </div>
        ";
        }
        // line 11
        yield "    </div>
    <div class=\"mb-3 row\">
        <label for=\"titre_filtre\" class=\"col-sm-2 col-form-label\"><b>Groupe</b></label>
        <div class=\"col-sm-10\">
            <input type=\"text\" class=\"form-control-sm form-control\"  value=\"";
        // line 15
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["groupe"]) || array_key_exists("groupe", $context) ? $context["groupe"] : (function () { throw new RuntimeError('Variable "groupe" does not exist.', 15, $this->source); })()), "nom", [], "any", false, false, false, 15), "html", null, true);
        yield "\" readonly>
        </div>
    </div>
    <div class=\"col\" style=\"padding-right:2rem;position:relative\">
        <table class=\"table table-lg table-bordered\" id=\"tab-group-members-";
        // line 19
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["groupe"]) || array_key_exists("groupe", $context) ? $context["groupe"] : (function () { throw new RuntimeError('Variable "groupe" does not exist.', 19, $this->source); })()), "id", [], "any", false, false, false, 19), "html", null, true);
        yield "\" style=\"min-width:400px\">
            <thead>
                <th>Membres</th>
                <th>Notification</th>
                <th>Action</th>
            </thead>
            <tbody>
                ";
        // line 26
        $context['_parent'] = $context;
        $context['_seq'] = CoreExtension::ensureTraversable(CoreExtension::getAttribute($this->env, $this->source, (isset($context["groupe"]) || array_key_exists("groupe", $context) ? $context["groupe"] : (function () { throw new RuntimeError('Variable "groupe" does not exist.', 26, $this->source); })()), "groupesUtilisateur", [], "any", false, false, false, 26));
        foreach ($context['_seq'] as $context["_key"] => $context["groupeUtilisateur"]) {
            // line 27
            yield "                    ";
            if (CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["groupeUtilisateur"], "utilisateur", [], "any", false, false, false, 27), "isAgent", [], "any", false, false, false, 27)) {
                // line 28
                yield "                        <tr disabled style=\"background-color: #e6e6e6;\">
                            <td>";
                // line 29
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["groupeUtilisateur"], "utilisateur", [], "any", false, false, false, 29), "nomComplet", [], "any", false, false, false, 29), "html", null, true);
                yield "</td>
                            <td></td>
                            <td></td>
                        </tr>
                    ";
            } else {
                // line 34
                yield "                        <tr>
                            <td>";
                // line 35
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["groupeUtilisateur"], "utilisateur", [], "any", false, false, false, 35), "nomComplet", [], "any", false, false, false, 35), "html", null, true);
                yield "</td>
                            <td align=\"middle\"> <i class=\"tchat-group-notif fas fa-bell fa-lg  ";
                // line 36
                yield (((0 === CoreExtension::compare(CoreExtension::getAttribute($this->env, $this->source, $context["groupeUtilisateur"], "notification", [], "any", false, false, false, 36), 0))) ? ("fa-unselected") : (""));
                yield "\" data-idutilisateur=\"";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["groupeUtilisateur"], "utilisateur", [], "any", false, false, false, 36), "id", [], "any", false, false, false, 36), "html", null, true);
                yield "\" data-idgroupe=\"";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["groupe"]) || array_key_exists("groupe", $context) ? $context["groupe"] : (function () { throw new RuntimeError('Variable "groupe" does not exist.', 36, $this->source); })()), "id", [], "any", false, false, false, 36), "html", null, true);
                yield "\"></i></td>
                            <td align=\"middle\"><i class=\"tchat-group-delete fas fa-trash fa-lg\" data-idutilisateur=\"";
                // line 37
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["groupeUtilisateur"], "utilisateur", [], "any", false, false, false, 37), "id", [], "any", false, false, false, 37), "html", null, true);
                yield "\" data-idgroupe=\"";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["groupe"]) || array_key_exists("groupe", $context) ? $context["groupe"] : (function () { throw new RuntimeError('Variable "groupe" does not exist.', 37, $this->source); })()), "id", [], "any", false, false, false, 37), "html", null, true);
                yield "\"></i></td>
                        </tr>
                    ";
            }
            // line 40
            yield "                ";
        }
        $_parent = $context['_parent'];
        unset($context['_seq'], $context['_iterated'], $context['_key'], $context['groupeUtilisateur'], $context['_parent'], $context['loop']);
        $context = array_intersect_key($context, $_parent) + $_parent;
        // line 41
        yield "            </tbody>
        </table>
        <a ><i class=\"fa fa-plus add-icon add-group-user\" data-id=\"";
        // line 43
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["groupe"]) || array_key_exists("groupe", $context) ? $context["groupe"] : (function () { throw new RuntimeError('Variable "groupe" does not exist.', 43, $this->source); })()), "id", [], "any", false, false, false, 43), "html", null, true);
        yield "\" style=\"right: -12px;\"></i></a>
    </div>
    <div class=\"form-group d-flex justify-content-center mt-4\">
        <div class=\"form-actions-row\">
            <button class=\"btn btn-danger btn-close-popup\" data-dxpopup-id=\"popup-tchat-groupe\" style=\"background-color: white;color: #e74c3c;\">Annuler</button>
            ";
        // line 48
        if ((0 === CoreExtension::compare(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["groupe"]) || array_key_exists("groupe", $context) ? $context["groupe"] : (function () { throw new RuntimeError('Variable "groupe" does not exist.', 48, $this->source); })()), "admin", [], "any", false, false, false, 48), "id", [], "any", false, false, false, 48), CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 48, $this->source); })()), "user", [], "any", false, false, false, 48), "id", [], "any", false, false, false, 48)))) {
            // line 49
            yield "                <button class=\"btn btn-danger btn-groupe-delete \" data-dxpopup-id=\"popup-tchat-groupe\" data-href=\"";
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("tchat_groupe_delete", ["id" => CoreExtension::getAttribute($this->env, $this->source, (isset($context["groupe"]) || array_key_exists("groupe", $context) ? $context["groupe"] : (function () { throw new RuntimeError('Variable "groupe" does not exist.', 49, $this->source); })()), "id", [], "any", false, false, false, 49)]), "html", null, true);
            yield "\"><i class=\"fas fa-trash fa-lg me-2\"></i>Supprimer le groupe</button>
            ";
        }
        // line 51
        yield "        </div>
    </div>
</div>";
        
        $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);

        
        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);

        return; yield '';
    }

    /**
     * @codeCoverageIgnore
     */
    public function getTemplateName()
    {
        return "tchat/_tchat_groupe_config.html.twig";
    }

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

    /**
     * @codeCoverageIgnore
     */
    public function getDebugInfo()
    {
        return array (  153 => 51,  147 => 49,  145 => 48,  137 => 43,  133 => 41,  127 => 40,  119 => 37,  111 => 36,  107 => 35,  104 => 34,  96 => 29,  93 => 28,  90 => 27,  86 => 26,  76 => 19,  69 => 15,  63 => 11,  56 => 7,  53 => 6,  51 => 5,  49 => 4,  44 => 1,);
    }

    public function getSourceContext()
    {
        return new Source("
<div class=\"p-3\">
    <div class=\"messages\">
        {% if message is defined %}
            {# Bootstrap alert, see https://getbootstrap.com/docs/3.4/components/#alerts #}
            <div class=\"alert alert-dismissible alert-success fade show\" role=\"alert\">
                {{ message|raw }}
                <button type=\"button\" class=\"btn-close\" data-bs-dismiss=\"alert\" aria-label=\"Close\" style=\"opacity:1\"></button>
            </div>
        {% endif %}
    </div>
    <div class=\"mb-3 row\">
        <label for=\"titre_filtre\" class=\"col-sm-2 col-form-label\"><b>Groupe</b></label>
        <div class=\"col-sm-10\">
            <input type=\"text\" class=\"form-control-sm form-control\"  value=\"{{ groupe.nom }}\" readonly>
        </div>
    </div>
    <div class=\"col\" style=\"padding-right:2rem;position:relative\">
        <table class=\"table table-lg table-bordered\" id=\"tab-group-members-{{ groupe.id }}\" style=\"min-width:400px\">
            <thead>
                <th>Membres</th>
                <th>Notification</th>
                <th>Action</th>
            </thead>
            <tbody>
                {% for groupeUtilisateur in groupe.groupesUtilisateur %}
                    {% if groupeUtilisateur.utilisateur.isAgent %}
                        <tr disabled style=\"background-color: #e6e6e6;\">
                            <td>{{ groupeUtilisateur.utilisateur.nomComplet }}</td>
                            <td></td>
                            <td></td>
                        </tr>
                    {% else %}
                        <tr>
                            <td>{{ groupeUtilisateur.utilisateur.nomComplet }}</td>
                            <td align=\"middle\"> <i class=\"tchat-group-notif fas fa-bell fa-lg  {{ (groupeUtilisateur.notification == 0) ? 'fa-unselected' }}\" data-idutilisateur=\"{{ groupeUtilisateur.utilisateur.id }}\" data-idgroupe=\"{{ groupe.id }}\"></i></td>
                            <td align=\"middle\"><i class=\"tchat-group-delete fas fa-trash fa-lg\" data-idutilisateur=\"{{ groupeUtilisateur.utilisateur.id }}\" data-idgroupe=\"{{ groupe.id }}\"></i></td>
                        </tr>
                    {% endif %}
                {% endfor %}
            </tbody>
        </table>
        <a ><i class=\"fa fa-plus add-icon add-group-user\" data-id=\"{{ groupe.id }}\" style=\"right: -12px;\"></i></a>
    </div>
    <div class=\"form-group d-flex justify-content-center mt-4\">
        <div class=\"form-actions-row\">
            <button class=\"btn btn-danger btn-close-popup\" data-dxpopup-id=\"popup-tchat-groupe\" style=\"background-color: white;color: #e74c3c;\">Annuler</button>
            {% if groupe.admin.id == app.user.id %}
                <button class=\"btn btn-danger btn-groupe-delete \" data-dxpopup-id=\"popup-tchat-groupe\" data-href=\"{{ path('tchat_groupe_delete', {id: groupe.id}) }}\"><i class=\"fas fa-trash fa-lg me-2\"></i>Supprimer le groupe</button>
            {% endif %}
        </div>
    </div>
</div>", "tchat/_tchat_groupe_config.html.twig", "/builds/dev/refonte_sav/templates/tchat/_tchat_groupe_config.html.twig");
    }
}
