I'm using datatables along with angular and I have this piece of code:
render: function (data, type, full, meta) {
var buttonHtml = '<div style="text-align: center;">' +
'<button data-toggle="modal" data-target="#myModal" class="btn btn-primary btn-xs" data-ng-click="loadModal(' + meta.row + ')">' +
'<i class="fa fa-folder-open-o"></i> View' +
'</button>' +
'</div>';
return buttonHtml;
}
The above it's a handler from datatables to dynamically format a column based on data.
The problem is that the ng-click handler (loadModal) is never called and I guess because the html is never compiled. How could I solve this issue?