Add structured routine logging sheets to Doris Barbell
This commit is contained in:
86
home/doris-barbell/app/templates/routine_log.html
Normal file
86
home/doris-barbell/app/templates/routine_log.html
Normal file
@@ -0,0 +1,86 @@
|
||||
{% extends 'base.html' %}
|
||||
|
||||
{% block content %}
|
||||
<section class="grid cols-2 dossier-grid">
|
||||
<article class="card evidence-board">
|
||||
<div class="case-legend">
|
||||
<span class="section-label">Routine field sheet</span>
|
||||
<span class="pill">Live training log</span>
|
||||
</div>
|
||||
<h2>{{ routine.name }}</h2>
|
||||
<p class="muted">Fill in today's completed reps and weight for each set. Leave any unfinished exercise blank and it will be skipped.</p>
|
||||
{% if routine.notes %}
|
||||
<p class="muted">{{ routine.notes }}</p>
|
||||
{% endif %}
|
||||
</article>
|
||||
|
||||
<article class="card evidence-board">
|
||||
<div class="case-legend">
|
||||
<span class="section-label">Current prescription</span>
|
||||
<span class="pill">Shoulder day</span>
|
||||
</div>
|
||||
<h2>Loaded exercises</h2>
|
||||
<ul class="list case-list">
|
||||
{% for exercise in routine_sheet %}
|
||||
<li>
|
||||
<strong>{{ exercise.exercise_name }}</strong>
|
||||
<p class="muted">{{ exercise.target_sets }} sets{% if exercise.target_reps %} · target reps {{ exercise.target_reps }}{% endif %}{% if exercise.notes %} · {{ exercise.notes }}{% endif %}</p>
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</article>
|
||||
</section>
|
||||
|
||||
<section class="grid dossier-grid">
|
||||
<article class="card evidence-board">
|
||||
<div class="case-legend">
|
||||
<span class="section-label">Workout report</span>
|
||||
<span class="pill">Structured entry</span>
|
||||
</div>
|
||||
<h2>Log this session</h2>
|
||||
<form class="stack-form intake-docket" method="post" action="/workouts/routine-log">
|
||||
<input type="hidden" name="user_id" value="{{ routine.user_id }}">
|
||||
<input type="hidden" name="routine_id" value="{{ routine.id }}">
|
||||
<input type="hidden" name="routine_name" value="{{ routine.name }}">
|
||||
<input type="hidden" name="exercise_count" value="{{ routine_sheet|length }}">
|
||||
<label>Performed at
|
||||
<input type="datetime-local" name="performed_at" value="{{ default_performed_at }}" required>
|
||||
</label>
|
||||
<label>Session notes
|
||||
<textarea name="notes" rows="2" placeholder="Pain, wins, machine availability, energy, anything worth remembering."></textarea>
|
||||
</label>
|
||||
|
||||
{% for exercise in routine_sheet %}
|
||||
<section class="evidence-slab">
|
||||
<input type="hidden" name="exercise_{{ exercise.exercise_index }}_name" value="{{ exercise.exercise_name }}">
|
||||
<input type="hidden" name="exercise_{{ exercise.exercise_index }}_set_count" value="{{ exercise.target_sets }}">
|
||||
<div class="case-legend">
|
||||
<span class="section-label">Exercise {{ loop.index }}</span>
|
||||
<span class="pill">{{ exercise.target_sets }} sets</span>
|
||||
</div>
|
||||
<h3>{{ exercise.exercise_name }}</h3>
|
||||
<p class="muted">Target reps: {{ exercise.target_reps or 'enter manually' }}</p>
|
||||
<div class="grid cols-2 compact-grid">
|
||||
{% for set in exercise.sets %}
|
||||
<div class="evidence-slab compact-slab">
|
||||
<strong>Set {{ set.index + 1 }}</strong>
|
||||
<label>Reps
|
||||
<input type="number" name="exercise_{{ set.exercise_index }}_set_{{ set.index }}_reps" min="1" step="1" value="{{ set.default_reps }}">
|
||||
</label>
|
||||
<label>Weight (lb)
|
||||
<input type="number" name="exercise_{{ set.exercise_index }}_set_{{ set.index }}_weight_lbs" min="0" step="0.1">
|
||||
</label>
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
<label>Exercise notes
|
||||
<textarea name="exercise_{{ exercise.exercise_index }}_notes" rows="2" placeholder="Technique note, pain flag, or machine change."></textarea>
|
||||
</label>
|
||||
</section>
|
||||
{% endfor %}
|
||||
|
||||
<button type="submit">Save {{ routine_action_label }} workout</button>
|
||||
</form>
|
||||
</article>
|
||||
</section>
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user