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

/* empresas/index.html.twig */
class __TwigTemplate_0d63321aebea7b695a6ee87409649ed0 extends \Twig\Template
{
    private $source;
    private $macros = [];

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

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

        $this->blocks = [
            'body' => [$this, 'block_body'],
            'javascripts' => [$this, 'block_javascripts'],
        ];
    }

    protected function doGetParent(array $context)
    {
        // line 1
        return "inc/base.html.twig";
    }

    protected function doDisplay(array $context, array $blocks = [])
    {
        $macros = $this->macros;
        $this->parent = $this->loadTemplate("inc/base.html.twig", "empresas/index.html.twig", 1);
        $this->parent->display($context, array_merge($this->blocks, $blocks));
    }

    // line 2
    public function block_body($context, array $blocks = [])
    {
        $macros = $this->macros;
        // line 3
        echo "<div class=\"container\">
    <div class=\"row\">
        <div class=\"col-md-12 text-center\">
<h3>Aprendices</h3>
</div>
</div>
<input id=\"codemp\" type=\"hidden\" name=\"codemp\" value=\"";
        // line 9
        echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, ($context["codemp"] ?? null), "cod", [], "any", false, false, false, 9), "html", null, true);
        echo "\">
</div>
<table id='tabla00' class=\"table table-striped table-hover table-sm\" style=\"width:100%;font-size: 10pt; \">
<thead style=\" background-color: #4E73DF;color:#FFFFFF;\">
    <tr class=\"d-flex\">
    <th class='col text-center'>C&eacute;dula</th>
    <th class='col text-center'>Aprendices</th>
    <th class='col text-center'>Sexo</th>
    <th class='col text-center'>Edad</th>
    <th class='col text-center'>&nbsp;</th>
    <th class='col text-center'>Cursos</th>
    <th class='col text-center'>Estado</th>
    <th class='col text-center'>&nbsp;</th>
    </tr>
  </thead>
  <tbody>

";
        // line 26
        $context['_parent'] = $context;
        $context['_seq'] = twig_ensure_traversable(($context["aprendices"] ?? null));
        foreach ($context['_seq'] as $context["_key"] => $context["educado"]) {
            // line 27
            echo "    <tr class=\"d-flex\">
      <td class='col text-center'>";
            // line 28
            echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "cedula", [], "any", false, false, false, 28), "html", null, true);
            echo "</td>
      <td class='col text-left'>";
            // line 29
            echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "aprendiz", [], "any", false, false, false, 29), "html", null, true);
            echo "</td>
      <td class='col text-center'>";
            // line 30
            echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "sexo", [], "any", false, false, false, 30), "html", null, true);
            echo "</td>
      <td class='col text-center'>";
            // line 31
            echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "edad", [], "any", false, false, false, 31), "html", null, true);
            echo "</td>
      <td class='col text-center'>
          <a class=\"dropdown-item\" href='#' data-toggle=\"modal\" data-target=\"#FotoModal\" data-placement=\"top\"  data-ced=\"";
            // line 33
            echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "aprendiz", [], "any", false, false, false, 33), "html", null, true);
            echo "\"  data-foto=\"";
            echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "documento", [], "any", false, false, false, 33), "html", null, true);
            echo "\">
          <!--<img src=\"";
            // line 34
            echo twig_escape_filter($this->env, twig_constant("URLROOTI"), "html", null, true);
            echo "tmp_1708182085-DESCARGA000.JPG\" alt=\"\" width=\"50px\">   -->
          <img src=\"";
            // line 35
            echo twig_escape_filter($this->env, twig_constant("URLROOTI"), "html", null, true);
            echo "foto.jpg\" alt=\"\" width=\"25px\"><br>FOTO
          </a>
      </td>
      <td class='col text-center'>";
            // line 38
            echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "descripcion", [], "any", false, false, false, 38), "html", null, true);
            echo "</td>
    <td class='col text-center'>
            ";
            // line 40
            if ((twig_get_attribute($this->env, $this->source, $context["educado"], "estatus", [], "any", false, false, false, 40) == "ACTIVO")) {
                // line 41
                echo "            <span class=\"badge badge-success\">";
                echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "estatus", [], "any", false, false, false, 41), "html", null, true);
                echo "</span>
            ";
            } else {
                // line 43
                echo "            <span class=\"badge badge-danger\">";
                echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "estatus", [], "any", false, false, false, 43), "html", null, true);
                echo "<br>";
                echo twig_escape_filter($this->env, twig_date_format_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "f_tag", [], "any", false, false, false, 43), "d/m/Y"), "html", null, true);
                echo "</span>
            ";
            }
            // line 45
            echo "    </td>
    <td class='col text-center'>
    <a onclick=\"procesando();\" class=\"btn btn-info btn-sm\" href=\"";
            // line 47
            echo twig_escape_filter($this->env, twig_constant("URLROOT2"), "html", null, true);
            echo "/tableros/detalles_notas/";
            echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "cid", [], "any", false, false, false, 47), "html", null, true);
            echo "\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"Notas\"><i class=\"fa fa-file-archive-o\"></i></a>&nbsp;&nbsp;
