All Apps and Add-ons

Table Module "per row"checbox

Path Finder

Hello everyone,
I have reached the point where I keep hitting dead ends and I turn to the community for help! I am using sideview utils 3.3.11 and advanced xml to try and put a check-box in each table line so that the user can click the checkbox, and the onValue gets stored for later use. I am modeling my dashboard after the example: https://answers.splunk.com/answers/168267/table-module-per-row-checkbox-module-downstreams.html Titled: Table Module "per row" checkbox module downstreams (posting the title since I do not have enough Karama for links).

Here is what the code looks like so far:

<view autoCancelInterval="90" isVisible="true" objectMode="SimpleDashboard" onunloadCancelJobs="true" refresh="-1" template="dashboard.html">
  <label>test</label>

  <module name="AccountBar" layoutPanel="appHeader" />

  <module name="AppBar" layoutPanel="navigationHeader" />

  <module name="Message" layoutPanel="messaging">
    <param name="filter">*</param>
    <param name="maxSize">1</param>
    <param name="clearOnJobDispatch">False</param>
  </module>

  <module name="DashboardTitleBar" layoutPanel="viewHeader" />

  <module name="Message" layoutPanel="navigationHeader">
    <param name="filter">splunk.search.job</param>
    <param name="maxSize">1</param>
    <param name="clearOnJobDispatch">True</param>
    <param name="level">warn</param>
  </module>

  <module name="SideviewUtils" layoutPanel="appHeader" />

  <module name="Search" layoutPanel="panel_row1_col1" autoRun="True">
    <param name="latest">now</param>
    <param name="earliest">-24h@h</param>
    <param name="search"><![CDATA[
index=_internal | head 1000 | top sourcetype | eval tablevalue=sourcetype+"   "+count]]></param>

    <module name="Pager">

      <module name="Table">

        <module name="Checkbox">
          <param name="name">row_selection</param>
          <param name="name">row_selection</param>
          <param name="onValue">$row.field.sourcetype$</param>
        </module>
      </module>
    </module>
  </module>
</view>

Any help or nudges in the right direction would be appreciated!

1 Solution

SplunkTrust
SplunkTrust

You should circle back to the official docs.
Look under "Module Documentation > The Table Module > Table - embedding examples"

Although along the way you might also want to spend some time reading through the other 4 pages of docs and examples about the Table's other features.

In short, you want to "table-embed" the Checkbox instead of just placing it downstream. By placing it downstream you're wiring up an inline drilldown - when the user clicks on a (now-clickable) table row, a lone Checkbox will show, and that's not what you want.

the even shorter version, is that you should
a) put some extra field into your search like | eval actions=""
b) put an attribute on your <module name="Checkbox"> ofgroup="row.field.actions"

But... definitely read through the actual Table-embedding docs and the working examples it has.

View solution in original post

SplunkTrust
SplunkTrust

You should circle back to the official docs.
Look under "Module Documentation > The Table Module > Table - embedding examples"

Although along the way you might also want to spend some time reading through the other 4 pages of docs and examples about the Table's other features.

In short, you want to "table-embed" the Checkbox instead of just placing it downstream. By placing it downstream you're wiring up an inline drilldown - when the user clicks on a (now-clickable) table row, a lone Checkbox will show, and that's not what you want.

the even shorter version, is that you should
a) put some extra field into your search like | eval actions=""
b) put an attribute on your <module name="Checkbox"> ofgroup="row.field.actions"

But... definitely read through the actual Table-embedding docs and the working examples it has.

View solution in original post

Path Finder

Thank you! For some reason when I was playing with this in the editor earlier I could not get it to work properly. By taking the time to hand code using the documentation as my guide I was able to get it all work properly.

0 Karma

Explorer

Hi nkpiquette - its great. can you please share your sample source code.

0 Karma