Hello,
this is so old, but this can help the people to hide all the row from helper from.
Only you have to change the input name and the val:
$(document).ready(function() { var inputstohide = [ $('input[name="date_start"]'), $('input[name="date_end"]') ]; var change = $('select[name="option"]'); var valtosearch = 1; /*OPTIONAL TO HIDE THE INPUTS AFTER PAGE LOAD*/ for (var i=0; i<inputstohide.length;i++){ inputstohide[i].closest('.form-group').hide(); } /******************/ change.on('change', function(e) { opt = $(this).val(); if ( opt == valtosearch ) { for (var i=0; i<inputstohide.length;i++) inputstohide[i].closest('.form-group').show(); } else { for (var i=0; i<inputstohide.length;i++) inputstohide[i].closest('.form-group').hide(); } }); });