<!--    <a onclick=\"procesando();\" class=\"btn btn-primary btn-sm\" href=\"";
            // line 48
            echo twig_escape_filter($this->env, twig_constant("URLROOT2"), "html", null, true);
            echo "/tableros/detalles_doc/";
            echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "cid", [], "any", false, false, false, 48), "html", null, true);
            echo "\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"Documentos\"><i class=\"fa fa-book\"></i></a>&nbsp;&nbsp;
     <a onclick=\"procesando();\" class=\"btn btn-warning btn-sm\" href=\"";
            // line 49
            echo twig_escape_filter($this->env, twig_constant("URLROOT2"), "html", null, true);
            echo "/tableros/detalles_mov/";
            echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, $context["educado"], "cid", [], "any", false, false, false, 49), "html", null, true);
            echo "\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"Movimientos\"><i class=\"fa fa-tasks\"></i></a>&nbsp;&nbsp;
 -->
    </td>
    </tr>

";
        }
        $_parent = $context['_parent'];
        unset($context['_seq'], $context['_iterated'], $context['_key'], $context['educado'], $context['_parent'], $context['loop']);
        $context = array_intersect_key($context, $_parent) + $_parent;
        // line 55
        echo "</tbody>
</table>

<div class=\"modal fade\" id=\"FotoModal\" tabindex=\"-1\" aria-labelledby=\"exampleModalLabel\" aria-hidden=\"true\">
    <div class=\"modal-dialog\">
        <div class=\"modal-content\">
            <div class=\"modal-header\">
                <h5 class=\"modal-title\" id=\"exampleModalLabel\">Foto Aprendiz</h5>
                <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">
                    <span aria-hidden=\"true\">&times;</span>
                </button>
            </div>
            <div class=\"modal-body\">
                <div id=\"foto_ced\"></div>
                    <div id=\"foto_ver\"></div>
            </div>
            <div class=\"modal-footer\">
                <button type=\"button\" class=\"btn btn-secondary\" data-dismiss=\"modal\">Cerrar</button>
              </div>
        </div>
    </div>
</div>

