Im a big fan of jquery DataTable, but i realize that using AngularJs, it doesnt work, it shows all the data withoug pagination and says "No data available in table Showing 0 to 0 of 0 entries". I have see the website http://l-lin.github.io/angular-datatables/ but i can not make it work, im getting the info from a database. im newbe on angular JS. So basically there's a human way to use jquery datatable with angular and succeed?.
Arr = new Object();
Arr['Accion'] = "ObtenerDatosPersonal";
params = JSON.stringify(Arr);
var url = 'modulos/personal/funciones.php';
$http({
method: "post",
url: url,
data: $.param({params:params}),
headers: { 'Content-Type': 'application/x-www-form-urlencoded' }
}).success(function(data, status, headers, config) {
$scope.Empleadosmodal = data.Empleados;
Cantidad = Empleados.length;
$('#Empleados').DataTable();
$("#myModal").modal("show");
})/*Success*/
.error(function(data, status, headers, config)
{
alert("Ha fallado la petición. Estado HTTP:"+status);
});
$.param()on a string. Would be best to put your code in a directive where you can useelement.Datatable()and there are open source directives already available for datatables