Hi
I have a dashboard with 3 panels. 2nd and 3rd will be invisible by default
first panel have some data like show below
app | fail | success
----------------------------
A | 10 | 20
B | 30 | 40
------------------------------
if i click on A, corresponding panel (say 2nd(only)) should be visible.
if i click on B, corresponding panel (say 3nd(only)) should be visible.
could someone please help me with the condition I have do in <drilldown></drilldown> in first panel
Currently I am trying like this.
<panel id="first"> ....... </panel>
<panel depends="$second$"> ...... </panel>
<panel depends="$third$"> ...... </panel>
@sravankaripe try the drilldown like below which sets the token for specific panel based on whether row with App =A is clicked or App=B is clicked.
<drilldown>
<unset token="showPanelA"></unset>
<unset token="showPanelB"></unset>
<eval token="showPanelA">case($row.app$=="A","true")</eval>
<eval token="showPanelB">case($row.app$=="B","true")</eval>
</drilldown>
Following is a run anywhere example based on details/sample data provided.
<dashboard>
<label>Shop panel based on table row selected</label>
<row>
<panel>
<title>Click on a Row to open respective Panel (showPanelA=$showPanelA$ | showPanelB=$showPanelB$)</title>
<table>
<search>
<query>| makeresults
| eval data="A|10|20;B|30|40"
| makemv data delim=";"
| mvexpand data
| eval data=split(data,"|"), app=mvindex(data,0), fail=mvindex(data,1), success=mvindex(data,2)
| table app fail success</query>
<earliest>-24h@h</earliest>
<latest>now</latest>
<sampleRatio>1</sampleRatio>
</search>
<option name="count">100</option>
<option name="dataOverlayMode">none</option>
<option name="drilldown">cell</option>
<option name="percentagesRow">false</option>
<option name="refresh.display">progressbar</option>
<option name="rowNumbers">false</option>
<option name="totalsRow">false</option>
<option name="wrap">true</option>
<drilldown>
<unset token="showPanelA"></unset>
<unset token="showPanelB"></unset>
<eval token="showPanelA">case($row.app$=="A","true")</eval>
<eval token="showPanelB">case($row.app$=="B","true")</eval>
</drilldown>
</table>
</panel>
</row>
<row>
<panel depends="$showPanelA$">
<html>Panel A</html>
</panel>
<panel depends="$showPanelB$">
<html>Panel B</html>
</panel>
</row>
</dashboard>
@sravankaripe try the drilldown like below which sets the token for specific panel based on whether row with App =A is clicked or App=B is clicked.
<drilldown>
<unset token="showPanelA"></unset>
<unset token="showPanelB"></unset>
<eval token="showPanelA">case($row.app$=="A","true")</eval>
<eval token="showPanelB">case($row.app$=="B","true")</eval>
</drilldown>
Following is a run anywhere example based on details/sample data provided.
<dashboard>
<label>Shop panel based on table row selected</label>
<row>
<panel>
<title>Click on a Row to open respective Panel (showPanelA=$showPanelA$ | showPanelB=$showPanelB$)</title>
<table>
<search>
<query>| makeresults
| eval data="A|10|20;B|30|40"
| makemv data delim=";"
| mvexpand data
| eval data=split(data,"|"), app=mvindex(data,0), fail=mvindex(data,1), success=mvindex(data,2)
| table app fail success</query>
<earliest>-24h@h</earliest>
<latest>now</latest>
<sampleRatio>1</sampleRatio>
</search>
<option name="count">100</option>
<option name="dataOverlayMode">none</option>
<option name="drilldown">cell</option>
<option name="percentagesRow">false</option>
<option name="refresh.display">progressbar</option>
<option name="rowNumbers">false</option>
<option name="totalsRow">false</option>
<option name="wrap">true</option>
<drilldown>
<unset token="showPanelA"></unset>
<unset token="showPanelB"></unset>
<eval token="showPanelA">case($row.app$=="A","true")</eval>
<eval token="showPanelB">case($row.app$=="B","true")</eval>
</drilldown>
</table>
</panel>
</row>
<row>
<panel depends="$showPanelA$">
<html>Panel A</html>
</panel>
<panel depends="$showPanelB$">
<html>Panel B</html>
</panel>
</row>
</dashboard>