*/ private array $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 = []): iterable { $macros = $this->macros; $__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"]; $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "partials/user/user-employment-details.html.twig")); $__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"]; $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "partials/user/user-employment-details.html.twig")); // line 1 yield "

Employment Details

"; // line 12 if ((array_key_exists("mode", $context) && ((isset($context["mode"]) || array_key_exists("mode", $context) ? $context["mode"] : (function () { throw new RuntimeError('Variable "mode" does not exist.', 12, $this->source); })()) == "view"))) { // line 13 yield "
"; // line 14 if ((($tmp = !(null === CoreExtension::getAttribute($this->env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 14, $this->source); })()), "start_date", [], "any", false, false, false, 14))) && $tmp instanceof Markup ? (string) $tmp : $tmp)) { // line 15 yield " "; yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Twig\Extension\CoreExtension']->formatDate(CoreExtension::getAttribute($this->env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 15, $this->source); })()), "start_date", [], "any", false, false, false, 15), "d/m/Y"), "html", null, true); yield " "; } else { // line 17 yield " Not provided "; } // line 19 yield "
"; } elseif (CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, // line 20 ($context["user"] ?? null), "roles", [], "any", false, true, false, 20), "ROLE_SUPERADMIN", [], "any", true, true, false, 20)) { // line 21 yield " env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 21, $this->source); })()), "start_date", [], "any", false, false, false, 21))) && $tmp instanceof Markup ? (string) $tmp : $tmp)) { yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Twig\Extension\CoreExtension']->formatDate(CoreExtension::getAttribute($this->env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 21, $this->source); })()), "start_date", [], "any", false, false, false, 21), "Y-m-d"), "html", null, true); } yield "\" data-provider=\"flatpickr\" data-date-format=\"Y-m-d\"> "; } else { // line 23 yield " env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Twig\Extension\CoreExtension']->formatDate(CoreExtension::getAttribute($this->env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 23, $this->source); })()), "start_date", [], "any", false, false, false, 23), "d/m/Y"), "html", null, true); yield "\" disabled> "; } // line 25 yield "
"; // line 32 if ((array_key_exists("mode", $context) && ((isset($context["mode"]) || array_key_exists("mode", $context) ? $context["mode"] : (function () { throw new RuntimeError('Variable "mode" does not exist.', 32, $this->source); })()) == "view"))) { // line 33 yield "
"; // line 34 if ((($tmp = !(null === CoreExtension::getAttribute($this->env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 34, $this->source); })()), "leave_date", [], "any", false, false, false, 34))) && $tmp instanceof Markup ? (string) $tmp : $tmp)) { // line 35 yield " "; yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Twig\Extension\CoreExtension']->formatDate(CoreExtension::getAttribute($this->env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 35, $this->source); })()), "leave_date", [], "any", false, false, false, 35), "d/m/Y"), "html", null, true); yield " "; } else { // line 37 yield " Not provided "; } // line 39 yield "
"; } elseif (CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, // line 40 ($context["user"] ?? null), "roles", [], "any", false, true, false, 40), "ROLE_SUPERADMIN", [], "any", true, true, false, 40)) { // line 41 yield " env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 41, $this->source); })()), "leave_date", [], "any", false, false, false, 41))) && $tmp instanceof Markup ? (string) $tmp : $tmp)) { yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Twig\Extension\CoreExtension']->formatDate(CoreExtension::getAttribute($this->env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 41, $this->source); })()), "leave_date", [], "any", false, false, false, 41), "Y-m-d"), "html", null, true); } yield "\" data-provider=\"flatpickr\" data-date-format=\"Y-m-d\"> "; } else { // line 43 yield " env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Twig\Extension\CoreExtension']->formatDate(CoreExtension::getAttribute($this->env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 43, $this->source); })()), "leave_date", [], "any", false, false, false, 43), "d/m/Y"), "html", null, true); yield "\" disabled> "; } // line 45 yield "
"; // line 57 if ((array_key_exists("mode", $context) && ((isset($context["mode"]) || array_key_exists("mode", $context) ? $context["mode"] : (function () { throw new RuntimeError('Variable "mode" does not exist.', 57, $this->source); })()) == "view"))) { // line 58 yield "
"; // line 59 if ((CoreExtension::getAttribute($this->env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 59, $this->source); })()), "holiday_allowance", [], "any", false, false, false, 59) != 0)) { // line 60 yield " "; yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 60, $this->source); })()), "holiday_allowance", [], "any", false, false, false, 60), "html", null, true); yield " "; } else { // line 62 yield " Not provided "; } // line 64 yield "
"; } elseif (CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, // line 65 ($context["user"] ?? null), "roles", [], "any", false, true, false, 65), "ROLE_SUPERADMIN", [], "any", true, true, false, 65)) { // line 66 yield " env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 66, $this->source); })()), "holiday_allowance", [], "any", false, false, false, 66), "html", null, true); yield "\"> "; } else { // line 68 yield " env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["data"]) || array_key_exists("data", $context) ? $context["data"] : (function () { throw new RuntimeError('Variable "data" does not exist.', 68, $this->source); })()), "holiday_allowance", [], "any", false, false, false, 68), "html", null, true); yield "\" disabled> "; } // line 70 yield "
"; // line 77 if (((array_key_exists("mode", $context) && ((isset($context["mode"]) || array_key_exists("mode", $context) ? $context["mode"] : (function () { throw new RuntimeError('Variable "mode" does not exist.', 77, $this->source); })()) == "view")) || !CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, ($context["user"] ?? null), "roles", [], "any", false, true, false, 77), "ROLE_SUPERADMIN", [], "any", true, true, false, 77))) { // line 78 yield " "; } // line 82 yield "
"; $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof); $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof); yield from []; } /** * @codeCoverageIgnore */ public function getTemplateName(): string { return "partials/user/user-employment-details.html.twig"; } /** * @codeCoverageIgnore */ public function isTraitable(): bool { return false; } /** * @codeCoverageIgnore */ public function getDebugInfo(): array { return array ( 329 => 133, 325 => 131, 323 => 130, 320 => 129, 318 => 128, 302 => 117, 294 => 114, 286 => 111, 278 => 108, 270 => 105, 262 => 102, 254 => 99, 246 => 96, 238 => 93, 230 => 90, 222 => 87, 214 => 84, 210 => 82, 206 => 80, 204 => 79, 201 => 78, 199 => 77, 190 => 70, 184 => 68, 178 => 66, 176 => 65, 173 => 64, 169 => 62, 163 => 60, 161 => 59, 158 => 58, 156 => 57, 142 => 45, 136 => 43, 128 => 41, 126 => 40, 123 => 39, 119 => 37, 113 => 35, 111 => 34, 108 => 33, 106 => 32, 97 => 25, 91 => 23, 83 => 21, 81 => 20, 78 => 19, 74 => 17, 68 => 15, 66 => 14, 63 => 13, 61 => 12, 48 => 1,); } public function getSourceContext(): Source { return new Source("

Employment Details

{% if mode is defined and mode == 'view' %}
{% if data.start_date is not null %} {{ data.start_date|date(\"d/m/Y\") }} {% else %} Not provided {% endif %}
{% elseif user.roles.ROLE_SUPERADMIN is defined %} {% else %} {% endif %}
{% if mode is defined and mode == 'view' %}
{% if data.leave_date is not null %} {{ data.leave_date|date(\"d/m/Y\") }} {% else %} Not provided {% endif %}
{% elseif user.roles.ROLE_SUPERADMIN is defined %} {% else %} {% endif %}
{% if mode is defined and mode == 'view' %}
{% if data.holiday_allowance != 0 %} {{ data.holiday_allowance }} {% else %} Not provided {% endif %}
{% elseif user.roles.ROLE_SUPERADMIN is defined %} {% else %} {% endif %}
{% if mode is defined and mode == 'view' or user.roles.ROLE_SUPERADMIN is not defined %} {% endif %}
", "partials/user/user-employment-details.html.twig", "/var/www/cds-intranet/app/templates/partials/user/user-employment-details.html.twig"); } }