Each radio button enables and disables two fields, two by two. When the first radio is clicked the first two textBox
are enabled and the last two are deactivated. When the second radio button is clicked the first two textBox
are disabled and the last two are enabled.
<div class="row">
<div class="col-md-12">
<h5>Tipo de pesquisa:</h5>
<div class="radio radio-inline pesquisa">
<input type="radio" name="optradio" value="Periodo" id="Periodo" onclick="TipoPesquisa()">
<label for="Periodo">Período</label>
</div>
<div class="radio radio-inline pesquisa">
<input type="radio" name="optradio" value="MesAno" id="MesAno" onclick="TipoPesquisa()">
<label for="MesAno">Mês/Ano</label>
</div>
<span id="tipoPesquisaVazio" class="text-danger" style="display: none">
Uma tipo de pesquisa deve ser selecionado.
</span>
</div>
</div>
The onclick="TipoPesquisa()
method is the doubt.