After selecting exercise for new set in a workout display most recent set with the same exercise(weight, reps) as placeholder rather then value as on form submission it doesnt clear the number inputs. May revert

This commit is contained in:
Peter Stockings
2023-08-21 20:53:31 +10:00
parent 7730a3964b
commit c31ec6ad84

View File

@@ -30,7 +30,8 @@
</label> </label>
<input <input
class="appearance-none block w-full bg-gray-200 text-gray-700 border border-gray-200 rounded py-3 px-4 leading-tight focus:outline-none focus:bg-white focus:border-gray-500" class="appearance-none block w-full bg-gray-200 text-gray-700 border border-gray-200 rounded py-3 px-4 leading-tight focus:outline-none focus:bg-white focus:border-gray-500"
id="grid-city" type="number" name="repetitions" {% if has_value==True %} value="{{ repetitions }}" {% endif %}> id="grid-city" type="number" name="repetitions" {% if has_value==True %} placeholder="{{ repetitions }}" {%
endif %}>
</div> </div>
<div class="w-full md:w-1/3 px-3 mb-6 md:mb-0"> <div class="w-full md:w-1/3 px-3 mb-6 md:mb-0">
@@ -39,5 +40,6 @@
</label> </label>
<input <input
class="appearance-none block w-full bg-gray-200 text-gray-700 border border-gray-200 rounded py-3 px-4 leading-tight focus:outline-none focus:bg-white focus:border-gray-500" class="appearance-none block w-full bg-gray-200 text-gray-700 border border-gray-200 rounded py-3 px-4 leading-tight focus:outline-none focus:bg-white focus:border-gray-500"
id="grid-zip" type="number" name="weight" step="any" {% if has_value==True %} value="{{ weight }}" {% endif %}> id="grid-zip" type="number" name="weight" step="any" {% if has_value==True %} placeholder="{{ weight }}" {%
endif %}>
</div> </div>