我有一个过滤器切换按钮,用于切换$scope.uiGridOptions.enableFiltering.
$scope.toggleFiltering= function () { $scope.uiGridOptions.enableFiltering = !$scope.uiGridOptions.enableFiltering; $scope.gridApi.core.notifyDataChange( uiGridConstants.dataChange.COLUMN ); }
{{uiGridOptions.enableFiltering}}更改true和false,但我的网格中的过滤器不会隐藏/显示.
$scope.uiGridOptions = { enableFiltering:true,//default onRegisterApi: function (gridApi) { $scope.gridApi = gridApi; },columnDefs: [ { field: 'name',name: 'Name' }] }
Notified of a data change,but the type was not recognised,so no action taken,type was: undefined (anonymous function) d.service.q.logError o.notifyDataChange d.service.q.createBoundedWrapper $scope.toggleFiltering ib.functionCall Dc.(anonymous function).compile.d.on.f $get.l.$eval $get.l.$apply (anonymous function) jQuery.event.dispatch jQuery.event.add.elemData.handle
我希望有一个人可以帮助我.