Hello
I have a dashboard where I'd like to color the entire row based on the results of a field value. Currently its an XML dashboard and I have it setup to color the column but I'd like to color the entire row based on the field value.
Here's the code for the dashboard:
<form version="1.1" theme="dark">
<label> Production Report</label>
<fieldset submitButton="false" autoRun="true">
<input type="time" token="field1">
<label></label>
<default>
<earliest>-24h@h</earliest>
<latest>now</latest>
</default>
</input>
</fieldset>
<row>
<panel>
<title>Product Submission Details</title>
<table>
<search>
<query>index=my_dbx sourcetype="my:dbx:details"
| fillnull value="NA" SUPPORTING_DOC_NUMBER PRODUCT_SOURCE_KEY PROJECT_ID
|stats count by ID INT_MESSAGE_ID APPLICATION_NUMBER APPLICATION_TYPE SUBMISSION_NUMBER SUBMISSION_TYPE SUPPORTING_DOC_NUMBER PRODUCT_SOURCE_KEY PROJECT_ID MESSAGE_STATUS MESSAGE_COMMENT LAST_UPDATE_TIMESTAMP
| fields - count
| sort - INT_MESSAGE_ID</query>
<earliest>$field1.earliest$</earliest>
<latest>$field1.latest$</latest>
<sampleRatio>1</sampleRatio>
</search>
<option name="count">10</option>
<option name="dataOverlayMode">none</option>
<option name="drilldown">none</option>
<option name="percentagesRow">false</option>
<option name="rowNumbers">false</option>
<option name="totalsRow">false</option>
<option name="wrap">true</option>
<format type="color" field="MESSAGE_STATUS">
<colorPalette type="map">{"PRODUCTS NOT UPDATABLE":#DC4E41,"Project not Found":#DC4E41,"PRODUCTS UPDATE FAILED":#DC4E41,"PROCESS PRODUCTS":#F8BE34,"PRODUCTS UPDATED":#53A051}</colorPalette>
</format>
</table>
</panel>
</row>
Just trying to figure out how to accomplish this.
Thanks for the assistance.
Try something like this
<form version="1.1" theme="dark">
<label> Production Report</label>
<fieldset submitButton="false" autoRun="true">
<input type="time" token="field1">
<label></label>
<default>
<earliest>-24h@h</earliest>
<latest>now</latest>
</default>
</input>
</fieldset>
<row>
<panel depends="$stayhidden$">
<html>
<style>
#productreport table tbody td div.multivalue-subcell[data-mv-index="1"]{
display: none;
}
</style>
</html>
</panel>
<panel>
<title>IWMS Product Submission Details</title>
<table id="productreport">
<search>
<query>index=my_dbx sourcetype="my:dbx:details"
| fillnull value="NA" SUPPORTING_DOC_NUMBER PRODUCT_SOURCE_KEY PROJECT_ID
|stats count by ID INT_MESSAGE_ID APPLICATION_NUMBER APPLICATION_TYPE SUBMISSION_NUMBER SUBMISSION_TYPE SUPPORTING_DOC_NUMBER PRODUCT_SOURCE_KEY PROJECT_ID MESSAGE_STATUS MESSAGE_COMMENT LAST_UPDATE_TIMESTAMP
| fields - count
| sort - INT_MESSAGE_ID
| foreach *
[| eval <<FIELD>>=mvappend(<<FIELD>>,MESSAGE_STATUS)]</query>
<earliest>$field1.earliest$</earliest>
<latest>$field1.latest$</latest>
<sampleRatio>1</sampleRatio>
</search>
<option name="count">10</option>
<option name="dataOverlayMode">none</option>
<option name="drilldown">none</option>
<option name="percentagesRow">false</option>
<option name="rowNumbers">false</option>
<option name="totalsRow">false</option>
<option name="wrap">true</option>
<format type="color">
<colorPalette type="map">{"PRODUCTS NOT UPDATABLE":#DC4E41,"Project not Found":#DC4E41,"PRODUCTS UPDATE FAILED":#DC4E41,"PROCESS PRODUCTS":#F8BE34,"PRODUCTS UPDATED":#53A051}</colorPalette>
</format>
</table>
</panel>
</row>
Hi @tkwaller1 ,
in the Splunk Dashboard Examples App (https://splunkbase.splunk.com/app/1603) Table Row Highlighting dashboard, you can find a sample of the solution for your requisite.
Ciao.
Giuseppe