-
e5d7a0ad45
fix(docs): quitar credenciales admin de la documentación pública
main

Lizandro GuarnizoandClaude Sonnet 4.6
2026-08-04 19:53:36 -05:00
-
15cf6b3675
fix(docs): cambiar ruta /docs → /documentacion para evitar conflicto con Swagger FastAPI

Lizandro GuarnizoandClaude Sonnet 4.6
2026-08-04 19:47:43 -05:00
-
b927fd7ec0
fix(print): agregar @page para reducir márgenes del navegador al imprimir

Lizandro GuarnizoandClaude Sonnet 4.6
2026-08-04 18:05:54 -05:00
-
eed3c8abd6
fix(print): ocultar sidebar y eliminar fondos de color al imprimir

Lizandro GuarnizoandClaude Sonnet 4.6
2026-08-04 15:49:24 -05:00
-
400e6ff60b
feat(docs): sección de documentación completa en /docs

Lizandro GuarnizoandClaude Sonnet 4.6
2026-08-04 15:45:25 -05:00
-
cfba7a657f
fix(contratos): ampliar contenedor a max-w-full para mostrar columna Acciones

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-30 16:45:49 -05:00
-
91dbcc8135
feat(contratos): gestión de códigos de pago + asignación por contrato

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-30 16:43:13 -05:00
-
551dec9c11
feat(ventas): codFormaPago dinámico CIAC/CR según total + fechaVence por DIASVENC

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-30 16:10:33 -05:00
-
6a54b61a2e
fix: ventas JSON codFormaPago=MU, codBanco=""

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 20:06:59 -05:00
-
64682de147
fix: ventas JSON uses FECHAFACT (billing date) instead of FECHA_RECEPCION

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 19:35:18 -05:00
-
f4f135ba29
fix: add ?codigosucursal to Ventas/Crear URL in ventas.py

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 19:07:27 -05:00
-
b5b6258270
fix: add sucursal 00 to ventas JSON

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 19:03:52 -05:00
-
2053d8a36f
fix: codTercero uses full NIT with dash format (e.g. 900123456-7)

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 18:28:39 -05:00
-
58dc364502
fix: ventas JSON - remove precioExcento, include NIT verification digit in codTercero

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 18:27:58 -05:00
-
22e42463c7
fix: ventas page uses same SQL as automation (FACTURA_DIAN + FECHAFACT)

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 17:28:05 -05:00
-
c0e66989ca
fix: ventas page only shows CMXC records, remove duplicate column

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 17:23:16 -05:00
-
8ed8f0999f
fix: refactor ventas page to group by factura instead of idrecepcion

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 17:08:20 -05:00
-
c1925ef6da
fix: cast FECHAFACT to TIMESTAMP for BETWEEN comparison

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 16:55:17 -05:00
-
33bd25c6c8
fix: reenviar-venta now fetches all receptions of the factura

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 16:46:38 -05:00
-
090890fa46
fix: filter ventas by FECHAFACT (billing date) instead of FECHA_RECEPCION

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 16:45:18 -05:00
-
9dd234e124
debug: add /debug-fb/facturas endpoint to search by NUM_FACTURA range

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 16:13:02 -05:00
-
55bb34a1fa
chore: remove debug fields from preview response, simplify ventas filter

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 16:00:47 -05:00
-
7ac17e29a9
fix: remove duplicate agrupar_por_factura that was overriding the correct one

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 15:45:56 -05:00
-
8747ff950e
ui: show ventas generation errors as toast in preview

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 15:38:47 -05:00
-
c463c6ecc3
debug: catch generar_factura_venta exceptions in preview, expose in response

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 15:31:23 -05:00
-
29ab01e729
debug: add /debug-fb/preview-ventas GET endpoint to trace filter logic

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 15:29:05 -05:00
-
0e837e4a2d
debug: run actual _SQL_VENTAS query in /debug-fb/cmxc to compare

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 15:26:54 -05:00
-
9e6f1171c6
debug: show SQLite contratos excluir_ventas state in /debug-fb/cmxc

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 15:25:16 -05:00
-
27b15b184c
debug: add /debug-fb/cmxc endpoint for direct Firebird CMXC query

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 15:21:32 -05:00
-
b8bee68d6a
debug: expose ventas filter info in preview response

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 15:10:59 -05:00
-
c58ecc1757
fix: defensive grouping filter in preview and run ventas endpoints

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 15:05:09 -05:00
-
3a0964e4ec
fix: generar_factura_venta uses PREFIJO from row, not config default

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 09:59:40 -05:00
-
ae90eaf71c
config: increase scheduler ventana from 10 to 60 minutes

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 09:44:26 -05:00
-
408325192a
fix: use FECHA_RECEPCION for exam query in scheduler, not HORAINICIORECEPCION

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-28 09:32:42 -05:00
-
7f2dffc63e
fix: group ventas by NUM_FACTURA, not IDRECEPCION

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-27 17:36:21 -05:00
-
531fb29122
fix: group terceros by cedula not fecha-as-factura

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-26 21:45:14 -05:00
-
4b70f6f2fa
fix: resumen - group terceros by cedula, prioritize success over warning

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-26 21:34:45 -05:00
-
6e9ee32646
fix: group resumen by factura+tipo only, not cedula

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-26 18:09:42 -05:00
-
ab2ef167f9
feat: add Resumen Diario TNS page as submodule

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-26 17:59:42 -05:00
-
3859095f17
fix: contrato 050 tipo_usuario 11 → 12 (particular)

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-25 10:33:33 -05:00
-
f0c4436622
fix: separar routing CMXC (Ventas) vs LHXC (RDA) por prefijo en SQL

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-25 08:48:42 -05:00
-
ebc24bd480
feat: agregar contrato 050 (PARTICULAR COLEGAS) — va a RDA, no a Ventas

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-25 08:37:14 -05:00
-
02b0defef5
fix: ventas CMXC usan NIT_EMPRESA como codTercero en lugar del código de paciente

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-24 19:08:02 -05:00
-
cefc8b664b
fix: automation.html usa status string (success/warning/error) no booleano ok

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-24 11:02:20 -05:00
-
6a452cd950
feat: sistema de 3 estados (success/warning/error) para envíos TNS

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-24 10:45:15 -05:00
-
a37c1bb7d6
fix: _parse_tns_resp distingue status booleano (TNS) de entero HTTP (ASP.NET)

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-24 10:34:55 -05:00
-
2525e053bf
fix: agregar codigosucursal al endpoint de ventas en automation

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-24 10:21:05 -05:00
-
6950e5aaed
tmp: debug script exploración muestras pendientes Firebird
Lizandro Guarnizo
2026-07-23 12:17:10 -05:00
-
fff34d2003
tmp: debug script para verificar TIPOIDENT en Firebird
Lizandro Guarnizo
2026-07-23 12:09:56 -05:00
-
59ee62591c
chore: bajar intervalo scheduler a 20 segundos

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-23 12:00:09 -05:00
-
78e9c31d90
fix: usar FECHA_RECEPCION en SQL del scheduler en lugar de filtro Python por HORAINICIORECEPCION

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-23 11:38:11 -05:00
-
cffeae7e94
fix: parallelize WA sync and surface scheduler errors in historial

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-23 11:34:30 -05:00
-
5ca97159b4
tmp: debug query paciente 88272630 en Firebird
Lizandro Guarnizo
2026-07-22 23:22:27 -05:00
-
9bffe4209f
fix(automation): parsear respuesta TNS correctamente, tratar 'ya existe' como OK

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-22 23:12:32 -05:00
-
988ac672e9
tmp: ver respuesta_api tercero fallido
Lizandro Guarnizo
2026-07-22 23:07:57 -05:00
-
66d44392ee
fix(automation): guardar mensaje_tns en _guardar_envio; eliminar script tmp

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-22 23:01:27 -05:00
-
36ace04c35
tmp: script buscar paciente en db
Lizandro Guarnizo
2026-07-22 22:52:26 -05:00
-
9bd247219e
fix(automation): skip RDA/preserv si el tercero del paciente falló

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-22 22:47:49 -05:00
-
599391739f
feat(logs): filtro por cédula de paciente en historial de envíos

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-22 22:37:40 -05:00
-
03655427a5
fix(rips): discapacidad siempre 08, diagnostico default Z017 si vacío

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-22 22:33:59 -05:00
-
0a234f056c
fix: execute_query now handles positional tuple params directly

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-21 16:26:22 -05:00
-
329157ca7a
fix: use DATEADD(MINUTE, -n, CURRENT_TIMESTAMP) for Firebird interval

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-21 16:24:09 -05:00
-
04d2eb5563
fix: remove NUM_FACTURA > 0 filter — sync all receptions by time window

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-21 16:03:03 -05:00
-
a880b7fb81
feat: filter exams by time window in SQL (last N minutes), default 10min

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-21 15:59:11 -05:00
-
35859e8d75
fix: auto-load libfbclient on macOS from Firebird.framework

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-21 08:58:26 -05:00
-
6cbf0732e6
feat: resolve exam prices via TARIFA+EMPRESA JOIN, show company name

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-18 14:58:10 -05:00
-
7aa02fe6ac
fix: update /debug-fb/recepcion to show all columns and empresa tables

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-18 14:51:07 -05:00
-
85ae3a0b3e
feat: add /debug-fb/tarifas endpoint to explore price tables in Firebird

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-18 14:29:43 -05:00
-
268451decc
fix: render errores_det objects as readable text in historial

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 15:39:05 -05:00
-
33e569c27a
fix: historial shows error detail and correct Colombia timestamp

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 15:37:00 -05:00
-
83c8b2aa0b
fix: format scheduler times in Colombia UTC-5 server-side

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 15:31:40 -05:00
-
12f5f1388d
fix: correct column names in scheduler status query (total, errores)

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 15:26:34 -05:00
-
467a24baa4
feat: scheduler live status — endpoint + UI polling every 15s

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 15:21:32 -05:00
-
9d79fe932b
fix: reduce diagnosticos batch 500→200, add start_from resume param

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 15:13:14 -05:00
-
97f4561283
fix: capture raw PHP response on JSON error in sync-diagnosticos
Lizandro Guarnizo
2026-07-17 10:43:07 -05:00
-
9a7e4e219b
feat: add CIE-10 sync endpoint and migration button in ERP tab

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 10:27:52 -05:00
-
b65fdf0d9c
fix: use uppercase column names for Firebird alias in diagnosticos query
Lizandro Guarnizo
2026-07-17 10:19:04 -05:00
-
e185095e28
fix: use raw RDB$FIELD_NAME key instead of alias for Firebird metadata query
Lizandro Guarnizo
2026-07-17 10:18:10 -05:00
-
6235b1539c
feat: add /debug-fb/diagnosticos endpoint to list CIE-10 from Firebird

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 10:11:44 -05:00
-
6157d2c2f9
fix: show raw PHP response in error message, clean up errores column UI

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 09:57:45 -05:00
-
cd63683869
feat: enrich sync log with exams, diagnosis, EPS and valor per patient

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 09:52:08 -05:00
-
e044f21e3e
feat: store and display per-patient sync detail in historial

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 09:33:46 -05:00
-
29b6aa4016
fix: pass user_id=None in scheduler sync log to avoid FK constraint

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 09:25:17 -05:00
-
863e012c12
fix: handle Firebird Decimal and datetime types in JSON serialization

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-17 09:10:41 -05:00
-
fc18acc761
fix: use CAST(FECHA_RECEPCION AS DATE) for Firebird timestamp comparison

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-16 21:45:25 -05:00
-
37c4124559
debug: add /debug-fb/recepcion diagnostic endpoint

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-16 21:43:40 -05:00
-
dc18d128fb
feat(envios/erp): add manual sync trigger endpoint and test UI

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-16 21:40:54 -05:00
-
8e27225326
feat: módulos de envío TNS/ERP Lab + sync de médico, empresa y valor total

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-16 21:13:48 -05:00
-
31c0b71c90
fix(automation): quitar filtro por convenio del panel de control

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-11 15:26:55 -05:00
-
c584097426
fix(automation): excluir ventas con NUM_FACTURA=0 (numero 00000)

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-11 15:22:46 -05:00
-
6dee8fba82
feat(automation): resultados con filtro Errores/Enviados/Todos y filas descriptivas

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-11 15:12:13 -05:00
-
fe31af2f9a
feat(automation): paso chips, results failure-first con reenvío por item

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-11 15:03:49 -05:00
-
f8c76f7ce2
fix: ensure_defaults no sobreescribe toggles de contratos al reiniciar

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-11 14:38:09 -05:00
-
73062af8bc
feat: paso 4 ventas en automation + fixes varios

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-11 14:29:39 -05:00
-
21eb99d18d
fix: agregar tipo ventas al historial de logs

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-11 11:57:14 -05:00
-
f103d536c7
feat: excluir_ventas independiente por contrato

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-11 11:56:28 -05:00
-
af71968c7f
fix: TRIM en CODCONTRATO de queries ventas 040

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-11 11:37:08 -05:00
-
6fdca61636
fix: ampliar CHECK constraint para soportar tipo ventas

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-11 11:31:05 -05:00
-
6b84ecfd90
feat: módulo de facturas venta (Ventas/Crear) para contrato 040

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-11 11:16:42 -05:00
-
6fb18a7af6
revert: especialidad siempre usa el default de config

Lizandro GuarnizoandClaude Sonnet 4.6
2026-07-11 10:23:33 -05:00