diff options
| author | stilbruch <stilbruch@protonmail.com> | 2022-04-24 19:45:07 -0500 |
|---|---|---|
| committer | stilbruch <stilbruch@protonmail.com> | 2022-04-24 19:45:07 -0500 |
| commit | 0bcfd4a9a26d66af8a44ff36686b54ad2572d9e1 (patch) | |
| tree | ba6d035a835c2451427a46d29b30c85898dd398d /app/templates/workout/create.html | |
| parent | 0dd74e2b672053e3296bc814a36988ba8463854f (diff) | |
| download | Strengthy-0bcfd4a9a26d66af8a44ff36686b54ad2572d9e1.tar.xz Strengthy-0bcfd4a9a26d66af8a44ff36686b54ad2572d9e1.zip | |
Fix workout creation and editing
Diffstat (limited to 'app/templates/workout/create.html')
| -rw-r--r-- | app/templates/workout/create.html | 22 |
1 files changed, 17 insertions, 5 deletions
diff --git a/app/templates/workout/create.html b/app/templates/workout/create.html index a84b457..1f6d136 100644 --- a/app/templates/workout/create.html +++ b/app/templates/workout/create.html @@ -1,6 +1,12 @@ {% extends 'base/form.html' %} -{% block title %}Create Workout{% endblock %} +{% block title %} + {% if workout %} + Edit {{ workout.name }} + {% else %} + Create Workout + {% endif %} +{% endblock %} {% block form %} <div class="field is-horizontal"> @@ -18,7 +24,9 @@ <div id="rows" class="field"> {% for entry in form.exercises.entries %} - {{ entry['id']() }} + {% if workout %} + {{ entry['id']() }} + {% endif %} <div class="field is-horizontal"> <div class="field-body"> <div class="field"> @@ -73,10 +81,14 @@ <div class="field is-horizontal is-grouped is-grouped-right"> <button class="button is-success "> - <span class="icon is-small"> - <i class="fa fa-check"></i> + <span class="icon is-small"><i class="fa fa-check"></i></span> + <span> + {% if workout %} + Save Changes + {% else %} + Create Workout + {% endif %} </span> - <span>Create Workout</span> </button> </div> |
