How to set pageLength on jquery datatable depending on specific column?
How to set pageLength on jquery datatable depending on specific column?
I have a table like this
But I'm trying to set de pageLength parameter depending on the first column to get something like this
My datatable paramerters so far are:
var table = $('#table-comp').DataTable(
language:spanish,
columns: [
name: 'competencia',
title: 'Nombre de Competencia',
,
title: 'Grado Indicador',
,
title: 'Sel',
],
data: datos,
lengthChange: false,
searching: false,
pageLength: 6 //<--- Here is my problem. Not always is 6 fixed.
paging: true,
order: ,
rowsGroup: [
'competencia:name'
],
)
table.draw(false);
Help me please!
By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.
Comments
Post a Comment