Create a custom Cascading Interactive Filter using Dynamic Content.

Megha Sharma
ServiceNow Employee
ServiceNow Employee

Hi, I'm trying to create a custom Interactive filter which will be a cascading filter. First level will have reference to sys_user and 2nd level will be the reportees under first level selections. There can be multiple selection. I cannot use out of the box cascading filter option because there are some custom reports on my dashboard. I was successful in creating a dynamic content for the first level ( when that was the only requirement) but now I want to create the 2nd level. My question is can I have two different dashboard handler objects in a single Dynamic content. 

i.e., can i use this twice : 

SNC.canvas.interactiveFilters.setDefaultValue({
id: '1stLevelFilter',
filters: finalFilterForFirstLevel
}, false);
my_dashboardMessageHandler.publishMessage(finalFilterForFirstLevel);
 
Attached is a dynamic content wizard that I have created but I want to make it work for other out of the box reports on the dashboard. 2nd Level selection will be possible only after we select something in the 1st Level, and 2nd level options depend on 1st level. I can make this dynamic content work for my custom report by using DOM manipulation but I would need two different 'finalFilters' for 1st Level and 2nd Level to make it work on the other reports present on the dashbaord. Is that possible?
3 REPLIES 3

rajeevj
Tera Contributor

Hi @Megha Sharma 

 

Have you managed to make any further progress with this one, please?

 

I have a very similar requirement and I need help to make it work.

 

Many thanks

 

Rajeev

Megha Sharma
ServiceNow Employee
ServiceNow Employee

Hi @rajeevj yes, i was able to make progress. 

sivaranjani3894
Tera Guru

@Megha Sharma I have a similar requirement, please share approach you took to make Custom Interactive Filter work as 1st level cascading filter.

 

Thanks,

Siva