Forum Discussion

mgriffin1996's avatar
mgriffin1996
Data Storage
01-18-2022
Solved

Looking to run Script on any filter changes

Hello!

I am a developer and have recently been delving into building Javascript API calls for Pivot 2.0

I am looking for a way for my script to run every single time an end user changes any filters on their dashboard.  I've been scouring the forums but can't seem to find anything, perhaps I am just not looking effectively, but who knows 🙂

Does anybody have any ideas or suggestions? Thank you in advance!

  • mgriffin1996 if you write your script in 'filterschanged' event, it will execute every time user changes the filter.

    Here is the dashboard script:

    dashboard.on('filterschanged', function(se, ev){
    	//Write your script here
    	console.log('Testing filterschanged event...' )
    })

    -Hari

2 Replies

Replies have been turned off for this discussion
  • harikm007's avatar
    harikm007
    Data Warehouse

    mgriffin1996 if you write your script in 'filterschanged' event, it will execute every time user changes the filter.

    Here is the dashboard script:

    dashboard.on('filterschanged', function(se, ev){
    	//Write your script here
    	console.log('Testing filterschanged event...' )
    })

    -Hari