I have a problem saving a form by a radio button, it always saves the value zero and must be on demand according to what the user selects:
<div class="form-group">
<label for="BONUS" class="col-md-2 control-label">Bono:</label>
<div class="col-md-10">
if (Model.BONUS== 1)
{
<text>
<label class="radio radio-inline"><input type="radio" name="BONUS" value="@Model.BONUS">No</label>
<label class="radio radio-inline"><input type="radio" name="BONUS" checked="checked" value="@Model.BONUS">Si</label>
</text>
}
else if (Model.BONUS == 0)
{
<text>
<label class="radio radio-inline"><input type="radio" name="BONUS" checked="checked" value="@Model.BONUS">No</label>
<label class="radio radio-inline"><input type="radio" name="BONUS" value="@Model.BONUS">Si</label>
</text>
}
else
{
<text>
<label class="radio radio-inline"><input type="radio" name="BONUS" value="0">No</label>
<label class="radio radio-inline"><input type="radio" name="BONUS" value="1">Si</label>
</text>
}
}
</div>
</div>
Please if someone can help me with the error.