RadioButtonFor not presenting option checked correctly

0

I need to keep the radiobutton checked when the property VINC_ESTRAT_OPERA = 1 comes from the bank. However, all the controls are showing the last radiobutton arrived, regardless of the value.

<fieldset>
    <legend>1. Possui vínculo e estratégia?</legend>
    <div class="editor-field">
        @Html.RadioButtonFor(m => m.VINC_ESTRAT_OPERA, "1", new { @onclick = "document.getElementById('DESC_VINC_EST_OPE').disabled = false;" , @checked = (Model.VINC_ESTRAT_OPERA == 1 ? true : false) }) Sim
        @Html.RadioButtonFor(m => m.VINC_ESTRAT_OPERA, "0", new { @onclick = "document.getElementById('DESC_VINC_EST_OPE').disabled = true;" , @checked = (Model.VINC_ESTRAT_OPERA == 0 ? true : false) }) Não
    </div>
</fieldset>
    
asked by anonymous 09.08.2018 / 16:58

0 answers