ui-grid icon indicating copy to clipboard operation
ui-grid copied to clipboard

update from 4.0.2 to 4.0.4, grid shows nothing and no console error

Open RaeCai opened this issue 9 years ago • 3 comments

Hi, I am updating ui grid from 4.0.2 to 4.0.4 to solve grid menu error(following screen shot) related with ui-grid-exporter. capture but after ui grid lib updated, grid shows nothing and no error in console, only grid menu shows 2 options. have anyone has the same issue? 2

RaeCai avatar Apr 11 '17 21:04 RaeCai

Are you setting data source with string value? Maybe it's related to this issue: https://github.com/angular-ui/ui-grid/issues/6155

slobodan-jov avatar Apr 17 '17 19:04 slobodan-jov

@bnaand yes, I am using string value to set the data source. is there any fix to this issue?

RaeCai avatar Apr 17 '17 20:04 RaeCai

from 4.0.3, ui grid is not taking data source with string, which is setting data on $scope: $scope.data = data; And then direct the grid to resolve whatever is in $scope.data: $scope.gridOptions.data = 'data'; issue solved by using $http.get('/data/100.json') .success(function(data) { $scope.myData = data; $scope.gridOptions.data = $scope.myData; }); Where you do this, you need to take care in updating the data - you can't just update $scope.myData to some other array, you need to update $scope.gridOptions.data to point to that new array as well.

RaeCai avatar Apr 17 '17 21:04 RaeCai