admin: add Total imported and Last sync columns to Garmin sync table
Matches the Strava sync table layout. Accumulates total_imported in garmin_sync.json state on each sync run; admin API exposes last_sync_at and total_imported from that file.
This commit is contained in:
@@ -174,6 +174,7 @@ def garmin_sync_iter(
|
||||
|
||||
# ── Persist sync state ─────────────────────────────────────────────────────
|
||||
state["last_sync_at"] = datetime.now(timezone.utc).strftime("%Y-%m-%d")
|
||||
state["total_imported"] = state.get("total_imported", 0) + imported
|
||||
_save_sync_state(user_dir, state)
|
||||
|
||||
yield {
|
||||
|
||||
Reference in New Issue
Block a user