ranking y tags
This commit is contained in:
parent
0bfeb610a9
commit
d29152a0f6
9 changed files with 344 additions and 48 deletions
|
|
@ -53,6 +53,16 @@
|
|||
<button class="ver-mas-btn" type="button">Ver más</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
{# === Chips de tags para la TRADUCCIÓN (si existen) === #}
|
||||
{% set chips = (tags_por_trad.get(n.traduccion_id) if (n.traduccion_id and tags_por_trad) else None) %}
|
||||
{% if chips %}
|
||||
<div class="noticia-tags" style="margin-top:8px;" aria-label="Etiquetas">
|
||||
{% for valor, tipo in chips %}
|
||||
<span class="badge" title="{{ (tipo or '')|capitalize }}">{{ valor }}</span>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
<div class="tab-panel {% if not (use_tr and n.tiene_traduccion) %}active{% endif %}" data-panel="orig">
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@
|
|||
<div class="card-body">
|
||||
<p>Exporta tu lista de fuentes URL o restaura/importa desde un archivo CSV.</p>
|
||||
<a href="{{ url_for('backup_urls') }}" class="btn"><i class="fas fa-download"></i> Exportar URLs</a>
|
||||
<a href="{{ url_for('restore_urls') }}" class="btn btn-info"><i class="fas fa-upload"></i> Importar URLs</a>
|
||||
<a href="{{ url_for('restore_urls') }}" class="btn btn-info"><i class="fas fa-upload"></i> Importar Fuentes URL</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -55,4 +55,48 @@
|
|||
<a href="{{ url_for('backup_completo') }}" class="btn btn-secondary"><i class="fas fa-archive"></i> Backup Completo (.zip)</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% if top_tags and top_tags|length > 0 %}
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h3>Top tags (últimas 24h)</h3>
|
||||
</div>
|
||||
<div class="card-body" style="padding:0;">
|
||||
<table style="width:100%; border-collapse: collapse;">
|
||||
<thead>
|
||||
<tr style="background-color: rgba(0,0,0,0.05);">
|
||||
<th style="padding: 12px 15px; text-align: left;">Tag</th>
|
||||
<th style="padding: 12px 15px; text-align: left;">Tipo</th>
|
||||
<th style="padding: 12px 15px; text-align: right;">Apariciones</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for t in top_tags %}
|
||||
<tr>
|
||||
<td style="padding: 12px 15px; border-top: 1px solid var(--border-color);">
|
||||
{{ t.valor }}
|
||||
</td>
|
||||
<td style="padding: 12px 15px; border-top: 1px solid var(--border-color); text-transform: capitalize;">
|
||||
{{ t.tipo }}
|
||||
</td>
|
||||
<td style="padding: 12px 15px; border-top: 1px solid var(--border-color); text-align: right;">
|
||||
{{ t.apariciones }}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
{% else %}
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h3>Top tags (últimas 24h)</h3>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<p style="color: var(--text-color-light); margin: 0;">No hay tags para mostrar todavía.</p>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue