<?php
use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
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;
/* comun/fichaje/index.html.twig */
class __TwigTemplate_9f8660e8babcbaa7cb30f5a46f9a236aab0cf8d8607c3b180605cccb7843da35 extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'title' => [$this, 'block_title'],
'titulo' => [$this, 'block_titulo'],
'tabla' => [$this, 'block_tabla'],
];
}
protected function doGetParent(array $context)
{
// line 1
return "comun/fichaje/base.html.twig";
}
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", "comun/fichaje/index.html.twig"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "comun/fichaje/index.html.twig"));
$this->parent = $this->loadTemplate("comun/fichaje/base.html.twig", "comun/fichaje/index.html.twig", 1);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
}
// line 3
public function block_title($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(), "block", "title"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "title"));
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("fichaje.titulo"), "html", null, true);
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
// line 6
public function block_titulo($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(), "block", "titulo"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "titulo"));
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("fichaje.titulo"), "html", null, true);
echo " - ";
echo twig_escape_filter($this->env, (isset($context["empleada"]) || array_key_exists("empleada", $context) ? $context["empleada"] : (function () { throw new RuntimeError('Variable "empleada" does not exist.', 6, $this->source); })()), "html", null, true);
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
// line 8
public function block_tabla($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(), "block", "tabla"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "tabla"));
// line 9
echo "
<a class=\"btn btn-primary\" href=\"";
// line 10
if ((isset($context["admin"]) || array_key_exists("admin", $context) ? $context["admin"] : (function () { throw new RuntimeError('Variable "admin" does not exist.', 10, $this->source); })())) {
echo " ";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_comun_fichaje_new_admin", ["empleada" => twig_get_attribute($this->env, $this->source, (isset($context["empleada"]) || array_key_exists("empleada", $context) ? $context["empleada"] : (function () { throw new RuntimeError('Variable "empleada" does not exist.', 10, $this->source); })()), "id", [], "any", false, false, false, 10)]), "html", null, true);
echo "
";
} else {
// line 11
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_comun_fichaje_new");
}
echo "\">";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("fichaje.nuevo"), "html", null, true);
echo "</a>
";
// line 13
if (twig_in_filter("ROLE_ADMIN", twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 13, $this->source); })()), "user", [], "any", false, false, false, 13), "roles", [], "any", false, false, false, 13))) {
// line 14
echo " <a class=\"btn btn-primary float-right\" href=\"";
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_comun_fichaje_todos");
echo "\">";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("fichaje.verTodos"), "html", null, true);
echo "</a>";
}
echo " <br><br>
<table class=\"table table-bordered datatables-basic\">
<thead>
<tr>
<th>";
// line 19
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("fichaje.proyecto"), "html", null, true);
echo "</th>
<th>";
// line 20
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("fichaje.tarea"), "html", null, true);
echo "</th>
<th>";
// line 21
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("fichaje.cantidadHoras"), "html", null, true);
echo "</th>
<th>";
// line 22
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("fichaje.fecha"), "html", null, true);
echo "</th>
<th>";
// line 23
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("fichaje.observaciones"), "html", null, true);
echo "</th>
<th></th>
</tr>
</thead>
<tbody>
";
// line 28
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["fichajes"]) || array_key_exists("fichajes", $context) ? $context["fichajes"] : (function () { throw new RuntimeError('Variable "fichajes" does not exist.', 28, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["fichaje"]) {
// line 29
echo " <tr><td>";
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["fichaje"], "proyecto", [], "any", false, false, false, 29), "html", null, true);
echo "</td>
<td>";
// line 30
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["fichaje"], "tarea", [], "any", false, false, false, 30), "html", null, true);
echo "</td>
<td>";
// line 31
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["fichaje"], "cantidadHorasFormat", [], "any", false, false, false, 31), "html", null, true);
echo "</td>
<td class=\"text-center\">";
// line 32
((twig_get_attribute($this->env, $this->source, $context["fichaje"], "fecha", [], "any", false, false, false, 32)) ? (print (twig_escape_filter($this->env, twig_date_format_filter($this->env, twig_get_attribute($this->env, $this->source, $context["fichaje"], "fecha", [], "any", false, false, false, 32), $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("comun.fechaFormato")), "html", null, true))) : (print ("")));
echo "</td>
<td>";
// line 33
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["fichaje"], "observaciones", [], "any", false, false, false, 33), "html", null, true);
echo "</td>
<td>
<a href=\"";
// line 35
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_comun_fichaje_edit", ["id" => twig_get_attribute($this->env, $this->source, $context["fichaje"], "id", [], "any", false, false, false, 35)]), "html", null, true);
echo "\" class=\"far fa-fw fa-edit text-dark\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("comun.editar"), "html", null, true);
echo "\"></a>
<a href=\"";
// line 36
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_comun_fichaje_delete", ["id" => twig_get_attribute($this->env, $this->source, $context["fichaje"], "id", [], "any", false, false, false, 36)]), "html", null, true);
echo "\" class=\"far fa-fw fa-trash-alt text-dark\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("comun.eliminar"), "html", null, true);
echo "\"></a>
</td>
</tr>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['fichaje'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 40
echo " </tbody>
</table>
<h5>";
// line 43
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("fichaje.tiempoTrabajado"), "html", null, true);
echo ": ";
echo twig_escape_filter($this->env, (isset($context["tiempoTrabajado"]) || array_key_exists("tiempoTrabajado", $context) ? $context["tiempoTrabajado"] : (function () { throw new RuntimeError('Variable "tiempoTrabajado" does not exist.', 43, $this->source); })()), "html", null, true);
echo "</h5>
<br><br>
<a class=\"btn btn-primary\" href=\"";
// line 45
if ((isset($context["admin"]) || array_key_exists("admin", $context) ? $context["admin"] : (function () { throw new RuntimeError('Variable "admin" does not exist.', 45, $this->source); })())) {
echo " ";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_comun_fichaje_new_admin", ["empleada" => twig_get_attribute($this->env, $this->source, (isset($context["empleada"]) || array_key_exists("empleada", $context) ? $context["empleada"] : (function () { throw new RuntimeError('Variable "empleada" does not exist.', 45, $this->source); })()), "id", [], "any", false, false, false, 45)]), "html", null, true);
echo "
";
} else {
// line 46
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_comun_fichaje_new");
}
echo "\">";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("fichaje.nuevo"), "html", null, true);
echo "</a>
";
// line 48
if (twig_in_filter("ROLE_ADMIN", twig_get_attribute($this->env, $this->source, twig_get_attribute($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), "roles", [], "any", false, false, false, 48))) {
// line 49
echo " <a class=\"btn btn-primary float-right\" href=\"";
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("app_comun_fichaje_todos");
echo "\">";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("fichaje.verTodos"), "html", null, true);
echo "</a>";
}
// line 50
echo "
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
}
public function getTemplateName()
{
return "comun/fichaje/index.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 247 => 50, 240 => 49, 238 => 48, 230 => 46, 223 => 45, 216 => 43, 211 => 40, 199 => 36, 193 => 35, 188 => 33, 184 => 32, 180 => 31, 176 => 30, 171 => 29, 167 => 28, 159 => 23, 155 => 22, 151 => 21, 147 => 20, 143 => 19, 130 => 14, 128 => 13, 120 => 11, 113 => 10, 110 => 9, 100 => 8, 79 => 6, 60 => 3, 37 => 1,);
}
public function getSourceContext()
{
return new Source("{% extends 'comun/fichaje/base.html.twig' %}
{% block title %}{{ 'fichaje.titulo'|trans }}{% endblock %}
{%block titulo%}{{'fichaje.titulo'|trans}} - {{ empleada }}{% endblock %}
{% block tabla %}
<a class=\"btn btn-primary\" href=\"{% if admin %} {{ path('app_comun_fichaje_new_admin', {'empleada': empleada.id}) }}
{% else %}{{ path('app_comun_fichaje_new') }}{% endif %}\">{{ 'fichaje.nuevo'|trans }}</a>
{% if \"ROLE_ADMIN\" in app.user.roles %}
<a class=\"btn btn-primary float-right\" href=\"{{ path('app_comun_fichaje_todos') }}\">{{ 'fichaje.verTodos'|trans }}</a>{% endif %} <br><br>
<table class=\"table table-bordered datatables-basic\">
<thead>
<tr>
<th>{{ 'fichaje.proyecto'|trans }}</th>
<th>{{ 'fichaje.tarea'|trans }}</th>
<th>{{ 'fichaje.cantidadHoras'|trans }}</th>
<th>{{ 'fichaje.fecha'|trans }}</th>
<th>{{ 'fichaje.observaciones'|trans }}</th>
<th></th>
</tr>
</thead>
<tbody>
{% for fichaje in fichajes %}
<tr><td>{{ fichaje.proyecto }}</td>
<td>{{ fichaje.tarea }}</td>
<td>{{ fichaje.cantidadHorasFormat }}</td>
<td class=\"text-center\">{{ fichaje.fecha ? fichaje.fecha|date('comun.fechaFormato'|trans) : '' }}</td>
<td>{{ fichaje.observaciones }}</td>
<td>
<a href=\"{{ path('app_comun_fichaje_edit', {'id': fichaje.id}) }}\" class=\"far fa-fw fa-edit text-dark\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"{{ 'comun.editar'|trans }}\"></a>
<a href=\"{{ path('app_comun_fichaje_delete', {'id': fichaje.id}) }}\" class=\"far fa-fw fa-trash-alt text-dark\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"{{ 'comun.eliminar'|trans }}\"></a>
</td>
</tr>
{% endfor %}
</tbody>
</table>
<h5>{{ 'fichaje.tiempoTrabajado'|trans }}: {{ tiempoTrabajado }}</h5>
<br><br>
<a class=\"btn btn-primary\" href=\"{% if admin %} {{ path('app_comun_fichaje_new_admin', {'empleada': empleada.id}) }}
{% else %}{{ path('app_comun_fichaje_new') }}{% endif %}\">{{ 'fichaje.nuevo'|trans }}</a>
{% if \"ROLE_ADMIN\" in app.user.roles %}
<a class=\"btn btn-primary float-right\" href=\"{{ path('app_comun_fichaje_todos') }}\">{{ 'fichaje.verTodos'|trans }}</a>{% endif %}
{% endblock %}
", "comun/fichaje/index.html.twig", "/var/www/vhosts/aplicaciones.debamatika.com/daiteke.aplicaciones.debamatika.com/templates/comun/fichaje/index.html.twig");
}
}