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

/* agent/_affectation.html.twig */
class __TwigTemplate_2e9adecd206ca19114a666047ce9ed92c84f9ed6709f05c93d43ce3981b10d4a 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", "agent/_affectation.html.twig"));

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

        // line 1
        if (((0 === CoreExtension::compare((isset($context["type"]) || array_key_exists("type", $context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.', 1, $this->source); })()), "show")) && (0 === CoreExtension::compare((isset($context["programmation"]) || array_key_exists("programmation", $context) ? $context["programmation"] : (function () { throw new RuntimeError('Variable "programmation" does not exist.', 1, $this->source); })()), "non")))) {
            // line 2
            yield "    <div class=\"form-check\">
        <input class=\"form-check-input\" disabled style=\"margin-top:0.6rem;\" type=\"checkbox\" ";
            // line 3
            yield ((((isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 3, $this->source); })()) && CoreExtension::getAttribute($this->env, $this->source, (isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 3, $this->source); })()), "planifiable", [], "any", false, false, false, 3))) ? ("checked") : (""));
            yield ">
        <label class=\"form-check-label me-1 \"  style=\"padding-top: 0.4rem;\"> Planifiable</label>
    </div>
";
        }
        // line 7
        yield "<div class=\"d-flex\">
    <div class=\"d-flex flex-column\">
        ";
        // line 9
        if ((0 === CoreExtension::compare((isset($context["programmation"]) || array_key_exists("programmation", $context) ? $context["programmation"] : (function () { throw new RuntimeError('Variable "programmation" does not exist.', 9, $this->source); })()), "oui"))) {
            // line 10
            yield "        <div class=\"form-check align-self-center\" style=\"margin-left: 0.9rem;margin-bottom: 5px;\">
            <input class=\"form-check-input\" type=\"checkbox\" value=\"OUI\" id=\"planifiable-";
            // line 11
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["type"]) || array_key_exists("type", $context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.', 11, $this->source); })()), "html", null, true);
            yield "\" ";
            yield (((0 === CoreExtension::compare((isset($context["type"]) || array_key_exists("type", $context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.', 11, $this->source); })()), "show"))) ? ("disabled") : ("name=\"planifiable\""));
            yield " style=\"margin-top:0.6rem;\" ";
            yield ((((((0 === CoreExtension::compare((isset($context["type"]) || array_key_exists("type", $context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.', 11, $this->source); })()), "show")) && (isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 11, $this->source); })())) && CoreExtension::getAttribute($this->env, $this->source, (isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 11, $this->source); })()), "planifiable", [], "any", false, false, false, 11)) || (((0 !== CoreExtension::compare(            // line 12
(isset($context["type"]) || array_key_exists("type", $context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.', 12, $this->source); })()), "show")) && (isset($context["hasNext"]) || array_key_exists("hasNext", $context) ? $context["hasNext"] : (function () { throw new RuntimeError('Variable "hasNext" does not exist.', 12, $this->source); })())) && CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["agent"]) || array_key_exists("agent", $context) ? $context["agent"] : (function () { throw new RuntimeError('Variable "agent" does not exist.', 12, $this->source); })()), "nextAffectation", [], "any", false, false, false, 12), "planifiable", [], "any", false, false, false, 12)))) ? ("checked") : (""));
            // line 13
            yield ">
            <label class=\"form-check-label me-1 \" for=\"planifiable-";
            // line 14
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["type"]) || array_key_exists("type", $context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.', 14, $this->source); })()), "html", null, true);
            yield "\"  style=\"padding-top: 0.4rem;\"> Planifiable</label>
        </div>
        ";
        } else {
            // line 17
            yield "        <div class=\"d-flex align-items-center\" style=\"margin-right:2rem;margin-bottom: 5px;\">
            <label class=\"me-1\" style=\"width:117px\">Date d'embauche</label>
            <input type=\"date\"  style=\"width:128px\"  data-disable-on-view=\"\" name=\"date_embauche\" ";
            // line 19
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["disabled"]) || array_key_exists("disabled", $context) ? $context["disabled"] : (function () { throw new RuntimeError('Variable "disabled" does not exist.', 19, $this->source); })()), "html", null, true);
            yield " class=\"form-control bg-grey input-date-custom\" value=\"";
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(Twig\Extension\CoreExtension::default($this->extensions['Twig\Extension\CoreExtension']->formatDate(CoreExtension::getAttribute($this->env, $this->source, (isset($context["agent"]) || array_key_exists("agent", $context) ? $context["agent"] : (function () { throw new RuntimeError('Variable "agent" does not exist.', 19, $this->source); })()), "dateEmbauche", [], "any", false, false, false, 19), "Y-m-d"), ""), "html", null, true);
            yield "\" form=\"form_agent_update\">
        </div>
        <div class=\"d-flex align-items-center\" style=\"margin-right:2rem;margin-bottom: 5px;\">
            <label class=\"me-1\" style=\"width:117px\">Date d'affectation</label>
            <input type=\"date\"  style=\"width:128px\"  disabled class=\"form-control bg-grey input-date-custom\" value=\"";
            // line 23
            (((isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 23, $this->source); })())) ? (yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Twig\Extension\CoreExtension']->formatDate(CoreExtension::getAttribute($this->env, $this->source, (isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 23, $this->source); })()), "debutEffet", [], "any", false, false, false, 23), "Y-m-d"), "html", null, true)) : (yield ""));
            yield "\">
        </div>
        ";
        }
        // line 26
        yield "        <div class=\"d-flex align-items-center me-3 \" style=\"margin-bottom: 5px;\">
            <label style=\"width:";
        // line 27
        yield (((0 === CoreExtension::compare((isset($context["programmation"]) || array_key_exists("programmation", $context) ? $context["programmation"] : (function () { throw new RuntimeError('Variable "programmation" does not exist.', 27, $this->source); })()), "oui"))) ? ("110px") : ("116px;"));
        yield "\" class=\"me-1 ";
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(((array_key_exists("classLabel", $context)) ? (Twig\Extension\CoreExtension::default((isset($context["classLabel"]) || array_key_exists("classLabel", $context) ? $context["classLabel"] : (function () { throw new RuntimeError('Variable "classLabel" does not exist.', 27, $this->source); })()), "")) : ("")), "html", null, true);
        yield "\">Type profil</label>
            ";
        // line 28
        if ((0 === CoreExtension::compare((isset($context["type"]) || array_key_exists("type", $context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.', 28, $this->source); })()), "show"))) {
            // line 29
            yield "                <input type=\"text\"  style=\"width:171px\" ";
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["disabled"]) || array_key_exists("disabled", $context) ? $context["disabled"] : (function () { throw new RuntimeError('Variable "disabled" does not exist.', 29, $this->source); })()), "html", null, true);
            yield " class=\"form-control\" value=\"";
            (((isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 29, $this->source); })())) ? (yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 29, $this->source); })()), "utilisateurProfil", [], "any", false, false, false, 29), "libelle", [], "any", false, false, false, 29), "html", null, true)) : (yield ""));
            yield "\">
            ";
        } else {
            // line 31
            yield "                <select name=\"type_profil\" style=\"width:auto\" class=\"form-control bg-grey\" id=\"affectation_type_profil\">
                    ";
            // line 32
            $context['_parent'] = $context;
            $context['_seq'] = CoreExtension::ensureTraversable((isset($context["typesProfil"]) || array_key_exists("typesProfil", $context) ? $context["typesProfil"] : (function () { throw new RuntimeError('Variable "typesProfil" does not exist.', 32, $this->source); })()));
            foreach ($context['_seq'] as $context["_key"] => $context["profil"]) {
                // line 33
                yield "                        ";
                $context["selected"] = ((((isset($context["hasNext"]) || array_key_exists("hasNext", $context) ? $context["hasNext"] : (function () { throw new RuntimeError('Variable "hasNext" does not exist.', 33, $this->source); })()) && (0 === CoreExtension::compare(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["agent"]) || array_key_exists("agent", $context) ? $context["agent"] : (function () { throw new RuntimeError('Variable "agent" does not exist.', 33, $this->source); })()), "nextAffectation", [], "any", false, false, false, 33), "utilisateurProfil", [], "any", false, false, false, 33), "id", [], "any", false, false, false, 33), CoreExtension::getAttribute($this->env, $this->source, $context["profil"], "id", [], "any", false, false, false, 33))))) ? ("selected") : (""));
                // line 34
                yield "                        <option value=\"";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["profil"], "id", [], "any", false, false, false, 34), "html", null, true);
                yield "\" ";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["selected"]) || array_key_exists("selected", $context) ? $context["selected"] : (function () { throw new RuntimeError('Variable "selected" does not exist.', 34, $this->source); })()), "html", null, true);
                yield ">";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["profil"], "libelle", [], "any", false, false, false, 34), "html", null, true);
                yield "</option>
                    ";
            }
            $_parent = $context['_parent'];
            unset($context['_seq'], $context['_iterated'], $context['_key'], $context['profil'], $context['_parent'], $context['loop']);
            $context = array_intersect_key($context, $_parent) + $_parent;
            // line 36
            yield "                </select>
            ";
        }
        // line 38
        yield "        </div>
        ";
        // line 39
        if ((0 === CoreExtension::compare((isset($context["programmation"]) || array_key_exists("programmation", $context) ? $context["programmation"] : (function () { throw new RuntimeError('Variable "programmation" does not exist.', 39, $this->source); })()), "oui"))) {
            // line 40
            yield "            ";
            yield Twig\Extension\CoreExtension::include($this->env, $context, "agent/_affectation_temps_travail.html.twig");
            yield "
        ";
        }
        // line 42
        yield "    </div>
    <div class=\"d-flex flex-column\">
        ";
        // line 44
        if ((0 === CoreExtension::compare((isset($context["programmation"]) || array_key_exists("programmation", $context) ? $context["programmation"] : (function () { throw new RuntimeError('Variable "programmation" does not exist.', 44, $this->source); })()), "non"))) {
            // line 45
            yield "            ";
            yield Twig\Extension\CoreExtension::include($this->env, $context, "agent/_affectation_temps_travail.html.twig");
            yield "
        ";
        }
        // line 47
        yield "        <div class=\"d-flex align-items-center\">
            <label class=\"me-1 ";
        // line 48
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(((array_key_exists("classLabel", $context)) ? (Twig\Extension\CoreExtension::default((isset($context["classLabel"]) || array_key_exists("classLabel", $context) ? $context["classLabel"] : (function () { throw new RuntimeError('Variable "classLabel" does not exist.', 48, $this->source); })()), "")) : ("")), "html", null, true);
        yield "\" style=\"width: 107px\">Groupe</label>
            ";
        // line 49
        if ((0 === CoreExtension::compare((isset($context["type"]) || array_key_exists("type", $context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.', 49, $this->source); })()), "show"))) {
            // line 50
            yield "                <input type=\"text\" ";
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["disabled"]) || array_key_exists("disabled", $context) ? $context["disabled"] : (function () { throw new RuntimeError('Variable "disabled" does not exist.', 50, $this->source); })()), "html", null, true);
            yield " style=\"width: 227px\" class=\"form-control\" value=\"";
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["agent"]) || array_key_exists("agent", $context) ? $context["agent"] : (function () { throw new RuntimeError('Variable "agent" does not exist.', 50, $this->source); })()), "getNomResponsable", [], "any", false, false, false, 50), "html", null, true);
            yield " \">
            ";
        } else {
            // line 52
            yield "                <select name=\"utilisateur_responsable\" style=\"width:227px;\" class=\"form-control bg-grey\" id=\"affectation_responsable\" required>
                    <option value=\"\">Sélectionnez [...]</option>
                    ";
            // line 54
            $context['_parent'] = $context;
            $context['_seq'] = CoreExtension::ensureTraversable((isset($context["utilisateursResponsable"]) || array_key_exists("utilisateursResponsable", $context) ? $context["utilisateursResponsable"] : (function () { throw new RuntimeError('Variable "utilisateursResponsable" does not exist.', 54, $this->source); })()));
            foreach ($context['_seq'] as $context["_key"] => $context["utilisateur"]) {
                // line 55
                yield "                        ";
                $context["selected"] = (((((isset($context["hasNext"]) || array_key_exists("hasNext", $context) ? $context["hasNext"] : (function () { throw new RuntimeError('Variable "hasNext" does not exist.', 55, $this->source); })()) && CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["agent"]) || array_key_exists("agent", $context) ? $context["agent"] : (function () { throw new RuntimeError('Variable "agent" does not exist.', 55, $this->source); })()), "nextAffectation", [], "any", false, false, false, 55), "getUtilisateurReponsable", [], "any", false, false, false, 55)) && (0 === CoreExtension::compare(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["agent"]) || array_key_exists("agent", $context) ? $context["agent"] : (function () { throw new RuntimeError('Variable "agent" does not exist.', 55, $this->source); })()), "nextAffectation", [], "any", false, false, false, 55), "getUtilisateurReponsable", [], "any", false, false, false, 55), "id", [], "any", false, false, false, 55), CoreExtension::getAttribute($this->env, $this->source, $context["utilisateur"], "id", [], "any", false, false, false, 55))))) ? ("selected") : (""));
                // line 56
                yield "                        <option value=\"";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["utilisateur"], "id", [], "any", false, false, false, 56), "html", null, true);
                yield " \" data-idgestionnaire=\"";
                ((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, $context["utilisateur"], "getActiveUtilisateurAffectation", [], "any", false, false, false, 56), "getUtilisateurPlanning", [], "any", false, false, false, 56)) ? (yield $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["utilisateur"], "getActiveUtilisateurAffectation", [], "any", false, false, false, 56), "getUtilisateurPlanning", [], "any", false, false, false, 56), "id", [], "any", false, false, false, 56), "html", null, true)) : (yield ""));
                yield "\" ";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["selected"]) || array_key_exists("selected", $context) ? $context["selected"] : (function () { throw new RuntimeError('Variable "selected" does not exist.', 56, $this->source); })()), "html", null, true);
                yield ">";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["utilisateur"], "NomComplet", [], "any", false, false, false, 56), "html", null, true);
                yield "</option>
                    ";
            }
            $_parent = $context['_parent'];
            unset($context['_seq'], $context['_iterated'], $context['_key'], $context['utilisateur'], $context['_parent'], $context['loop']);
            $context = array_intersect_key($context, $_parent) + $_parent;
            // line 58
            yield "                </select>
            ";
        }
        // line 60
        yield "        </div>
        <div class=\"  d-flex align-items-center\">
            <label class=\"me-1 ";
        // line 62
        yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(((array_key_exists("classLabel", $context)) ? (Twig\Extension\CoreExtension::default((isset($context["classLabel"]) || array_key_exists("classLabel", $context) ? $context["classLabel"] : (function () { throw new RuntimeError('Variable "classLabel" does not exist.', 62, $this->source); })()), "")) : ("")), "html", null, true);
        yield "\" style=\"width: 108px\" >Utilisateur<br> gestion planning</label>
            ";
        // line 63
        if ((0 === CoreExtension::compare((isset($context["type"]) || array_key_exists("type", $context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.', 63, $this->source); })()), "show"))) {
            // line 64
            yield "                <input type=\"text\"  ";
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["disabled"]) || array_key_exists("disabled", $context) ? $context["disabled"] : (function () { throw new RuntimeError('Variable "disabled" does not exist.', 64, $this->source); })()), "html", null, true);
            yield " class=\"form-control\" style=\"width: 227px;\" value=\"";
            (((isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 64, $this->source); })())) ? (yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 64, $this->source); })()), "getUtilisateurPlanningIdNom", [], "any", false, false, false, 64), "html", null, true)) : (yield ""));
            yield "\">
                &nbsp;<i>";
            // line 66
            ((            // line 65
(isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 65, $this->source); })())) ? (((CoreExtension::getAttribute($this->env, $this->source, (isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 65, $this->source); })()), "getUtilisateurPlanning", [], "any", false, false, false, 65)) ? (yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source,             // line 66
(isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 66, $this->source); })()), "getUtilisateurPlanning", [], "any", false, false, false, 66), "getPoleLibelle", [], "any", false, false, false, 66), "html", null, true)) : (yield ""))) : (yield ""));
            yield "</i>
            ";
        } else {
            // line 68
            yield "                <select name=\"utilisateur_planning\" style=\"width:227px;\" class=\"form-control bg-grey\" id=\"affectation_utilisateur_planning\">
                    <option value=\"\">Sélectionnez [...]</option>
                    ";
            // line 70
            $context['_parent'] = $context;
            $context['_seq'] = CoreExtension::ensureTraversable((isset($context["utilisateursPlanning"]) || array_key_exists("utilisateursPlanning", $context) ? $context["utilisateursPlanning"] : (function () { throw new RuntimeError('Variable "utilisateursPlanning" does not exist.', 70, $this->source); })()));
            foreach ($context['_seq'] as $context["_key"] => $context["utilisateur"]) {
                // line 71
                yield "                        ";
                $context["selected"] = (((((isset($context["hasNext"]) || array_key_exists("hasNext", $context) ? $context["hasNext"] : (function () { throw new RuntimeError('Variable "hasNext" does not exist.', 71, $this->source); })()) && CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["agent"]) || array_key_exists("agent", $context) ? $context["agent"] : (function () { throw new RuntimeError('Variable "agent" does not exist.', 71, $this->source); })()), "nextAffectation", [], "any", false, false, false, 71), "getUtilisateurPlanning", [], "any", false, false, false, 71)) && (0 === CoreExtension::compare(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["agent"]) || array_key_exists("agent", $context) ? $context["agent"] : (function () { throw new RuntimeError('Variable "agent" does not exist.', 71, $this->source); })()), "nextAffectation", [], "any", false, false, false, 71), "getUtilisateurPlanning", [], "any", false, false, false, 71), "id", [], "any", false, false, false, 71), CoreExtension::getAttribute($this->env, $this->source, $context["utilisateur"], "id", [], "any", false, false, false, 71))))) ? ("selected") : (""));
                // line 72
                yield "                        <option value=\"";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["utilisateur"], "id", [], "any", false, false, false, 72), "html", null, true);
                yield "\" ";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["selected"]) || array_key_exists("selected", $context) ? $context["selected"] : (function () { throw new RuntimeError('Variable "selected" does not exist.', 72, $this->source); })()), "html", null, true);
                yield ">";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(((CoreExtension::getAttribute($this->env, $this->source, $context["utilisateur"], "id", [], "any", false, false, false, 72) . " - ") . CoreExtension::getAttribute($this->env, $this->source, $context["utilisateur"], "NomComplet", [], "any", false, false, false, 72)), "html", null, true);
                yield "</option>
                    ";
            }
            $_parent = $context['_parent'];
            unset($context['_seq'], $context['_iterated'], $context['_key'], $context['utilisateur'], $context['_parent'], $context['loop']);
            $context = array_intersect_key($context, $_parent) + $_parent;
            // line 74
            yield "                </select>
            ";
        }
        // line 76
        yield "        </div>
        ";
        // line 77
        if (((0 === CoreExtension::compare((isset($context["type"]) || array_key_exists("type", $context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.', 77, $this->source); })()), "edit")) || ((isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 77, $this->source); })()) && CoreExtension::getAttribute($this->env, $this->source, (isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 77, $this->source); })()), "motifTempsPartiel", [], "any", false, false, false, 77)))) {
            // line 78
            yield "            <div class=\" d-flex align-items-center  ";
            yield (((0 === CoreExtension::compare((isset($context["type"]) || array_key_exists("type", $context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.', 78, $this->source); })()), "edit"))) ? ("hide") : (""));
            yield "\" id=\"affectation_div_motif\" style=\"align-self: end\">
                <label class=\"me-3 ";
            // line 79
            yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(((array_key_exists("classLabel", $context)) ? (Twig\Extension\CoreExtension::default((isset($context["classLabel"]) || array_key_exists("classLabel", $context) ? $context["classLabel"] : (function () { throw new RuntimeError('Variable "classLabel" does not exist.', 79, $this->source); })()), "")) : ("")), "html", null, true);
            yield "\">Motif</label>
                ";
            // line 80
            if ((0 === CoreExtension::compare((isset($context["type"]) || array_key_exists("type", $context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.', 80, $this->source); })()), "show"))) {
                // line 81
                yield "                    <input type=\"text\"  ";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["disabled"]) || array_key_exists("disabled", $context) ? $context["disabled"] : (function () { throw new RuntimeError('Variable "disabled" does not exist.', 81, $this->source); })()), "html", null, true);
                yield " class=\"form-control\" style=\"width:auto;\" value=\"";
                yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["affectation"]) || array_key_exists("affectation", $context) ? $context["affectation"] : (function () { throw new RuntimeError('Variable "affectation" does not exist.', 81, $this->source); })()), "motifTempsPartiel", [], "any", false, false, false, 81), "libelle", [], "any", false, false, false, 81), "html", null, true);
                yield "\">
                ";
            } else {
                // line 83
                yield "                    <select name=\"motif\" style=\"width:227px;\" class=\"form-control bg-grey\" id=\"affectation_motif\">
                        ";
                // line 84
                $context['_parent'] = $context;
                $context['_seq'] = CoreExtension::ensureTraversable((isset($context["motifs"]) || array_key_exists("motifs", $context) ? $context["motifs"] : (function () { throw new RuntimeError('Variable "motifs" does not exist.', 84, $this->source); })()));
                foreach ($context['_seq'] as $context["_key"] => $context["motif"]) {
                    // line 85
                    yield "                            ";
                    $context["selected"] = ((((isset($context["hasNext"]) || array_key_exists("hasNext", $context) ? $context["hasNext"] : (function () { throw new RuntimeError('Variable "hasNext" does not exist.', 85, $this->source); })()) && (0 === CoreExtension::compare(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["agent"]) || array_key_exists("agent", $context) ? $context["agent"] : (function () { throw new RuntimeError('Variable "agent" does not exist.', 85, $this->source); })()), "nextAffectation", [], "any", false, false, false, 85), "motifTempsPartiel", [], "any", false, false, false, 85), "id", [], "any", false, false, false, 85), CoreExtension::getAttribute($this->env, $this->source, $context["motif"], "id", [], "any", false, false, false, 85))))) ? ("selected") : (""));
                    // line 86
                    yield "                            <option value=\"";
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["motif"], "id", [], "any", false, false, false, 86), "html", null, true);
                    yield "\" ";
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["selected"]) || array_key_exists("selected", $context) ? $context["selected"] : (function () { throw new RuntimeError('Variable "selected" does not exist.', 86, $this->source); })()), "html", null, true);
                    yield ">";
                    yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["motif"], "libelle", [], "any", false, false, false, 86), "html", null, true);
                    yield "</option>
                        ";
                }
                $_parent = $context['_parent'];
                unset($context['_seq'], $context['_iterated'], $context['_key'], $context['motif'], $context['_parent'], $context['loop']);
                $context = array_intersect_key($context, $_parent) + $_parent;
                // line 88
                yield "                    </select>
                ";
            }
            // line 90
            yield "            </div>
        ";
        }
        // line 92
        yield "    </div>
