fix: eliminar espacios en horas de Firebird en fechaHoraIngreso/Egreso/Realizacion
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 4.6
parent
dd4d012a4b
commit
c5d6b9857e
@@ -17,13 +17,16 @@ def _fmt_fecha(val) -> str:
|
||||
return s
|
||||
|
||||
|
||||
def _clean_time(s: str) -> str:
|
||||
return s.replace(": ", ":").replace(" :", ":")
|
||||
|
||||
|
||||
def _fmt_datetime(val) -> str:
|
||||
if not val:
|
||||
return ""
|
||||
if hasattr(val, "strftime"):
|
||||
return val.strftime("%d/%m/%Y %H:%M:%S")
|
||||
# Eliminar espacios dentro de la hora ANTES de truncar ("06: 59: 28" → "06:59:28")
|
||||
s = str(val).replace(": ", ":").replace(" :", ":")
|
||||
return _clean_time(val.strftime("%d/%m/%Y %H:%M:%S"))
|
||||
s = _clean_time(str(val))
|
||||
s = s[:19].replace("T", " ")
|
||||
parts = s.split(" ")
|
||||
if len(parts) == 2:
|
||||
|
||||
Reference in New Issue
Block a user