1
Need to validate if all my Radio have been checked, can you help me perform this validation on JS? My cshtml is mounting the radio’s through a Model List<> .
<div id="checklists" class="row">
<div class="col-md-6">
@{int index = 0; }
@foreach (var descricao in @Model.Domiciliacao.listaPerg)
{
<div class="descricaoItemChecklist" style="height: 40px;">
<table class="table table-striped" width="100%" id="tbListaPerg">
<tbody>
<tr>
<td width="80%">@descricao.descperg</td>
<td width="10%">
<label class="CheckBox-inline">
@Html.RadioButtonFor(m => m.Domiciliacao.listaPerg[index].ckPerg, true, new { @class = "radio-inline", @id = "rbListaPerg" }) Sim
</label>
@Html.HiddenFor(m => m.Domiciliacao.listaPerg[index].codperg)
@Html.HiddenFor(m => m.Domiciliacao.listaPerg[index].descperg)
</td>
<td width="10%">
<label class="CheckBox-inline">
@Html.RadioButtonFor(m => (m.Domiciliacao.listaPerg[index].ckPerg), false, new { @class = "radio-inline", @id = "rbListaPerg" }) Não
</label>
@Html.HiddenFor(m => m.Domiciliacao.listaPerg[index].codperg)
@Html.HiddenFor(m => m.Domiciliacao.listaPerg[index].descperg)
</td>
</tr>
</tbody>
</table>
</div>
index = index + 1;
}
</div>
</div>