</div>";
        
        $__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);

        
        $__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);

        return; yield '';
    }

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

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

    /**
     * @codeCoverageIgnore
     */
    public function getDebugInfo()
    {
        return array (  323 => 92,  319 => 90,  315 => 88,  302 => 86,  299 => 85,  295 => 84,  292 => 83,  284 => 81,  282 => 80,  278 => 79,  273 => 78,  271 => 77,  268 => 76,  264 => 74,  251 => 72,  248 => 71,  244 => 70,  240 => 68,  235 => 66,  234 => 65,  233 => 66,  226 => 64,  224 => 63,  220 => 62,  216 => 60,  212 => 58,  197 => 56,  194 => 55,  190 => 54,  186 => 52,  178 => 50,  176 => 49,  172 => 48,  169 => 47,  163 => 45,  161 => 44,  157 => 42,  151 => 40,  149 => 39,  146 => 38,  142 => 36,  129 => 34,  126 => 33,  122 => 32,  119 => 31,  111 => 29,  109 => 28,  103 => 27,  100 => 26,  94 => 23,  85 => 19,  81 => 17,  75 => 14,  72 => 13,  70 => 12,  65 => 11,  62 => 10,  60 => 9,  56 => 7,  49 => 3,  46 => 2,  44 => 1,);
    }

    public function getSourceContext()
    {
        return new Source("{% if type == 'show' and programmation == 'non' %}
    <div class=\"form-check\">
        <input class=\"form-check-input\" disabled style=\"margin-top:0.6rem;\" type=\"checkbox\" {{ affectation and affectation.planifiable ? 'checked' : '' }}>
        <label class=\"form-check-label me-1 \"  style=\"padding-top: 0.4rem;\"> Planifiable</label>
    </div>
{% endif %}
<div class=\"d-flex\">
    <div class=\"d-flex flex-column\">
        {% if programmation == 'oui' %}
        <div class=\"form-check align-self-center\" style=\"margin-left: 0.9rem;margin-bottom: 5px;\">
            <input class=\"form-check-input\" type=\"checkbox\" value=\"OUI\" id=\"planifiable-{{ type }}\" {{ type == 'show' ? 'disabled' : 'name=\"planifiable\"' }} style=\"margin-top:0.6rem;\" {{ (type == 'show' and affectation and affectation.planifiable) or
                                                                                    (type != 'show' and hasNext and agent.nextAffectation.planifiable)
                                                                                    ? 'checked' : '' }}>
            <label class=\"form-check-label me-1 \" for=\"planifiable-{{ type }}\"  style=\"padding-top: 0.4rem;\"> Planifiable</label>
        </div>
        {% else %}
        <div class=\"d-flex align-items-center\" style=\"margin-right:2rem;margin-bottom: 5px;\">
            <label class=\"me-1\" style=\"width:117px\">Date d'embauche</label>
            <input type=\"date\"  style=\"width:128px\"  data-disable-on-view=\"\" name=\"date_embauche\" {{ disabled }} class=\"form-control bg-grey input-date-custom\" value=\"{{agent.dateEmbauche|date(\"Y-m-d\")|default('') }}\" form=\"form_agent_update\">
        </div>
        <div class=\"d-flex align-items-center\" style=\"margin-right:2rem;margin-bottom: 5px;\">
            <label class=\"me-1\" style=\"width:117px\">Date d'affectation</label>
            <input type=\"date\"  style=\"width:128px\"  disabled class=\"form-control bg-grey input-date-custom\" value=\"{{affectation ? affectation.debutEffet|date(\"Y-m-d\") : '' }}\">
        </div>
        {% endif %}
        <div class=\"d-flex align-items-center me-3 \" style=\"margin-bottom: 5px;\">
            <label style=\"width:{{ programmation == 'oui' ? '110px' :'116px;' }}\" class=\"me-1 {{ classLabel|default('') }}\">Type profil</label>
            {% if type == 'show' %}
                <input type=\"text\"  style=\"width:171px\" {{ disabled }} class=\"form-control\" value=\"{{ affectation ? affectation.utilisateurProfil.libelle : '' }}\">
            {% else %}
                <select name=\"type_profil\" style=\"width:auto\" class=\"form-control bg-grey\" id=\"affectation_type_profil\">
                    {% for profil in typesProfil %}
                        {% set selected =  (hasNext and agent.nextAffectation.utilisateurProfil.id == profil.id) ? 'selected' : '' %}
                        <option value=\"{{ profil.id }}\" {{ selected }}>{{ profil.libelle }}</option>
                    {% endfor %}
                </select>
            {% endif %}
        </div>
        {% if programmation == 'oui' %}
            {{ include('agent/_affectation_temps_travail.html.twig') }}
        {% endif %}
    </div>
    <div class=\"d-flex flex-column\">
        {% if programmation == 'non' %}
            {{ include('agent/_affectation_temps_travail.html.twig') }}
        {% endif %}
        <div class=\"d-flex align-items-center\">
            <label class=\"me-1 {{ classLabel|default('') }}\" style=\"width: 107px\">Groupe</label>
            {% if type == 'show' %}
                <input type=\"text\" {{ disabled }} style=\"width: 227px\" class=\"form-control\" value=\"{{ agent.getNomResponsable }} \">
            {% else %}
                <select name=\"utilisateur_responsable\" style=\"width:227px;\" class=\"form-control bg-grey\" id=\"affectation_responsable\" required>
                    <option value=\"\">Sélectionnez [...]</option>
                    {% for utilisateur in utilisateursResponsable %}
                        {% set selected =  (hasNext and agent.nextAffectation.getUtilisateurReponsable and agent.nextAffectation.getUtilisateurReponsable.id == utilisateur.id) ? 'selected' : '' %}
                        <option value=\"{{ utilisateur.id }} \" data-idgestionnaire=\"{{ utilisateur.getActiveUtilisateurAffectation.getUtilisateurPlanning ? utilisateur.getActiveUtilisateurAffectation.getUtilisateurPlanning.id : ''  }}\" {{ selected }}>{{ utilisateur.NomComplet}}</option>
                    {% endfor %}
                </select>
            {% endif %}
        </div>
        <div class=\"  d-flex align-items-center\">
            <label class=\"me-1 {{ classLabel|default('') }}\" style=\"width: 108px\" >Utilisateur<br> gestion planning</label>
            {% if type == 'show' %}
                <input type=\"text\"  {{ disabled }} class=\"form-control\" style=\"width: 227px;\" value=\"{{ affectation ? affectation.getUtilisateurPlanningIdNom : '' }}\">
                &nbsp;<i>{{ affectation ? (affectation.getUtilisateurPlanning
                ?  affectation.getUtilisateurPlanning.getPoleLibelle : '') : ''}}</i>
            {% else %}
                <select name=\"utilisateur_planning\" style=\"width:227px;\" class=\"form-control bg-grey\" id=\"affectation_utilisateur_planning\">
                    <option value=\"\">Sélectionnez [...]</option>
                    {% for utilisateur in utilisateursPlanning %}
                        {% set selected =  (hasNext and agent.nextAffectation.getUtilisateurPlanning and  agent.nextAffectation.getUtilisateurPlanning.id == utilisateur.id) ? 'selected' : '' %}
                        <option value=\"{{ utilisateur.id }}\" {{ selected }}>{{ utilisateur.id ~ ' - ' ~ utilisateur.NomComplet}}</option>
                    {% endfor %}
                </select>
            {% endif %}
        </div>
        {% if type==\"edit\" or (affectation and affectation.motifTempsPartiel) %}
            <div class=\" d-flex align-items-center  {{ type==\"edit\" ? 'hide' : '' }}\" id=\"affectation_div_motif\" style=\"align-self: end\">
                <label class=\"me-3 {{ classLabel|default('') }}\">Motif</label>
                {% if type == 'show' %}
                    <input type=\"text\"  {{ disabled }} class=\"form-control\" style=\"width:auto;\" value=\"{{ affectation.motifTempsPartiel.libelle }}\">
                {% else %}
                    <select name=\"motif\" style=\"width:227px;\" class=\"form-control bg-grey\" id=\"affectation_motif\">
                        {% for motif in motifs %}
                            {% set selected =  (hasNext and agent.nextAffectation.motifTempsPartiel.id == motif.id) ? 'selected' : '' %}
                            <option value=\"{{ motif.id }}\" {{ selected }}>{{ motif.libelle }}</option>
                        {% endfor %}
                    </select>
                {% endif %}
            </div>
        {% endif %}
    </div>
</div>", "agent/_affectation.html.twig", "/builds/dev/refonte_sav/templates/agent/_affectation.html.twig");
    }
}
