Support for reduced registration fee
This commit is contained in:
@@ -23,6 +23,7 @@ Personendaten
|
||||
Telefon: {{ registration.phone_number }}
|
||||
E-Mail: {{ registration.email_address }}
|
||||
Jahrgang: {{ registration.year_of_birth }}
|
||||
Antrag auf reduzierte Teilnahmegebühr: {% if registration.apply_reduced_fee %}Ja{% else %}Nein{% endif %}
|
||||
{% if registration.dav_member %}DAV Mitgliedsnummer: {{ registration.dav_number }}{% else %}DAV Mitglied: Nein{% endif %}
|
||||
|
||||
Notfall-Kontakt
|
||||
|
||||
@@ -12,6 +12,7 @@ Teilnehmer*in:
|
||||
{{ registration.phone_number }}
|
||||
{{ registration.email_address }}
|
||||
{% if registration.dav_member %}{{ registration.dav_number }}{% else %}Nicht DAV Mitglied{% endif %}
|
||||
Antrag auf reduzierte Teilnahmegebühr: {% if registration.apply_reduced_fee %}Ja{% else %}Nein{% endif %}
|
||||
|
||||
Notfall-Kontakt:
|
||||
{% if registration.emergency_contact %}{{ registration.emergency_contact }}{% else %}-{% endif %}
|
||||
|
||||
@@ -32,8 +32,19 @@
|
||||
}
|
||||
}
|
||||
|
||||
function year_of_birth_handler() {
|
||||
var junior_age = 25
|
||||
var year_now = new Date().getFullYear()
|
||||
var year_of_birth = parseInt($("#id_year_of_birth").val());
|
||||
if(year_of_birth > (year_now - junior_age)) {
|
||||
$("#id_apply_reduced_fee").prop('checked', true);
|
||||
}
|
||||
}
|
||||
|
||||
$(document).ready(function(){
|
||||
init_not_dav_member_handler();
|
||||
var e = $("#id_year_of_birth");
|
||||
e.change(function(){ year_of_birth_handler(); });
|
||||
});
|
||||
</script>
|
||||
{% endblock head-additional %}
|
||||
@@ -74,10 +85,10 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-sm-4">
|
||||
<div class="col-sm-3">
|
||||
{% bootstrap_field form.postal_code %}
|
||||
</div>
|
||||
<div class="col-sm-8">
|
||||
<div class="col-sm-9">
|
||||
{% bootstrap_field form.city %}
|
||||
</div>
|
||||
</div>
|
||||
@@ -93,6 +104,12 @@
|
||||
<div class="col-sm-3">
|
||||
{% bootstrap_field form.year_of_birth %}
|
||||
</div>
|
||||
<div class="col-sm-9">
|
||||
<strong>Antrag auf reduzierte Teilnahmegebühr</strong>
|
||||
{% bootstrap_field form.apply_reduced_fee %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-sm-3">
|
||||
{% bootstrap_field form.dav_number %}
|
||||
</div>
|
||||
@@ -100,11 +117,6 @@
|
||||
<strong>Nichtmitglieder</strong>
|
||||
{% bootstrap_field form.not_dav_member %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<span class="hidden">Antrag auf reduzierten Teilnehmerbeitrag</span>
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
{% bootstrap_field form.emergency_contact %}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user