up
This commit is contained in:
@@ -594,21 +594,8 @@ function abrirFicha(turno) {
|
||||
.catch(() => {});
|
||||
}
|
||||
|
||||
// Cargar consentimientos anticipados (principal y otros ya creados)
|
||||
cargarConsentimientosTurno(turno.id);
|
||||
}
|
||||
|
||||
async function cargarConsentimientosTurno(turnoId) {
|
||||
try {
|
||||
const res = await fetch(`${API}get_consentimientos.php?turno_id=${turnoId}`);
|
||||
const json = await res.json();
|
||||
if (json.ok && json.consentimientos?.length) {
|
||||
consentimientos = json.consentimientos;
|
||||
renderConsentimientos(consentimientos);
|
||||
document.getElementById('sec-consentimientos').style.display = '';
|
||||
document.getElementById('btn-reenviar-consent').classList.remove('d-none');
|
||||
}
|
||||
} catch (_) {}
|
||||
// Buscar consentimientos si ya tiene solicitud
|
||||
verificarSolicitudExistente(turno.id);
|
||||
}
|
||||
|
||||
async function verificarSolicitudExistente(turnoId) {
|
||||
|
||||
Reference in New Issue
Block a user