";
    }

    // line 79
    public function block_javascripts($context, array $blocks = [])
    {
        $macros = $this->macros;
        // line 80
        echo "<script>
\$('#ModalSabana').on('show.bs.modal', function (event) {
          var button = \$(event.relatedTarget) // Bot�n que activ� el modal
                    var id = button.data('curso') // Extraer la informaci�n de atributos de datos

                    var modal = \$(this)
                //    modal.find('.modal-title').text('Modificar pa�s: '+nombre)
                    modal.find('.modal-body #id_curso').val(id)

})

\$('#FotoModal').on('show.bs.modal', function (event) {
    var button = \$(event.relatedTarget) // Button that triggered the modal
    var foto = button.data('foto') // Extract info from data-* attributes
    var ced = button.data('ced')

    var modal = \$(this)
    const ver_fotos=\"";
        // line 97
        echo twig_escape_filter($this->env, twig_constant("URLROOTI"), "html", null, true);
        echo "\"+foto;
    console.log(ver_fotos)
let foto_img='<img src=\"'+ver_fotos+'\" width=\"75%\" alt=\"\">'
document.getElementById('foto_ver').innerHTML=foto_img;
document.getElementById('foto_ced').innerHTML=ced;
})

function session(){
    const cod=document.getElementById('codemp').value;
    localStorage.setItem(\"com\", cod);
}
session();
</script>
";
    }

    public function getTemplateName()
    {
        return "empresas/index.html.twig";
    }

    public function isTraitable()
    {
        return false;
    }

    public function getDebugInfo()
    {
        return array (  220 => 97,  201 => 80,  197 => 79,  170 => 55,  156 => 49,  150 => 48,  144 => 47,  140 => 45,  132 => 43,  126 => 41,  124 => 40,  119 => 38,  113 => 35,  109 => 34,  103 => 33,  98 => 31,  94 => 30,  90 => 29,  86 => 28,  83 => 27,  79 => 26,  59 => 9,  51 => 3,  47 => 2,  36 => 1,);
    }

    public function getSourceContext()
    {
        return new Source("{% extends 'inc/base.html.twig' %}
{% block body %}
<div class=\"container\">
    <div class=\"row\">
        <div class=\"col-md-12 text-center\">
<h3>Aprendices</h3>
</div>
</div>
<input id=\"codemp\" type=\"hidden\" name=\"codemp\" value=\"{{ codemp.cod }}\">
</div>
<table id='tabla00' class=\"table table-striped table-hover table-sm\" style=\"width:100%;font-size: 10pt; \">
<thead style=\" background-color: #4E73DF;color:#FFFFFF;\">
    <tr class=\"d-flex\">
    <th class='col text-center'>C&eacute;dula</th>
    <th class='col text-center'>Aprendices</th>
    <th class='col text-center'>Sexo</th>
    <th class='col text-center'>Edad</th>
    <th class='col text-center'>&nbsp;</th>
    <th class='col text-center'>Cursos</th>
    <th class='col text-center'>Estado</th>
    <th class='col text-center'>&nbsp;</th>
    </tr>
  </thead>
  <tbody>

{% for educado in aprendices %}
    <tr class=\"d-flex\">
      <td class='col text-center'>{{ educado.cedula }}</td>
      <td class='col text-left'>{{ educado.aprendiz }}</td>
      <td class='col text-center'>{{ educado.sexo }}</td>
      <td class='col text-center'>{{ educado.edad }}</td>
      <td class='col text-center'>
          <a class=\"dropdown-item\" href='#' data-toggle=\"modal\" data-target=\"#FotoModal\" data-placement=\"top\"  data-ced=\"{{ educado.aprendiz }}\"  data-foto=\"{{ educado.documento }}\">
          <!--<img src=\"{{ constant('URLROOTI') }}tmp_1708182085-DESCARGA000.JPG\" alt=\"\" width=\"50px\">   -->
          <img src=\"{{ constant('URLROOTI') }}foto.jpg\" alt=\"\" width=\"25px\"><br>FOTO
          </a>
      </td>
      <td class='col text-center'>{{ educado.descripcion }}</td>
    <td class='col text-center'>
            {% if educado.estatus=='ACTIVO' %}
            <span class=\"badge badge-success\">{{ educado.estatus }}</span>
            {% else %}
            <span class=\"badge badge-danger\">{{ educado.estatus }}<br>{{ educado.f_tag| date('d/m/Y') }}</span>
            {% endif %}
    </td>
    <td class='col text-center'>
    <a onclick=\"procesando();\" class=\"btn btn-info btn-sm\" href=\"{{ constant('URLROOT2') }}/tableros/detalles_notas/{{ educado.cid }}\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"Notas\"><i class=\"fa fa-file-archive-o\"></i></a>&nbsp;&nbsp;
<!--    <a onclick=\"procesando();\" class=\"btn btn-primary btn-sm\" href=\"{{ constant('URLROOT2') }}/tableros/detalles_doc/{{ educado.cid }}\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"Documentos\"><i class=\"fa fa-book\"></i></a>&nbsp;&nbsp;
     <a onclick=\"procesando();\" class=\"btn btn-warning btn-sm\" href=\"{{ constant('URLROOT2') }}/tableros/detalles_mov/{{ educado.cid }}\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"Movimientos\"><i class=\"fa fa-tasks\"></i></a>&nbsp;&nbsp;
 -->
    </td>
    </tr>

{% endfor %}
</tbody>
</table>

<div class=\"modal fade\" id=\"FotoModal\" tabindex=\"-1\" aria-labelledby=\"exampleModalLabel\" aria-hidden=\"true\">
    <div class=\"modal-dialog\">
        <div class=\"modal-content\">
            <div class=\"modal-header\">
                <h5 class=\"modal-title\" id=\"exampleModalLabel\">Foto Aprendiz</h5>
                <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-label=\"Close\">
                    <span aria-hidden=\"true\">&times;</span>
                </button>
            </div>
            <div class=\"modal-body\">
                <div id=\"foto_ced\"></div>
                    <div id=\"foto_ver\"></div>
            </div>
            <div class=\"modal-footer\">
                <button type=\"button\" class=\"btn btn-secondary\" data-dismiss=\"modal\">Cerrar</button>
              </div>
        </div>
    </div>
</div>

{% endblock %}
{% block javascripts %}
<script>
\$('#ModalSabana').on('show.bs.modal', function (event) {
          var button = \$(event.relatedTarget) // Bot�n que activ� el modal
                    var id = button.data('curso') // Extraer la informaci�n de atributos de datos

                    var modal = \$(this)
                //    modal.find('.modal-title').text('Modificar pa�s: '+nombre)
                    modal.find('.modal-body #id_curso').val(id)

})

\$('#FotoModal').on('show.bs.modal', function (event) {
    var button = \$(event.relatedTarget) // Button that triggered the modal
    var foto = button.data('foto') // Extract info from data-* attributes
    var ced = button.data('ced')

    var modal = \$(this)
    const ver_fotos=\"{{ constant('URLROOTI') }}\"+foto;
    console.log(ver_fotos)
let foto_img='<img src=\"'+ver_fotos+'\" width=\"75%\" alt=\"\">'
document.getElementById('foto_ver').innerHTML=foto_img;
document.getElementById('foto_ced').innerHTML=ced;
})

function session(){
    const cod=document.getElementById('codemp').value;
    localStorage.setItem(\"com\", cod);
}
session();
</script>
{% endblock %}
", "empresas/index.html.twig", "/home/rtfyeqntgk/adiestra.com.ve/sistema/ruices/empresas/app/views/empresas/index.html.twig");
    }
}
