lukaskral / bootstrap-table-filter

MIT License
48 stars 39 forks source link

Updating Filter based on an Event #23

Open hitoro846 opened 9 years ago

hitoro846 commented 9 years ago

Hi guys,

I'm trying to configure the Bootstrap Table Filter to update based on a user clicking on an object rather than using the filter bar itself. If you navigate to http://www.cbstriptracker.com, you'll see that I have a map of the world towards the top of my screen and the Bootstrap Table & Filter at the bottom. I tried to write some JavaScript code such that clicking a country would filter the table accordingly by using the following code:

$('#filter-bar').bootstrapTableFilter('setupFilter', 'country', {_values: ['US']});

I'm getting an error that says bootstrapTableFilter can't be found. Has anyone tried anything similar, and if so have you found a solution for updating the filter based on an event?