dimanche 30 avril 2017

Reset radio buttons when unchecking checkbox in AngularJS

example

In the example above, the radio buttons below the checkbox are activated when the checkbox is checked. I'd like to reset the radio buttons (so that no radio button is filled) when unchecking this checkbox.

<div class="checkbox checkbox-info">
  <input id="icb" type="checkbox" ng-model="checked">
  <label for="icb"><i class="fa fa-refresh">&nbsp;</i><b>Integratie</b></label>
</div>
<div class="radio">
  <input type="radio" name="irb" id="iarb" ng-disabled="!checked" value="!checked">
  <label for="iarb">Administrator</label>
</div>
<div class="radio">
  <input type="radio" name="irb" id="imrb" ng-disabled="!checked" value="!checked">
  <label for="imrb">Medewerker</label>
</div>



Aucun commentaire:

Enregistrer un commentaire