Verify that enableGridMenu is set to false.
and inside GridOptions do something like this:
'exporterCsvFilename' : 'clarification-status.csv', exporterCsvLinkElement: angular.element(document.querySelectorAll(".custom-csv-link-location")), onRegisterApi: function(gridApi){ vm.gridApi = gridApi; },
and then you need to use csv or exportpdf export functions like this.
vm.exportCsv = function() { var grid = vm.gridApi.grid; var rowTypes = uiGridExporterConstants.ALL; var colTypes = uiGridExporterConstants.ALL; uiGridExporterService.csvExport(grid, rowTypes, colTypes); };
and inside your html view you need to call this exportcsv () function as shown below.
<img ng-src="public/images/excel-icon.png" ng-click="vm.exportCsv()" />
Siddhartha thhota
source share