feat: add Phase 4 Logging & Tracking — inline set logging, history views

Add workout logging so users can track sets, reps, weight, and a
"felt easy?" toggle inline from the workout day view via HTMX.
Sessions auto-create on first log. History page shows past sessions
with detailed per-exercise breakdowns.

New services: WorkoutSessionService, LogService
New routes: POST /log, /log/{id}/edit, /log/{id}/delete, GET /history, /history/{id}
New templates: log_form, log_entry, session_card, log_history, session_detail
Modified: exercise_card (inline logging), nav (History link), workouts route (session context)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-24 12:12:23 -06:00
parent 23754ea239
commit e35b78ae87
17 changed files with 1071 additions and 1 deletions

View File

@@ -24,9 +24,11 @@ from app.database import get_engine, get_db_session
from app.logging_config import setup_logging
from app.routes.auth import router as auth_router
from app.routes.exercises import router as exercises_router
from app.routes.history import router as history_router
from app.routes.health import router as health_router
from app.routes.pages import router as pages_router
from app.routes.profiles import router as profiles_router
from app.routes.logging import router as logging_router
from app.routes.workouts import router as workouts_router
from app.services.seed_service import SeedService
from app.services.auth_service import AuthService
@@ -104,6 +106,8 @@ def create_app() -> FastAPI:
app.include_router(auth_router)
app.include_router(exercises_router)
app.include_router(health_router)
app.include_router(history_router)
app.include_router(logging_router)
app.include_router(pages_router)
app.include_router(profiles_router)
app.include_router(workouts_router)