strange firebug alert (FF) after change pagination in row grouping

strange firebug alert (FF) after change pagination in row grouping

pakypaky Posts: 106Questions: 0Answers: 0
edited November 2009 in General
when click on number 2 (second page) of table with row grouped ... return this message in firebug

oSettings.aoData[oSettings.aiDisplay[iDisplayIndex]] is undefined
Line 227


and pagination not seem to work ....

thanks

Replies

  • allanallan Posts: 63,692Questions: 1Answers: 10,500 Site admin
    Hi paky,

    I'm afraid it's impossible to say what this error means without a lot more information. An example showing the issue would probably help.

    One other thing, could you possibly keep the questions you have relating to row grouping in a single thread please?

    Thanks,
    Allan
  • pakypaky Posts: 106Questions: 0Answers: 0
    Hi allan, it speaks of the group but not of the same problem, here I've a pagination problem ... The strange thing is that if I see 25 entries instead of 10 ... works

    [code]
    oTable = $('#box-table-a').dataTable(
    {
    "fnDrawCallback": function ( oSettings ) {
    if ( oSettings.aiDisplay.length == 0 )
    {
    return;
    }

    var nTrs = $('#box-table-a tbody tr');
    var iColspan = nTrs[0].getElementsByTagName('td').length;
    var sLastGroup = "";
    var i=0;
    for ( var i=0 ; i
  • pakypaky Posts: 106Questions: 0Answers: 0
    visual example here :

    1/2 http://www.paskuale.it/pagin_problem_1.jpg
    2/2 http://www.paskuale.it/pagin_problem_2.jpg

    thanks
  • allanallan Posts: 63,692Questions: 1Answers: 10,500 Site admin
    Okay, the reason for the error is exactly what it says it is - in the line:

    [code]
    var sGroup = oSettings.aoData[ oSettings.aiDisplay[iDisplayIndex] ]._aData[0];
    [/code]
    there is not index iDisplayIndex which is greater than the number of records on display when using server-side processing. oSettings._iDisplayStart does not map directly to aoData or aiDisplay when using server-side processing because on each draw the data is wiped out - it's stored on the server-side, not the client-side remember.

    Try using the index 'i' rather than var iDisplayIndex.

    Allan
  • pakypaky Posts: 106Questions: 0Answers: 0
    ok I'll try and tell you, thanks again and congratulations for the project datatable really well done !!!

    paky
  • pakypaky Posts: 106Questions: 0Answers: 0
    everything worked perfectly !! Thanks allan ;)
This discussion has been closed.