Dashboards & Visualizations

How to set the default time in timepicker based on a previous timepicker

coleman07
Path Finder

I have a chart which has a time picker to look at the the volume of data indexed on all our master license servers. When you click on one of the hosts, a new panel appears with a chart and table based on the previous panel. I want to provide a timepicker for that panel and set the defaults to the time selected in the previous panel.

<input type="time" token="all_master_time" searchWhenChanged="true">
        <label></label>
        <default>
          <earliest>-7d@h</earliest>
          <latest>now</latest>
        </default>
      </input>

...

<panel ... >
  <input type="time" token="slavetime" searchWhenChanged="true">
        <label></label>
        <default>
          <earliest>$all_master_time.earliest$</earliest>
          <latest>$all_master_time.latest$</latest>
        </default>
      </input>

Is this possible?

rjthibod
Champion

If this is all in the same dashboard, then this will not work as you want because the value for <default> is only evaluated when the dashboard first loads.

Instead, you should set the value of slavetime to all_master_time when the drilldown occurs from the top-level panel.

<drilldown>
  <condition field="*">
    ...
    <set token="form.slavetime.earliest">$all_master_time.earliest$</set>
    <set token="form.slavetime.latest">$all_master_time.latest$</set>
  </condition>
</drilldown>
0 Karma

sriley_splunk
Splunk Employee
Splunk Employee

Do you have any guidance on if you want to pass the time picker results from one dashboard to a new dashboard?

0 Karma

bowesmana
SplunkTrust
SplunkTrust

Did you solve this?

0 Karma
Get Updates on the Splunk Community!

Introducing the Splunk Community Dashboard Challenge!

Welcome to Splunk Community Dashboard Challenge! This is your chance to showcase your skills in creating ...

Built-in Service Level Objectives Management to Bridge the Gap Between Service & ...

Wednesday, May 29, 2024  |  11AM PST / 2PM ESTRegister now and join us to learn more about how you can ...

Get Your Exclusive Splunk Certified Cybersecurity Defense Engineer Certification at ...

We’re excited to announce a new Splunk certification exam being released at .conf24! If you’re headed to Vegas ...