Added warning on short range when mask on is selected
This commit is contained in:
parent
4ebbe4028f
commit
0c1a531464
2 changed files with 13 additions and 13 deletions
|
|
@ -242,6 +242,16 @@ function on_wearing_mask_change() {
|
|||
if (this.checked) {
|
||||
getChildElement($(this)).show();
|
||||
require_fields(this);
|
||||
if (this.id == "mask_on") {
|
||||
$('#short_range_no').click();
|
||||
$('input[name="short_range_option"]').attr('disabled', true);
|
||||
$("#short_range_warning").show();
|
||||
}
|
||||
else {
|
||||
$('input[name="short_range_option"]').attr('disabled', false);
|
||||
$("#short_range_warning").hide();
|
||||
}
|
||||
|
||||
}
|
||||
else {
|
||||
getChildElement($(this)).hide();
|
||||
|
|
@ -256,17 +266,6 @@ function on_short_range_option_change() {
|
|||
if (this.checked) {
|
||||
getChildElement($(this)).show();
|
||||
require_fields(this);
|
||||
// Disable face mask selection if short_range_yes is selected
|
||||
if (this.id == "short_range_yes") {
|
||||
$('#mask_off').click();
|
||||
require_mask(false);
|
||||
$('input[name="mask_wearing_option"]').attr('disabled', true);
|
||||
$("#face_mask_warning").show();
|
||||
}
|
||||
else {
|
||||
$('input[name="mask_wearing_option"]').attr('disabled', false);
|
||||
$("#face_mask_warning").hide();
|
||||
}
|
||||
}
|
||||
else {
|
||||
getChildElement($(this)).hide();
|
||||
|
|
@ -720,6 +719,7 @@ $(document).ready(function () {
|
|||
// When the short_range_option changes we want to make its respective
|
||||
// children show/hide.
|
||||
$("input[type=radio][name=short_range_option]").change(on_short_range_option_change);
|
||||
|
||||
// Call the function now to handle forward/back button presses in the browser.
|
||||
on_short_range_option_change();
|
||||
|
||||
|
|
|
|||
|
|
@ -268,7 +268,6 @@
|
|||
<label for="mask_on">Yes</label>
|
||||
<input class="ml-2" type="radio" id="mask_off" name="mask_wearing_option" value="mask_off" checked="checked">
|
||||
<label for="mask_off">No</label><br>
|
||||
<p id="face_mask_warning" class="red_text">The analytical model with short range interactions does not take mask wearing into account.</p>
|
||||
|
||||
<div id="DIVmasks_used" style="display:none">
|
||||
<div class='sub_title'>Type of masks used:</div>
|
||||
|
|
@ -367,7 +366,7 @@
|
|||
<hr width="80%">
|
||||
|
||||
<div class="split">
|
||||
<div style="min-width: 20em">Short range interactions (no masks):</div>
|
||||
<div style="min-width: 22em">Short range interactions (without masks):</div>
|
||||
<div>
|
||||
<input class="ml-2" type="radio" id="short_range_no" name="short_range_option" value="short_range_no" checked="checked">
|
||||
<label for="short_range_no">No</label>
|
||||
|
|
@ -375,6 +374,7 @@
|
|||
<label for="short_range_yes">Yes</label>
|
||||
</div>
|
||||
</div>
|
||||
<p id="short_range_warning" class="red_text" style="margin-right: 2rem">The use of masks mitigates exposure at short-range. The analytical model with short range interactions does not take mask wearing into account.</p>
|
||||
|
||||
<div id="DIVsr_interactions" class="none">
|
||||
<div class="d-flex">
|
||||
|
|
|
|||
Loading…
Reference in a new issue