temptours+tours

This commit is contained in:
2025-12-09 11:27:02 -05:00
commit f28439c9bb
49 changed files with 18416 additions and 0 deletions

16
engine/utils.py Normal file
View File

@ -0,0 +1,16 @@
from decimal import Decimal
def format_temps_decimal(d):
"""
Formatte un Decimal représentant un nombre de secondes
en HH:MM:SS.mmm — exemple : 00:06:52.820
"""
d = Decimal(d)
total_sec = float(d)
hours = int(total_sec // 3600)
minutes = int((total_sec % 3600) // 60)
seconds = total_sec % 60
return f"{hours:02d}:{minutes:02d}:{seconds:06.3f}"