I have the following table that filled it this way
<div class="panel-body">
<script type="text/javascript">
jQuery(document).ready(function($)
{
$("#example-1").DataTable({
"ajax": {
"url": "http://162.222.100.163/proyecto/public/ws/usuarios",
"dataSrc": "records"
},
"columns": [
{ "data": "id" },
{ "data": "nombre1" },
{ "data": "nombre2" },
{ "data": "apellido1" },
{ "data": "apellido2" }
]
});
});
</script>
<table id="example-1" class="table table-striped table-bordered " cellspacing="0" width="100%">
<thead>
<tr>
<th>#</th>
<th>Nombre</th>
<th>Apellido</th>
<th>Usuario</th>
<th>Tipo Usuario</th>
<th>Accion</th>
</tr>
</thead>
<tfoot>
<tr>
<th>#</th>
<th>Nombre</th>
<th>Apellido</th>
<th>Usuario</th>
<th>Tipo Usuario</th>
<th>Accion</th>
</tr>
</tfoot>
</table>
</div>
the table works completely for me, search and page. But for each record I must add a button and it turns out that in the button, I must add the ng-click directive to open a modal. Is this possible. Thank you very much.