somehow working
This commit is contained in:
@@ -53,6 +53,10 @@
|
||||
</div>
|
||||
|
||||
<div class="grid_12 alpha">
|
||||
<p>
|
||||
On this page, you can create and edit sessions for an entire time
|
||||
period.
|
||||
</p>
|
||||
<form id="ps-form-table" method="post">
|
||||
{% csrf_token %}
|
||||
{{ ps_formset.management_form }}
|
||||
@@ -68,9 +72,13 @@
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for form in ps_formset %}
|
||||
<tr>
|
||||
<tr id="id_form_row">
|
||||
<td> {{ forloop.counter }}
|
||||
{% if form.instance.pk %}{{ form.DELETE }}{% endif %}
|
||||
{{ form.id }}
|
||||
{% for field in form.hidden_fields %}
|
||||
{{ field }}
|
||||
{% endfor %}
|
||||
{% for field in form.visible_fields %}
|
||||
<td>
|
||||
{{ field }}
|
||||
@@ -80,7 +88,8 @@
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
<button type="submit">Submit</button>
|
||||
<a class="button gray small grid_2" href="/rowers/sessions/multicreate/thisweek/rower/{{ rower.id }}/extra/{{ extrasessions }}">Add More</a>
|
||||
<button class="button green small grid_2" type="submit">Submit</button>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
@@ -94,10 +103,9 @@
|
||||
$(document).ready(function(){
|
||||
|
||||
$('#ps-form-table tbody tr').formset({
|
||||
prefix: '{{ formset.prefix }}'
|
||||
addText: ''
|
||||
});
|
||||
|
||||
|
||||
$("td #id_sessionmode").change(function() {
|
||||
|
||||
if (this.value == 'TRIMP') {
|
||||
|
||||
Reference in New Issue
Block a user