turnero: indicador "Topaz en línea" en header de recepción

Detecta SigWeb al cargar; muestra badge verde solo si localhost:47289
responde. Si no hay pad, no aparece nada.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Lizandro Guarnizo
2026-07-21 11:33:56 -05:00
co-authored by Claude Sonnet 4.6
parent 90a940c379
commit e2f663c6ed
+11
View File
@@ -508,6 +508,9 @@ document.addEventListener('DOMContentLoaded', function() {
</span>
</div>
<div class="d-flex align-items-center gap-2">
<span id="sigweb-badge" style="display:none;font-size:.75rem;color:#16a34a;font-weight:600;white-space:nowrap">
<span style="display:inline-block;width:7px;height:7px;border-radius:50%;background:#22c55e;margin-right:4px;vertical-align:middle;box-shadow:0 0 4px #22c55e"></span>Topaz en línea
</span>
<span class="text-muted small"><?= htmlspecialchars($adminNombre) ?></span>
<button class="btn btn-primary btn-sm" id="btn-llamar" onclick="llamarSiguiente()">
<i class="fas fa-bell me-1"></i>Llamar siguiente
@@ -3028,5 +3031,13 @@ function mostrarToast(msg, type = 'info', duration = 2500) {
</script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script>
<script src="<?= defined('APP_URL') ? rtrim(APP_URL,'/') : '' ?>/assets/js/lab-sidebar.js"></script>
<script>
(function() {
var s = document.createElement('script');
s.src = 'http://localhost:47289/SigWeb/SigWebTablet.js';
s.onload = function() { var b = document.getElementById('sigweb-badge'); if (b) b.style.display = ''; };
document.head.appendChild(s);
})();
</script>
</body>
</html>