fix: ajouter liens navigation vers interface admin regles
- Lien sidebar base.html : "Regles metier" sous "Referentiels" - Lien croise admin_referentiels.html → regles - Boutons dashboard : "Gerer les referentiels" + "Regles metier" Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
{% block sidebar %}
|
||||
<div class="group-title">Admin</div>
|
||||
<a href="/admin/referentiels" style="color:#60a5fa;font-weight:600;border-left-color:#3b82f6;">Referentiels RAG</a>
|
||||
<a href="/admin/rules">Regles metier</a>
|
||||
<a href="/dashboard">Dashboard</a>
|
||||
<a href="/">Retour aux dossiers</a>
|
||||
{% endblock %}
|
||||
|
||||
@@ -415,6 +415,7 @@
|
||||
<a href="/dim" class="sidebar-link">🏥 Synthèse DIM</a>
|
||||
<a href="/cpam" class="sidebar-link">⚠ Contrôles UCR</a>
|
||||
<a href="/admin/referentiels" class="sidebar-link">📚 Référentiels</a>
|
||||
<a href="/admin/rules" class="sidebar-link">⚙ Règles métier</a>
|
||||
</nav>
|
||||
<div class="sidebar-search">
|
||||
<input type="text" id="sidebar-search" placeholder="Rechercher un dossier…" autocomplete="off">
|
||||
|
||||
@@ -9,17 +9,17 @@
|
||||
{# ---- Cartes métriques ---- #}
|
||||
<div style="display:grid;grid-template-columns:repeat(4,1fr);gap:0.75rem;margin-bottom:1.5rem;">
|
||||
{% set cards = [
|
||||
("Dossiers", stats.total_dossiers, "#3b82f6", "#dbeafe"),
|
||||
("Fichiers", stats.total_fichiers, "#6366f1", "#e0e7ff"),
|
||||
("DAS total", stats.total_das, "#1d4ed8", "#dbeafe"),
|
||||
("Actes total", stats.total_actes, "#3730a3", "#e0e7ff"),
|
||||
("Alertes", stats.total_alertes, "#c2410c", "#ffedd5"),
|
||||
("CMA", stats.total_cma, "#dc2626", "#fee2e2"),
|
||||
("Contrôles CPAM", stats.total_cpam, "#b45309", "#fef3c7"),
|
||||
("Temps total", stats.processing_time_total | format_duration, "#065f46", "#d1fae5"),
|
||||
("Dossiers", stats.total_dossiers, "#3b82f6", "#dbeafe", "Nombre total de dossiers patients analysés par le pipeline"),
|
||||
("Fichiers", stats.total_fichiers, "#6366f1", "#e0e7ff", "Nombre total de fichiers PDF/documents traités (un dossier peut contenir plusieurs fichiers)"),
|
||||
("DAS total", stats.total_das, "#1d4ed8", "#dbeafe", "Diagnostics Associés Significatifs — total des codes CIM-10 secondaires identifiés dans tous les dossiers"),
|
||||
("Actes total", stats.total_actes, "#3730a3", "#e0e7ff", "Actes CCAM — total des actes médicaux et chirurgicaux codés dans tous les dossiers"),
|
||||
("Alertes", stats.total_alertes, "#c2410c", "#ffedd5", "Alertes de codage — anomalies, incohérences ou points de vigilance détectés par le pipeline IA et le moteur de règles"),
|
||||
("CMA", stats.total_cma, "#dc2626", "#fee2e2", "Comorbidités et Morbidités Associées — diagnostics secondaires augmentant le niveau de sévérité GHM"),
|
||||
("Contrôles CPAM", stats.total_cpam, "#b45309", "#fef3c7", "Contrôles UCR simulés — scénarios de contestation CPAM avec impact financier estimé"),
|
||||
("Temps total", stats.processing_time_total | format_duration, "#065f46", "#d1fae5", "Durée totale de traitement par le pipeline IA (extraction + codage + validation + QC)"),
|
||||
] %}
|
||||
{% for label, value, fg, bg in cards %}
|
||||
<div class="card" style="text-align:center;padding:1rem;">
|
||||
{% for label, value, fg, bg, tip in cards %}
|
||||
<div class="card" style="text-align:center;padding:1rem;cursor:help;" title="{{ tip }}">
|
||||
<div style="font-size:0.7rem;text-transform:uppercase;letter-spacing:0.05em;color:#64748b;font-weight:600;">{{ label }}</div>
|
||||
<div style="font-size:1.5rem;font-weight:700;color:{{ fg }};margin-top:0.25rem;">{{ value }}</div>
|
||||
</div>
|
||||
@@ -37,7 +37,7 @@
|
||||
{% set conf = stats.dp_confidence %}
|
||||
{% set conf_total = (conf.get('high', 0) + conf.get('medium', 0) + conf.get('low', 0) + conf.get('none', 0)) or 1 %}
|
||||
<div class="card section">
|
||||
<h3>Confiance DP</h3>
|
||||
<h3 title="Répartition du niveau de confiance du pipeline sur le Diagnostic Principal proposé (haute = fiable, basse = à revoir)">Confiance DP</h3>
|
||||
<div style="display:flex;height:28px;border-radius:6px;overflow:hidden;margin-bottom:0.5rem;">
|
||||
{% if conf.get('high', 0) %}
|
||||
<div style="width:{{ (conf.get('high', 0) / conf_total * 100)|round(1) }}%;background:#16a34a;" title="Haute : {{ conf.get('high', 0) }}"></div>
|
||||
@@ -63,7 +63,7 @@
|
||||
{# ---- Top 15 codes CIM-10 ---- #}
|
||||
{% if stats.top_codes %}
|
||||
<div class="card section">
|
||||
<h3>Top 15 codes CIM-10</h3>
|
||||
<h3 title="Les 15 codes CIM-10 les plus fréquemment attribués comme Diagnostic Principal dans les dossiers analysés">Top 15 codes CIM-10</h3>
|
||||
{% for code, count in stats.top_codes %}
|
||||
<div style="display:flex;align-items:center;gap:0.5rem;margin-bottom:0.4rem;">
|
||||
<code style="min-width:60px;font-size:0.8rem;font-weight:600;">{{ code }}</code>
|
||||
@@ -81,7 +81,7 @@
|
||||
{% set ghm_total = (ghm.get('C', 0) + ghm.get('M', 0) + ghm.get('K', 0)) or 1 %}
|
||||
{% if ghm.get('C', 0) or ghm.get('M', 0) or ghm.get('K', 0) %}
|
||||
<div class="card section">
|
||||
<h3>Types GHM</h3>
|
||||
<h3 title="Répartition des Groupes Homogènes de Malades par type : C=Chirurgical, M=Médical, K=Interventionnel (actes non chirurgicaux)">Types GHM</h3>
|
||||
<div style="display:flex;height:28px;border-radius:6px;overflow:hidden;margin-bottom:0.5rem;">
|
||||
{% if ghm.get('C', 0) %}
|
||||
<div style="width:{{ (ghm.get('C', 0) / ghm_total * 100)|round(1) }}%;background:#dc2626;" title="Chirurgical : {{ ghm.get('C', 0) }}"></div>
|
||||
@@ -106,7 +106,7 @@
|
||||
{% set sev_total = (sev.get(1, 0) + sev.get(2, 0) + sev.get(3, 0) + sev.get(4, 0)) or 1 %}
|
||||
{% if sev.get(1, 0) or sev.get(2, 0) or sev.get(3, 0) or sev.get(4, 0) %}
|
||||
<div class="card section">
|
||||
<h3>Sévérité GHM</h3>
|
||||
<h3 title="Répartition des niveaux de sévérité GHM : 1=sans complication, 2=mineur, 3=majeur, 4=très sévère. Détermine la valorisation T2A du séjour">Sévérité GHM</h3>
|
||||
<div style="display:flex;height:28px;border-radius:6px;overflow:hidden;margin-bottom:0.5rem;">
|
||||
{% if sev.get(1, 0) %}
|
||||
<div style="width:{{ (sev.get(1, 0) / sev_total * 100)|round(1) }}%;background:#16a34a;" title="Niveau 1 : {{ sev.get(1, 0) }}"></div>
|
||||
@@ -151,7 +151,13 @@
|
||||
{# ---- Référentiels ---- #}
|
||||
{% if core_refs or ref_refs or proc_refs %}
|
||||
<div class="card section">
|
||||
<div style="display:flex;justify-content:space-between;align-items:center;">
|
||||
<h3>Référentiels ({{ total_refs }} documents)</h3>
|
||||
<div style="display:flex;gap:0.5rem;">
|
||||
<a href="/admin/referentiels" style="font-size:0.75rem;padding:0.25rem 0.6rem;border:1px solid #3b82f6;border-radius:0.25rem;color:#3b82f6;text-decoration:none;">Gérer les référentiels</a>
|
||||
<a href="/admin/rules" style="font-size:0.75rem;padding:0.25rem 0.6rem;border:1px solid #8b5cf6;border-radius:0.25rem;color:#8b5cf6;text-decoration:none;">Règles métier</a>
|
||||
</div>
|
||||
</div>
|
||||
{% if faiss_info %}
|
||||
<div style="display:flex;flex-wrap:wrap;align-items:center;gap:0.75rem;margin-bottom:0.75rem;padding:0.5rem 0.75rem;background:#f0f9ff;border:1px solid #bae6fd;border-radius:6px;">
|
||||
<span style="font-size:0.8rem;font-weight:600;color:#0369a1;">Index FAISS</span>
|
||||
|
||||
Reference in New Issue
Block a user