Goals -System refactored - Platzhaltersystem enhanced (als draft) #53

Merged
Lars merged 86 commits from develop into main 2026-03-31 11:46:48 +02:00
Showing only changes of commit 7ffa8f039b - Show all commits

View File

@ -713,7 +713,7 @@ def _get_historical_value_for_goal_type(conn, profile_id: str, goal_type: str, t
FROM {source_table} FROM {source_table}
WHERE profile_id = %s WHERE profile_id = %s
AND {date_col} BETWEEN %s AND %s AND {date_col} BETWEEN %s AND %s
ORDER BY ABS(EXTRACT(EPOCH FROM ({date_col} - %s::date))) ORDER BY ABS({date_col} - %s::date)
LIMIT 1 LIMIT 1
""", ( """, (
profile_id, profile_id,