Hi,
I am trying to highlight values in my table but I am having trouble implementing it because the table cells can either be single-value cells or multi-value cells.
If I only needed to highlight single-value cells then I can use the Splunk example "Table Cell Highlighting" from the "simple_xml_examples" Splunk app.
This works fine for me when highlighting table cells that only have one value.
If I only needed to highlight each value in multi-value cells in my table, then I could use the example from the link below which also works perfectly:
https://answers.splunk.com/answers/694420/is-it-possible-to-highlight-a-value-within-a-multi-1.html
My problem is that my cells can either be single-value or multi-value so I have to write a script that will be able to highlight the cell/value whether it is a multi-value or single-value cell.
For example, if I had the following field/values:
Field_A = Apple
Field_B = Banana
Field_C = Orange, Apple (lets say this is a multi-value field).
If I wanted to highlight all "Apple" values in my table, I would expect to see the following:
In a single-value cell, you can see that the whole cell is highlighted (Field_B).
In a multi-value cell, you can see that the just the value is highlighted (Field_D).
I've tried combining code from both js scripts but have had no luck so far.
I've also tried using the two separate js files on the dashboard which worked at the beginning but later I noticed that, in some cases, it was displaying multi-value cells as comma separated single-value cells.
Did anyone implement this before?
Thanks!
... View more