[javascript]view plain copy print ?<inputclass="unchecked"type="checkbox"ng-model="item.isCustOmized"ng-click="switchCheckBox($event,item.isCustOmized)"/>[javascript]view plain copy print ?$scope.switchCheckBox=function($event,value){ //console.log(value) if(value){ $($event.target).addClass("checked"); }else{ $($event.target).removeClass("checked"); } }可见只需要在函数参数中传入$event参数,在函数中使用$event.target就可以获取到了.
700字范文,内容丰富有趣,生活中的好帮手!