Hi,
I am trying to use
Thank you!
1. <form>
2. <label>Time Range Picker Within Panels</label>
3. <description>Example of placing a time range picker within a panel.</description>
4. <row>
5. <panel>
6. <input type="time" token="time_range1">
7. <label>Time Range for Internal All</label>
8. <default>
9. <earliestTime>-60m@m</earliestTime>
10. <latestTime>now</latestTime>
11. </default>
12. </input>
13. <chart>
14. <title>_Internal All</title>
15. <searchString>index=_internal | timechart count by sourcetype</searchString>
16. <earliestTime>$time_range1.earliest$</earliestTime>
17. <latestTime>$time_range1.latest$</latestTime>
18. <option name="charting.chart">line</option>
19. <option name="charting.chart.nullValueMode">gaps</option>
20. <option name="charting.chart.sliceCollapsingThreshold">0.01</option>
21. <option name="charting.chart.stackMode">default</option>
22. <option name="charting.chart.style">shiny</option>
23. <option name="charting.drilldown">all</option>
24. <option name="charting.layout.splitSeries">0</option>
25. <option name="charting.legend.labelStyle.overflowMode">ellipsisMiddle</option>
26. <option name="charting.legend.placement">right</option>
27. </chart>
28. </panel>
29. <panel>
30. <input type="time" token="time_range2" searchWhenChanged="true">
31. <label>Time Range for Internal Top 25</label>
32. <default>
33. <earliestTime>@d</earliestTime>
34. <latestTime>now</latestTime>
35. </default>
36. </input>
37. <event>
38. <title>_Internal Top 3</title>
39. <searchString>index=_internal | head 3</searchString>
40. <earliestTime>$time_range2.earliest$</earliestTime>
41. <latestTime>$time_range2.latest$</latestTime>
42. <option name="maxLines">5</option>
43. <option name="raw.drilldown">full</option>
44. <option name="rowNumbers">0</option>
45. <option name="type">list</option>
46. <option name="count">5</option>
47. </event>
48. </panel>
49. </row>
50. </form>
Sample could be like this (multiple timeRange Picker)
<form script="timerange_panels.js" stylesheet="timerange_panels.css">
<label>Multiple Time Picker</label>
<fieldset>
<input type="time" token="time1">
<label>TimePicker for SourceType</label>
<default>
<earliestTime>-15m</earliestTime>
<latestTime>now</latestTime>
</default>
</input>
<input type="time" token="time2">
<label>TimePicker for Source</label>
<default>
<earliestTime>-60m@m</earliestTime>
<latestTime>now</latestTime>
</default>
</input>
</fieldset>
<row>
<table>
<title>Sourcetypes</title>
<searchString>index=_internal | timechart count by sourcetype</searchString>
<earliestTime>$time1.earliest$</earliestTime>
<latestTime>$time1.latest$</latestTime>
<option name="count">5</option>
<option name="displayRowNumbers">0</option>
<option name="wrap">true</option>
<option name="rowNumbers">false</option>
<option name="dataOverlayMode">none</option>
<option name="drilldown">cell</option>
</table>
<table>
<title>Sources</title>
<searchString>index=_internal | timechart count by source</searchString>
<earliestTime>$time2.earliest$</earliestTime>
<latestTime>$time2.latest$</latestTime>
<option name="count">5</option>
<option name="displayRowNumbers">0</option>
</table>
</row>
</form>
I am not aware of the javascript to do the same. I would suggest to consider upgrading to 6.1 or above if possible.
I understood the tokens part, but do I have to change anything in JavaScript to add the time pickers to the panels?
Thanks for your time and help! I really appreciate it
The
My Splunk version is 6.0.3
Is the
Please find my code updated in the question
Can you post your dashboard xml? Also, ensure that you're creating forms (
) as you want to have use input controls (assuming you're on 6.1 or above)