Column filter not visible in searchpane.

Column filter not visible in searchpane.

PareshBafnaPareshBafna Posts: 16Questions: 1Answers: 0
edited April 2020 in Free community support

Why does the first column of my datatable not visible in the searchpane. Is anyone else having the same issue?

Replies

  • kthorngrenkthorngren Posts: 20,302Questions: 26Answers: 4,769

    Probably the same reason the first column in this example doesn't appear:
    https://datatables.net/extensions/searchpanes/examples/initialisation/simple.html

    SearchPanes uses a calculation to determine whether to show the search panel for each column. Its explained in the columns.searchPanes.threshold docs and in this example. You can adjust the threshold or explicitly show/hide panes as shown in this example.

    Kevin

  • PareshBafnaPareshBafna Posts: 16Questions: 1Answers: 0
    edited April 2020

    The data in my first column does not have unique values. It has the same value twice. I added the threshold and had to remove stateSave: true to make the threshold work. But why do i have to remove stateSave? Is there any way where i can use both threshold and stateSave?

  • PareshBafnaPareshBafna Posts: 16Questions: 1Answers: 0
    edited April 2020

    Why does cascadePanes does not work inside columnDefs?

  • sandysandy Posts: 913Questions: 0Answers: 236

    Hi @PareshBafna ,

    The methods to show and hide panes as kevin has provided should work for you. stateSave should not affect the panes being displayed, could you please make a test case showing your issue so that we can take a look? Information on how to create a test case (if you aren't able to link to the page you are working on) is available here.

    searchPanes.cascadePanes will not work inside columnDefs because it affects all of the Panes and is not column specific.

    Thanks,
    Sandy

  • PareshBafnaPareshBafna Posts: 16Questions: 1Answers: 0
    edited April 2020

    Thanks @sandy. I have another problem, having set the stateSave: true and selecting a filter and reloading the page, it works. But after unselecting that filter, only that data which is unselected is shown in that column searchpane and the remaining data does not show up?

  • sandysandy Posts: 913Questions: 0Answers: 236

    No worries. Again I would need to see a test case to debug that I am afraid.

    One thing that I can suggest that you try is to get the SearchPanes files from the nightly releases. There are a number of bug fixes in there which will be released in SearchPanes 1.1, we are just waiting to clear up one or two more before doing this.

    Thanks,
    Sandy

  • PareshBafnaPareshBafna Posts: 16Questions: 1Answers: 0

    The nightly releases is working fine :) Thanks @sandy.

  • sandysandy Posts: 913Questions: 0Answers: 236

    No worries, glad it is working for you

  • PareshBafnaPareshBafna Posts: 16Questions: 1Answers: 0

    I'll create a test case for any further problems :#

  • PareshBafnaPareshBafna Posts: 16Questions: 1Answers: 0

    http://live.datatables.net/sibalewo/2/edit
    Hi @sandy, i've added the test case. If i select the filter for the first and second column and if i reload the page, the filter for the second column remains selected, but all the other data in that filter appears.

  • sandysandy Posts: 913Questions: 0Answers: 236

    Yes something is not right there, I've created an issue internally (DD-1414 for my reference). I'll be sure to get back to you once we have a fix.

  • PareshBafnaPareshBafna Posts: 16Questions: 1Answers: 0

    Appreciate it. Thanks @sandy

This discussion has been closed.