Repaired conditions for displaying or hiding fields regarding to state of checkboxes.