academy finish

This commit is contained in:
2026-09-10 22:46:24 -03:00
parent 5b93a0905f
commit fdb02b11a5
7 changed files with 345 additions and 48 deletions
+72 -4
View File
@@ -544,13 +544,81 @@ window.openCourseModal = function (courseId) {
const course = allCourses.find(c => c.id === courseId);
if (!course) return;
const titleElem = document.getElementById('modal-course-title');
const catElem = document.getElementById('modal-course-category');
const titleElem = document.getElementById('modal-course-title');
const catElem = document.getElementById('modal-course-category');
const detailsElem = document.getElementById('modal-course-details');
const ctaElem = document.getElementById('modal-course-cta');
const ctaElem = document.getElementById('modal-course-cta');
if (titleElem) titleElem.innerText = course.titulo;
if (catElem) catElem.innerText = `${course.categoria} • ${course.modalidad} • ${course.duracion}`;
if (catElem) {
catElem.innerHTML = `
<div class="course-header-top">
<span class="course-badge-category">${course.categoria}</span>
</div>
<div class="course-specs-panel">
<!-- Modalidad -->
<div class="spec-item">
<div class="spec-icon-box spec-icon-blue">
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<rect x="2" y="3" width="20" height="14" rx="2" ry="2"></rect>
<line x1="8" y1="21" x2="16" y2="21"></line>
<line x1="12" y1="17" x2="12" y2="21"></line>
</svg>
</div>
<div class="spec-text">
<span class="spec-label">Modalidad</span>
<strong class="spec-value">${course.modalidad}</strong>
</div>
</div>
<!-- Duración -->
<div class="spec-item">
<div class="spec-icon-box spec-icon-purple">
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<circle cx="12" cy="12" r="10"></circle>
<polyline points="12 6 12 12 16 14"></polyline>
</svg>
</div>
<div class="spec-text">
<span class="spec-label">Duración</span>
<strong class="spec-value">${course.duracion}</strong>
</div>
</div>
<!-- Sector -->
<div class="spec-item">
<div class="spec-icon-box spec-icon-teal">
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<rect x="2" y="7" width="20" height="14" rx="2" ry="2"></rect>
<path d="M16 21V5a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16"></path>
</svg>
</div>
<div class="spec-text">
<span class="spec-label">Sector</span>
<strong class="spec-value">${course.sector || '—'}</strong>
</div>
</div>
<!-- Próxima Fecha -->
<div class="spec-item">
<div class="spec-icon-box spec-icon-amber">
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
<rect x="3" y="4" width="18" height="18" rx="2" ry="2"></rect>
<line x1="16" y1="2" x2="16" y2="6"></line>
<line x1="8" y1="2" x2="8" y2="6"></line>
<line x1="3" y1="10" x2="21" y2="10"></line>
</svg>
</div>
<div class="spec-text">
<span class="spec-label">Próxima fecha</span>
<strong class="spec-value highlight-date">${course.proxima_fecha || 'A consultar'}</strong>
</div>
</div>
</div>
`;
}
if (detailsElem) {
const objHtml = course.objetivos.map(obj => `<li>${obj}</li>`).join('');