I got the following gridOptions.columnDefs
$scope.generateReport = function(row) {
alert("Test");
};
$scope.gridOptions.columnDefs = [
{ name: 'Action',
cellEditableCondition: false,
cellTemplate: '<button ng-click="grid.appScope.generateReport(row)">
Report
</button>'
}];
It's not working, the button shows but once clicked its not calling the function. I'm following their guide Here, and I'm using ui-grid - v3.0.0-RC.18
.
I got the following for my html.
<div id="grid1"
ui-grid="gridOptions"
ui-grid-cellnav
ui-grid-edit
ui-grid-expandable
ui-grid-exporter
class="myGrid">
</div>
I also tried to add an external-scope
but didn't make a difference..
Any ideas?