feat(v3.4.0): support multi-career subjects with subject_careers Many-to-Many and enhance Google Sheets importer for 6 days

This commit is contained in:
2026-10-07 18:04:23 -03:00
parent 14bf7169c2
commit a60a7cdc78
17 changed files with 335 additions and 67 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "frontend",
"version": "3.3.0",
"version": "3.4.0",
"description": "",
"main": "index.js",
"scripts": {
+3 -3
View File
@@ -85,9 +85,9 @@ const env = nunjucks.configure(path.join(__dirname, '../views'), {
});
// Versiones institucionales del sistema
const APP_VERSION = '3.3.0';
const FRONTEND_VERSION = '3.3.0';
const BACKEND_VERSION = '3.3.0';
const APP_VERSION = '3.4.0';
const FRONTEND_VERSION = '3.4.0';
const BACKEND_VERSION = '3.4.0';
env.addGlobal('app_version', APP_VERSION);
env.addGlobal('frontend_version', FRONTEND_VERSION);
+7 -1
View File
@@ -190,7 +190,13 @@
<div class="fw-semibold text-primary">{{ comm.subject.name }}</div>
<div class="d-flex align-items-center gap-1 mt-1 flex-wrap">
<span class="badge bg-secondary-subtle text-secondary border font-monospace">{{ comm.subject.code }}</span>
<span class="badge bg-primary-subtle text-primary border" title="Carrera"><i class="bi bi-mortarboard me-1"></i>{{ comm.career_name or comm.subject.career_name or 'Carrera General' }}</span>
{% if comm.careers and (comm.careers | length > 0) %}
{% for c_obj in comm.careers %}
<span class="badge bg-primary-subtle text-primary border" title="Carrera"><i class="bi bi-mortarboard me-1"></i>{{ c_obj.name }}</span>
{% endfor %}
{% else %}
<span class="badge bg-primary-subtle text-primary border" title="Carrera"><i class="bi bi-mortarboard me-1"></i>{{ comm.career_name or comm.subject.career_name or 'Carrera General' }}</span>
{% endif %}
<small class="text-muted ms-1">{{ comm.semester }} {{ comm.year }}</small>
</div>
</td>
+22
View File
@@ -222,6 +222,28 @@
</div>
</div>
{% if stats.by_day %}
<div class="card bg-body-tertiary border mb-3">
<div class="card-header bg-transparent py-2 border-bottom">
<h6 class="mb-0 small fw-bold text-dark"><i class="bi bi-calendar3 me-2 text-primary"></i>Desglose Semanal por Día de Cursada:</h6>
</div>
<div class="card-body p-2">
<div class="row g-2 text-center">
{% for day_name, d_info in stats.by_day %}
<div class="col-md-2 col-4">
<div class="p-2 border rounded bg-white shadow-sm">
<span class="fw-bold d-block text-secondary small">{{ day_name }}</span>
<span class="badge {% if d_info.status == 'OK' %}bg-success-subtle text-success border border-success-subtle{% else %}bg-danger-subtle text-danger border border-danger-subtle{% endif %}">
{{ d_info.rows_count }} filas
</span>
</div>
</div>
{% endfor %}
</div>
</div>
</div>
{% endif %}
{% if stats.errors and (stats.errors|length > 0) %}
<div class="alert alert-warning mb-0 small">
<h6 class="alert-heading fw-bold mb-1"><i class="bi bi-exclamation-triangle me-1"></i>Advertencias o incidencias detectadas:</h6>
+9 -1
View File
@@ -148,7 +148,15 @@
{% endif %}
</td>
<td>
{% if s.career_obj %}
{% if s.careers and (s.careers|length > 0) %}
<div class="d-flex flex-wrap gap-1">
{% for c_obj in s.careers %}
<span class="badge bg-secondary-subtle text-secondary border">
<i class="bi bi-mortarboard me-1"></i>{{ c_obj.name }}
</span>
{% endfor %}
</div>
{% elif s.career_obj %}
<span class="badge bg-secondary-subtle text-secondary border">
<i class="bi bi-mortarboard me-1"></i>{{ s.career_obj.name }}
</span>
+1 -1
View File
@@ -225,7 +225,7 @@
</small>
<div class="mt-2">
<span class="badge bg-body-tertiary text-secondary border font-monospace" style="font-size: 0.68rem;" title="Versión de Edu-Space">
<i class="bi bi-tag-fill me-1"></i>v{{ app_version or '3.3.0' }} <span class="opacity-75">(FE: {{ frontend_version or '3.3.0' }} | BE: {{ backend_version or '3.3.0' }})</span>
<i class="bi bi-tag-fill me-1"></i>v{{ app_version or '3.4.0' }} <span class="opacity-75">(FE: {{ frontend_version or '3.4.0' }} | BE: {{ backend_version or '3.4.0' }})</span>
</span>
</div>
</div>
+1 -1
View File
@@ -1127,7 +1127,7 @@
<div class="sidebar-footer-text mt-3 pt-2 border-top border-secondary-subtle text-center">
<span class="badge bg-secondary-subtle text-secondary-emphasis font-monospace px-2 py-1" style="font-size:0.68rem;" title="Versión Institucional de Edu-Space">
<i class="bi bi-tag-fill me-1"></i>v{{ app_version or '3.3.0' }} <span class="opacity-75">(FE: {{ frontend_version or '3.3.0' }} · BE: {{ backend_version or '3.3.0' }})</span>
<i class="bi bi-tag-fill me-1"></i>v{{ app_version or '3.4.0' }} <span class="opacity-75">(FE: {{ frontend_version or '3.4.0' }} · BE: {{ backend_version or '3.4.0' }})</span>
</span>
</div>
</div>