Dashboards & Visualizations

Is there a way to remove or hide a dynamic dashboard panel without refreshing the entire dashboard?

jhatton
New Member

I'm starting to experiment with dynamic panels and have one working - I click on a cell in a dashboard panel and a new panel pops up with the results based on the drilldown token/search.

My question is - is there a way to have the newly created panel go away without refreshing the entire dashboard? Adding an 'x' or 'hide' option...etc???

0 Karma

aaraneta_splunk
Splunk Employee
Splunk Employee

@jhatton - Did one of the answers below help provide a solution your question? If yes, please click “Accept” below the best answer to resolve this post and upvote anything that was helpful. If no, please leave a comment with more feedback. Thanks.

0 Karma

niketn
Legend

There could be multiple ways to do it. However, best suited would be based on your current drilldown definition and details like what kind of visualization with what value/token is being used for displaying a new panel, also what should be the condition to hide the new panel.

However, if you just want to hide based on check box Show (checked or unchecked) or Link Switcher Show/Hide, you can use panel depends attribute for the same. If you assign a token to it based on whether the token is set or unset the panel will be displayed or hidden accordingly. Similar to depends rejects attribute can also be used which performs vice-versa. For the first time you can set the token HidePanel for your drilldown.

        .....
        ..... 
                <input type="checkbox" token="hideFlag">
                  <label>Select Field</label>
                  <choice value="true">Hide</choice>
                </input>
              </fieldset>
              <row>
                <panel depends="$hideFlag$">
        .....
        .....

For similar examples on Depends/Rejects and Link Switcher you can check out Splunk 6.x Dashboard Examples app from Splunkbase.

____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
0 Karma

niketn
Legend

@jhatton Were you able to try the above approach for your scenario.

____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
0 Karma

rjthibod
Champion

Yes, but you need a mechanism that will dynamically unset the token value you defined to trigger the drilldown. This can be done with input buttons, toggle buttons, or many other methods. You would need to share more details about your specific use-case/XML in order to get more detailed help.

The basic gist is whenever the trigger occurs that should hide the drilldown, you would want to do something like <unset token="<YOUR_DRILLDOWN_TOKEN>"/>

Get Updates on the Splunk Community!

Detecting Remote Code Executions With the Splunk Threat Research Team

WATCH NOWRemote code execution (RCE) vulnerabilities pose a significant risk to organizations. If exploited, ...

Enter the Dashboard Challenge and Watch the .conf24 Global Broadcast!

The Splunk Community Dashboard Challenge is still happening, and it's not too late to enter for the week of ...

Join Us at the Builder Bar at .conf24 – Empowering Innovation and Collaboration

What is the Builder Bar? The Builder Bar is more than just a place; it's a hub of creativity, collaboration, ...