69 lines
2.6 KiB
HTML
69 lines
2.6 KiB
HTML
{% extends "layout.html" %}
|
|
{% import "_paging.html" as paging %}
|
|
{% import "gestion/macros.html" as objetivos %}
|
|
|
|
|
|
{% block content %}
|
|
<div class="col-12 row">
|
|
{% for hijo in root.hijos if hijo.visible() %}
|
|
<div class="col-12 ml-3">
|
|
<div class="card shadow mb-4">
|
|
<div class="card-header">
|
|
<div class="d-flex flex-row align-items-center justify-content-between">
|
|
|
|
{% if hijo.tipo %}
|
|
<h3 class="m-0 font-weight-bold text-dark flex-grow-1 text-truncate"><i class="mr-2 fas fa-{{ hijo.tipo }}"></i>{{ hijo.nombre }}</h3>
|
|
{% else %}
|
|
<h3 class="m-0 font-weight-bold text-dark flex-grow-1 text-truncate">{{ hijo.nombre }}</h3>
|
|
{% endif %}
|
|
|
|
{% if hijo.is_manager %}
|
|
<div class="dropdown no-arrow">
|
|
<button class="btn btn-secondary btn-circle dropdown-toggle" type="button" id="dropdownConfig{{ hijo.id }}" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"><i class="fas fa-cog"></i></button>
|
|
<div class="dropdown-menu dropdown-menu-right shadow animated--fade-in" aria-labelledby="dropdownConfig{{ hijo.id }}">
|
|
{% if hijo.estado < 100 %}
|
|
<a class="dropdown-item text-dark" data-toggle="modal" data-target="#modalConfigObjetivo{{ hijo.id }}" data-pid="{{ hijo.id }}" data-rid="{{ hijo.responsableid }}"><i class="mr-2 fas fa-{{ hijo.icon_class }}"></i>Agregar {{label}}</a>
|
|
{% endif %}
|
|
<a class="dropdown-item text-dark" href="{{ url_for('gestion.reporte', objetivoid=hijo.id) }}"><i class="mr-2 fas fa-file-download"></i>Descargar Reporte</a>
|
|
</div>
|
|
</div>
|
|
{% endif %}
|
|
</div>
|
|
</div>
|
|
{% for nieto in hijo.hijos %}
|
|
{% if loop.first and loop.last %}
|
|
<div class="card-body row px-4">
|
|
{{ objetivos.resumen_li( nieto, label, single=True ) }}
|
|
</div>
|
|
{% else %}
|
|
{% if loop.first %}
|
|
<div class="card-body row px-4">
|
|
{% endif %}
|
|
{{ objetivos.resumen_li( nieto, label ) }}
|
|
{% if loop.last %}
|
|
</div>
|
|
{% endif %}
|
|
{% endif %}
|
|
{% endfor %}
|
|
|
|
</div>
|
|
</div>
|
|
{% else %}
|
|
<div class="col-12 text-dark my-1 text-center h5"><i class="fas fa-exclamation-triangle mr-2"></i>Este mensaje no debería mostrarse.</div>
|
|
{% endfor %}
|
|
</div>
|
|
{% endblock content %}
|
|
|
|
|
|
{% block js %}
|
|
{% if tag == 'gestion.personal' %}
|
|
{% for hijo in root.hijos if hijo.visible %}
|
|
{{ objetivos.show_js(hijo, redirect=url_for('gestion.main', uri=uri), invitado=False) }}
|
|
{% endfor %}
|
|
{% else %}
|
|
{% for hijo in root.hijos if hijo.visible %}
|
|
{{ objetivos.show_js(hijo, redirect=url_for('gestion.main', uri=uri), invitado=True) }}
|
|
{% endfor %}
|
|
{% endif %}
|
|
{% endblock %}
|