range filter ( settings, data, dataIndex ) "data" array didn't shows all cell data in a row

range filter ( settings, data, dataIndex ) "data" array didn't shows all cell data in a row

santhosh_rajavelsanthosh_rajavel Posts: 1Questions: 1Answers: 0
edited May 2018 in Free community support

In my table i have 14 columns, when i tried to data filter on colunm number 14 ,( settings, data, dataIndex ) "data" only gets 10 column data only remaining values are null

which means :
data values:1,221509009,SANTHOSH,RAJAVEL,2018-12-31,Male,SANTHOSHSOCCER01@GMAIL.COM,45.56,45,45,0,,,,,

see the index of above line it shows empty values when the array goes more than 10

$.fn.dataTable.ext.search.push(
    function( settings, data, dataIndex ) {
    var shtwelve = parseInt( $('#idmintwelve').val(), 15 );
    var twelveval = parseFloat( data[12] ) ;
    if ( (  shtwelve == twelveval || isNaN( shtwelve )) )
    {
        alert(" data values:"+**data**+" data index:"+dataIndex);
            return true;
    }
    
    return false;
    }
);

Answers

  • colincolin Posts: 15,142Questions: 1Answers: 2,586

    Hi @santhosh1248 ,

    Take a look at the example here, it's a stripped down version of yours and as you can see, the values are definitely being returned correctly.

    Have you rendered your columns perhaps, so they're displaying a value that's different to the DOM/search values?

    Cheers,

    Colin

This discussion has been closed.