fix: restore /api/stats route, remove dead player code, fix modal scroll

- app_sql.py: add get_overview_stats() with single SQL query (trip count,
  total km, duration, max speed, active DTC count)
- app.py: add /api/stats route (was missing after scp overwrote the file)
- local-videos.js: remove leftover old closePlayer/playVideo/renderFiles
  duplicate block that still had scrollIntoView and references to the old
  panel elements; new modal-based code is the only path now

Co-authored-by: Copilot <[email protected]>
This commit is contained in:
Mathieu Moran
2026-08-10 00:07:14 -04:00
co-authored by Copilot
parent 600fd41353
commit 375b93fcea
3 changed files with 30 additions and 138 deletions
+4
View File
@@ -255,6 +255,10 @@ def api_dtc():
"codes": app_obd.get_fresh_dtc_codes(),
})
@app.route('/api/stats')
def api_stats():
return jsonify(app_sql.get_overview_stats())
if __name__ == '__main__':
# Debug/Development
# app.run(debug=True, host="0.0.0.0", port="5000")