information about listening events when a column-based select-input filter changes

information about listening events when a column-based select-input filter changes

cinemacinema Posts: 5Questions: 3Answers: 0

At the moment I'm not using datatables but I want to switch it asap. I would like to ask a question to understand if a feature is present.
I wanted to ask a question about listening to an event fired when a filter changes and I've found the answer in the blog post Highcharts Integration - Asynchronous-Charting.Thank you. Now can I ask a more detailed quesion about this event? I want to use the Individual column searching (select inputs) (I don't want to search a string among all columns), so... is that filter event listening method going to work also in my case?

This question has an accepted answers - jump to answer

Answers

  • kthorngrenkthorngren Posts: 21,158Questions: 26Answers: 4,920
    Answer ✓

    The individual column search with select inputs should work regardless of using Highcharts. I'm guessing you are asking about this event from the blog you linked:

    table.on('draw', function () {
        // Set the data for the first series to be the map returned from the chartData function
        myChart.series[0].setData(chartData(table));
    });
    ``
    
    This code from the select input search example will cause the `-event draw` event to fire:
    
    ```js
                            column
                                .search( val ? '^'+val+'$' : '', true, false )
                                .draw();
                        } );
    

    Does this answer your question?

    Kevin

  • cinemacinema Posts: 5Questions: 3Answers: 0

    Hi Kevin! Thank you for your quick answer: so fast! I'm a bit lost, yeah the event should be that one and I guess that should be the answer.. but let me try somehow... I'm a bit lost... I'll let you know asap, I have to understand how to run the code, a moment, thank you again

  • cinemacinema Posts: 5Questions: 3Answers: 0

    Ok, I understand what you write: that is the answer, at least in theory. I'll do the needed testing soon but I assume it will work. Thank you

This discussion has been closed.