Open Matias-Barrios opened 7 years ago
I am not sure how you have the controller setup or what isn't working but I did it this way.
$scope.setTable = function() { //set count to length of your data $scope.TableParams = new NgTableParams({ count: $scope.maintable.length }, { count: [5, 10, 25], dataset: $scope.maintable)};
//timeout is needed to allow your ng table to render and show all the data. $timeout( function(){ return ngTableExcelExport.csv(this, 'main_table', 'Sheet Name Here') }, 1500 ); //might have to increase the timeout if there is alot of data in the 'main_table'
};
Hi All,
Im trying to make use of this fantasic tool. But the problem is that my table is a paginated ng-table so only the first displayed table gets downloaded. In order to fix that I created a function that set the items per page to some super high limit (10000 in this case but 99999 would also be good ) so I can download the entire thing. My problem is I dont know how to use it from an Angular function.
Could someone help me on this?
Im new to Angular but I understand my above code will never work, therefore I need your help understanding how to combine this code with Angular. Thanks!