html - Angular dart radio buttons not binding to model -
i have angular dart component following html:
edit: reason of html did not copy properly. outside of label tag have:
<div class="btn-group btn-group-vertical" data-toggle="buttons">
`
<label ng-repeat="item in items" class="btn btn-primary btn-sm btn-block" ng-show="isitemvisible(item)"> <input type="radio" name="options" value="{{item}}" ng-model="selected">{{item}} <span class="badge pull-right"><span class="glyphicon glyphicon-ok"></span></span> </label> </div>`
however, never updates model. have tried using onclick, ng-click, , ng-change same result- functions never called. there directive i'm using incorrectly?
use future in ng-click
allow model updated.
<input type="radio" name="options" value="{{item}}" ng-model="selected" ng-click="radiobuttonclicked();">{{item}}</input> //component code: void radiobuttonclicked(){ new future((){ //use selected model here. }); }
Comments
Post a Comment