diff --git a/cara/apps/calculator/static/js/form.js b/cara/apps/calculator/static/js/form.js index 39625947..a15f403f 100644 --- a/cara/apps/calculator/static/js/form.js +++ b/cara/apps/calculator/static/js/form.js @@ -68,6 +68,12 @@ function require_fields(obj) { case "mask_off": require_mask(false); break; + case "hepa_yes": + require_hepa(true); + break; + case "hepa_no": + require_hepa(false); + break; default: break; } @@ -135,6 +141,10 @@ function require_lunch(option) { $("#lunch_finish").prop('required', option); } +function require_hepa(option) { + $("#hepa_amount").prop('required', option); +} + function setMaxInfectedPeople() { $("#infected_people").attr("max", $("#total_people").val()); } diff --git a/cara/apps/calculator/templates/calculator.form.html.j2 b/cara/apps/calculator/templates/calculator.form.html.j2 index b59b28c8..32e666fc 100644 --- a/cara/apps/calculator/templates/calculator.form.html.j2 +++ b/cara/apps/calculator/templates/calculator.form.html.j2 @@ -68,11 +68,11 @@ Beta v1.0.0 Please send feedback to HEPA filtration: - - - - + + + +
Face masks: