somehow my sort

somehow my sort

bayanaaskbayanaask Posts: 2Questions: 1Answers: 0
edited September 2022 in Free community support

Link to test case: http://live.datatables.net/wifezuru/1/edit
Debugger code (debug.datatables.net):
Error messages shown:
Description of problem: 15th column is the true false hidden column. when customer select shipped or not it has to filter. but my filter is showing empty result.

shipped or not status in the 8th column. its showed by checkbox. but 15th column has hidden value true or false.

Other fields are filtering fine, but 15th row does not show any result when its true or false. when value is '' it shows all.

$('#zctb').DataTable().columns(15).search('true').draw(); this is how i test myself. when I use another thing it works. like $('#zctb').DataTable().columns(9).search('Sheridan-Sept2022').draw(); works fine. but that 15th true false does not work

Thank you

Answers

  • colincolin Posts: 15,240Questions: 1Answers: 2,599

    It's because you've disabled searching for that column:

            "columnDefs": [
                {
                    "targets": 15,
    
                    //if searchable enabled, FilterBannedPeople won't work
                    //if searchable disabled, global search will search hidden column
                    "searchable": false
                }
    
            ]
    

    If you remove columns.searchable then it works as expected.

    Colin

  • bayanaaskbayanaask Posts: 2Questions: 1Answers: 0

    @colin Thank you so much. I just moved select box to outside of the table and enabled search works well.

Sign In or Register to comment.