【发布时间】:2015-07-26 23:46:57
【问题描述】:
请帮助我使用 angularjs 和控制器动态更改 input[type=button] 的类。
app.controller('anodekeypadcntrl',function($scope){
$scope.clickTwentyFour = function(event){
In this function I need to highlight the button (adding the .active class to it)
};
});
<div class="keypadcontainer" ng-controller="anodekeypadcntrl as child">
------
<input type="button" value="24" id="twentyFour" class="twentyfour anodeKeypadButton"
ng-click="clickTwentyFour($event)" />
-------------
</div>
【问题讨论】:
标签: html css angularjs twitter-bootstrap