Dashboards & Visualizations

Why search is not triggered when drop-down value is changed in Django template?

pradeepkumarg
Influencer

Here is my drop-down


var nextday = new DropdownView({
id: "nextday",
labelField: "nextday",
valueField: "nextday",
selectFirstChoice: true,
value: mvc.tokenSafe("$nextday$"),
el: $("#nextdaydiv")
}).render();

        var nextDayChoices = [
            {label: "N",  value: "N" },
            {label: "Y",  value: "Y" },
        ];

And below is my query

{% searchmanager id="simplesearch" search="index=my_index sourcetype=my_sourcetype | search nextday=$nextday$" cache=False%}

When I change my drop-down value, the above search is not being triggered. What am I doing wrong here?

Tags (3)
0 Karma
1 Solution

tom_frotscher
Builder

There is a |token_safe missing after the end of your search in the searchmanager.

See here for examples: http://dev.splunk.com/view/SP-CAAAEWY

View solution in original post

tom_frotscher
Builder

There is a |token_safe missing after the end of your search in the searchmanager.

See here for examples: http://dev.splunk.com/view/SP-CAAAEWY

pradeepkumarg
Influencer

Thank you..

0 Karma
Get Updates on the Splunk Community!

Webinar Recap | Revolutionizing IT Operations: The Transformative Power of AI and ML ...

The Transformative Power of AI and ML in Enhancing Observability   In the realm of IT operations, the ...

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...