Clicking a checkbox with ng-click does not update the model

前端 未结 10 1661
太阳男子
太阳男子 2020-12-04 13:17

Clicking on a checkbox and calling ng-click: the model is not updated before ng-click kicks in so the checkbox value is wrongly presented in the UI:

This works in An

10条回答
  •  伪装坚强ぢ
    2020-12-04 13:45

    As reported in https://github.com/angular/angular.js/issues/4765, switching from ng-click to ng-change seems to fix this (I am using Angular 1.2.14)

提交回复
热议问题