Cascade method not taking place among filter drop-downs for all the columns
Cascade method not taking place among filter drop-downs for all the columns
Dear All,
I have Data table with some content , But when I filter the column the cascading between columns are not taking place .
Example : If you see my below snap I have employee Donna Snider , When I select it I should get all the positions of that particular employee in my "Position" column drop down .But I am getting all the positions of my table in drop-down.
And I a expecting all the drop-downs to hold the relevant values of employee when I select any employee name
Can any one please help me how can I make to
Replies
I wrote this example a while back which does what you are looking for: http://live.datatables.net/gejojiqu/1/edit .
Allan
Sir,
Thanks for your kind response,
With your given solution I am able to crack the requirement .But also I am loosing my other requirement ,where I required to show the column drop-downs on table header and unable to hide the filter down-downs for few columns .
Request you to please extend your kind support with my below fiddle
https://jsfiddle.net/spspecalist87/Lhxnfsy5/22/
See if this thread helps you place the drop down searches in the header:
https://datatables.net/forums/discussion/comment/125891/#Comment_125891
Maybe this thread will help you display drop down lists for the desired columns. As suggested by Allan the easiest way would be to assign classes to the columns and use an appropriate jQuery selector as noted by Allan in the last post:
https://datatables.net/forums/discussion/48707/how-to-hide-the-filter-drop-down-to-a-particular-column-in-jquery-data-table#latest
Kevin
I have added "dom" : '<"top"iflp<"clear">>rt<"bottom"iflp<"clear">>', and if condition in initComplete function. But I find no luck to move further .
Request you to please review the fiddle https://jsfiddle.net/spspecalist87/Lhxnfsy5/22/
I'm happy to alter the code for you if you need to show the filters in the header, under the support options. Alternatively, Kevin has given links that discuss how you can implement your requirements. The
dom
option does not effect the position of the filters at all.Allan