Splunk Search

Non Clickable column in drill down table

pero1234
Path Finder

How to set non clickable columns audittrail, linux_audit and scheduler in drill down table like for column OTHER in picture?

alt text

Tags (2)
0 Karma
1 Solution

zpavic
Path Finder

Simple, in $SPLUNK_HOME/etc/apps/appname/appserver/static/application.js add:

if ((Splunk.util.getCurrentView() == "target_dashboard_name") && Splunk.Module.SimpleResultsTable) {
  Splunk.Module.SimpleResultsTable = $.klass(Splunk.Module.SimpleResultsTable, {
    onResultsRendered: function($super) {
      var retVal = $super();
      this.myNonClickableColumns();
      return retVal;
      },

      myNonClickableColumns: function() 
      {
        $('table.simpleResultsTable td[field="target_column1"]').removeClass('d')
        $('table.simpleResultsTable td[field="target_column2"]').removeClass('d')
        $('table.simpleResultsTable td[field="target_column3"]').removeClass('d')        
      },
  });
}

Where:

  • target_dashboard_name is your dashboard with a table
  • target_column1,2,3 will be your non-clickable column in a table

Happy jQuering! 🙂

View solution in original post

zpavic
Path Finder

Simple, in $SPLUNK_HOME/etc/apps/appname/appserver/static/application.js add:

if ((Splunk.util.getCurrentView() == "target_dashboard_name") && Splunk.Module.SimpleResultsTable) {
  Splunk.Module.SimpleResultsTable = $.klass(Splunk.Module.SimpleResultsTable, {
    onResultsRendered: function($super) {
      var retVal = $super();
      this.myNonClickableColumns();
      return retVal;
      },

      myNonClickableColumns: function() 
      {
        $('table.simpleResultsTable td[field="target_column1"]').removeClass('d')
        $('table.simpleResultsTable td[field="target_column2"]').removeClass('d')
        $('table.simpleResultsTable td[field="target_column3"]').removeClass('d')        
      },
  });
}

Where:

  • target_dashboard_name is your dashboard with a table
  • target_column1,2,3 will be your non-clickable column in a table

Happy jQuering! 🙂

blee_i365
Explorer

I need this feature too. When will Splunk implement this? Alternatively I want to be able to map $click.value$ to any column I want regardless of which column of the row the user clicked on.

0 Karma
Get Updates on the Splunk Community!

Detecting Remote Code Executions With the Splunk Threat Research Team

REGISTER NOWRemote code execution (RCE) vulnerabilities pose a significant risk to organizations. If ...

Observability | Use Synthetic Monitoring for Website Metadata Verification

If you are on Splunk Observability Cloud, you may already have Synthetic Monitoringin your observability ...

More Ways To Control Your Costs With Archived Metrics | Register for Tech Talk

Tuesday, May 14, 2024  |  11AM PT / 2PM ET Register to Attend Join us for this Tech Talk and learn how to ...