我注意到在 IE10 中,复选框的背景颜色填充为黑色,然后转换回白色。当我使用 ng-repeat 进行排序时,IE10 似乎不会触发将复选框背景颜色变回白色/正常颜色的事件。
这是对复选框执行 ng-repeat 并根据状态和名称过滤它们的 HTML:
<div ng-repeat="item in (items | orderBy:['!status','itemName'])">
<input type="checkbox" ng-click="itemClickEvent($event, item.itemId)" ng-model="item.status"/>
</div>
已经绑定到点击事件的控制器方法:
$scope.itemClickEvent = function ($event, itemId) {
var checkbox = $event.target;
var checkboxState = checkbox.checked;
if (checkboxState) {
$scope.items = itemsFactory.doSomething(itemId);
} else {
$scope.items = itemsFactory.doAnotherthing(itemId);
}
};
IE10版本:IE10.0.9200.17229
Angularjs 版本:AngularJS v1.2.23
问题截图:
有人能帮我吗?