Hi at all,
I have to pass earliest and latest values from a form to another one by drilldown, but in the second form I have a TimePicker.
I'm able to do this putting earliest and latest tokens in drilldown URL, but this works only if I directly put tokens in a search of the second form (as the following example):
<!--<search>
<query>tag=HB ....</query>
<earliest>$TimeFrom$</earliest>
<latest>$TimeTo$</latest>
</search>-->
where $TimeFrom$
and $TimeTo$
are my tokens.
But if I put these Tokens in the TimePicker (see following example):
<!--<input type="time" token="TimeDet" searchWhenChanged="true">
<label></label>
<default>
<earliest>$TimeFrom$</earliest>
<latest>$TimeTo$</latest>
</default>
</input>-->
and I put TimeDet Tokens in the search, it doesn't work.
It's like the TimePicker doesn't recognize the Tokens I passed.
Anyone has an idea how to solve this problem?
Thank you in advance.
Bye.
Giuseppe
Just in case anyone is still seeking an answer to this question. somesoni2 is partially correct. Configure your link as follows:
......
<link>
<![CDATA[/app/search/seconddashboard?form.sourcetype=$click.name2$&form.field1.earliest=$earliest$&form.field1.latest=$latest$]]>
</link>
......
In the link above the token name is the same name as the token name in the destination dashboard. In this case, it is using the default names.
If you then configure your destination dashboard panels to use the Shared Time Picker (field1), the panels will load with the intended values. You should not have to change any Simple XML markup on the destination page for this to work.
Try something like this
On your Base Dashboard
......
<link>
<![CDATA[
/app/search/seconddashboard?form.sourcetype=$click.name2$&form.TimeDet.earliest=$earliest$&form.TimeDet.latest=$latest$
]]>
</link>
</drilldown>
......
On your drilldown dashboard
...
<input type="time" token="TimeDet">
<label>Select Time</label>
<default>
<earliest>-15m</earliest>
<latest>now</latest>
</default>
</input>
....
<row>
<panel>
<chart>
<search>
<query>...Your Search....</query>
<earliest>$TimeDet.earliest$</earliest>
<latest>$TimeDet.latest$</latest>
</search>
......
No, in this way the second form doesn't take tokens.
Thank you.
Giuseppe
Putting, as you suggested:
- "form.TimeDet.earliest=$earliest$&form.TimeDet.latest=$latest$" in the link of the first form
- "-15m" and "now" in the TimePicker defaults of the second form
- "$form.TimeDet.earliest$" and "$form.TimeDet.latest$" in the query default of the second form
the second form take the time default of the TimePicker.
In other words my form doesn't take Tokens.
Instead putting "$token_name.earliest$" and "$token_name.latest$" also in the TimePicker default, panels say " Invalid earliest_time"
In other words Tokens time format isn't recognized by the form.
Thank you.
Bye.
Giuseppe
Did you ever get this solved? Or are tokens just not allowed in the time picker's earliest and latest defaults?
Hi
You must use the same token_name in each search tag
look at an example:
<search>
<query>...Your Search....</query>
<earliest>$token_name.earliest$</earliest>
<latest>$token_name.latest$</latest>
</search>