fix: omitir pacientes sin RDAs válidas en preview automation
Pacientes cuyos contratos son todos excluidos quedan fuera del listado. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 4.6
parent
c9715e6a7e
commit
7ec9af84c5
@@ -168,12 +168,13 @@ async def preview_automation(
|
||||
"rda": rda_por_pac.get(str(p.get("CODIGO", "")), []),
|
||||
}
|
||||
for p in rows_pac
|
||||
if rda_por_pac.get(str(p.get("CODIGO", "")))
|
||||
]
|
||||
|
||||
return JSONResponse({
|
||||
"success": True,
|
||||
"fecha": fecha,
|
||||
"pacientes": len(rows_pac),
|
||||
"pacientes": len(pacientes_preview),
|
||||
"recepciones": len(grupos),
|
||||
"examenes": total_examenes,
|
||||
"excluidos": excluidos_count,
|
||||
|
||||
Reference in New Issue
Block a user