<?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\Sandbox\SecurityNotAllowedTestError;
use Twig\Source;
use Twig\Template;
use Twig\TemplateWrapper;
/* department/show.html.twig */
class __TwigTemplate_c5512740bbbe67696795919b86f94a79 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 = [
'title' => [$this, 'block_title'],
'body' => [$this, 'block_body'],
];
}
protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
{
// line 1
return "base.html.twig";
}
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", "department/show.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "department/show.html.twig"));
$this->parent = $this->load("base.html.twig", 1);
yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 3
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_title(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(), "block", "title"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "title"));
yield "Department";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
yield from [];
}
// line 5
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_body(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(), "block", "body"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "body"));
// line 6
yield " <h1>Department</h1>
<table class=\"table\">
<tbody>
<tr>
<th>";
// line 11
yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Id", [], "messages");
yield " </th>
<td>";
// line 12
yield (string) $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["department"]) || array_key_exists("department", $context) ? $context["department"] : (function () { throw new RuntimeError('Variable "department" does not exist.', 12, $this->source); })()), "id", [], "any", false, false, false, 12), "html", null, true);
yield "</td>
</tr>
<tr>
<th>";
// line 15
yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Name", [], "messages");
yield " </th>
<td>";
// line 16
yield (string) $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["department"]) || array_key_exists("department", $context) ? $context["department"] : (function () { throw new RuntimeError('Variable "department" does not exist.', 16, $this->source); })()), "name", [], "any", false, false, false, 16), "html", null, true);
yield "</td>
</tr>
<tr>
<th>";
// line 19
yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Description", [], "messages");
yield " </th>
<td>";
// line 20
yield (string) $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["department"]) || array_key_exists("department", $context) ? $context["department"] : (function () { throw new RuntimeError('Variable "department" does not exist.', 20, $this->source); })()), "description", [], "any", false, false, false, 20), "html", null, true);
yield "</td>
</tr>
<tr>
<th>";
// line 23
yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Region", [], "messages");
yield " </th>
<td>";
// line 24
yield (string) $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["department"]) || array_key_exists("department", $context) ? $context["department"] : (function () { throw new RuntimeError('Variable "department" does not exist.', 24, $this->source); })()), "region", [], "any", false, false, false, 24), "html", null, true);
yield "</td>
</tr>
<tr>
<th>";
// line 27
yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("UpdateAt", [], "messages");
yield "</th>
<td>";
// line 28
yield (string) (((($tmp = CoreExtension::getAttribute($this->env, $this->source, (isset($context["department"]) || array_key_exists("department", $context) ? $context["department"] : (function () { throw new RuntimeError('Variable "department" does not exist.', 28, $this->source); })()), "updateAt", [], "any", false, false, false, 28)) && $tmp instanceof Markup ? (string) $tmp : $tmp)) ? ($this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Twig\Extension\CoreExtension']->formatDate(CoreExtension::getAttribute($this->env, $this->source, (isset($context["department"]) || array_key_exists("department", $context) ? $context["department"] : (function () { throw new RuntimeError('Variable "department" does not exist.', 28, $this->source); })()), "updateAt", [], "any", false, false, false, 28), "Y-m-d H:i:s"), "html", null, true)) : (""));
yield "</td>
</tr>
</tbody>
</table>
<a href=\"";
// line 33
yield (string) $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("department_index");
yield "\">back to list</a>
";
// line 34
if ((($tmp = $this->extensions['Symfony\Bridge\Twig\Extension\SecurityExtension']->isGranted("ROLE_HABITECH")) && $tmp instanceof Markup ? (string) $tmp : $tmp)) {
// line 35
yield "
<a href=\"";
// line 36
yield (string) $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("department_edit", ["id" => CoreExtension::getAttribute($this->env, $this->source, (isset($context["department"]) || array_key_exists("department", $context) ? $context["department"] : (function () { throw new RuntimeError('Variable "department" does not exist.', 36, $this->source); })()), "id", [], "any", false, false, false, 36)]), "html", null, true);
yield "\">";
yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("edit", [], "messages");
yield "</a>
";
// line 37
yield (string) Twig\Extension\CoreExtension::include($this->env, $context, "department/_delete_form.html.twig");
yield "
";
}
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
yield from [];
}
/**
* @codeCoverageIgnore
*/
public function getTemplateName(): string
{
return "department/show.html.twig";
}
/**
* @codeCoverageIgnore
*/
public function isTraitable(): bool
{
return false;
}
/**
* @codeCoverageIgnore
*/
public function getDebugInfo(): array
{
return array ( 175 => 37, 169 => 36, 166 => 35, 164 => 34, 160 => 33, 152 => 28, 148 => 27, 142 => 24, 138 => 23, 132 => 20, 128 => 19, 122 => 16, 118 => 15, 112 => 12, 108 => 11, 101 => 6, 88 => 5, 65 => 3, 42 => 1,);
}
public function getSourceContext(): Source
{
return new Source("{% extends \x27base.html.twig\x27 %}
{% block title %}Department{% endblock %}
{% block body %}
<h1>Department</h1>
<table class=\"table\">
<tbody>
<tr>
<th>{% trans %}Id{% endtrans %} </th>
<td>{{ department.id }}</td>
</tr>
<tr>
<th>{% trans %}Name{% endtrans %} </th>
<td>{{ department.name }}</td>
</tr>
<tr>
<th>{% trans %}Description{% endtrans %} </th>
<td>{{ department.description }}</td>
</tr>
<tr>
<th>{% trans %}Region{% endtrans %} </th>
<td>{{ department.region }}</td>
</tr>
<tr>
<th>{% trans %}UpdateAt{% endtrans %}</th>
<td>{{ department.updateAt ? department.updateAt|date(\x27Y-m-d H:i:s\x27) : \x27\x27 }}</td>
</tr>
</tbody>
</table>
<a href=\"{{ path(\x27department_index\x27) }}\">back to list</a>
{% if is_granted(\x27ROLE_HABITECH\x27) %}
<a href=\"{{ path(\x27department_edit\x27, {\x27id\x27: department.id}) }}\">{% trans %}edit{% endtrans %}</a>
{{ include(\x27department/_delete_form.html.twig\x27) }}
{% endif %}
{% endblock %}
", "department/show.html.twig", "/var/www/vhosts/habitechsolutions.cm/birth.habitechsolutions.cm/templates/department/show.html.twig");
}
}