Dashboards & Visualizations

How to hide the search of a dashboard panel or report?

zacksoft
Contributor

We don't want our end users to be able to see the SPL running behind the reports in the dashboard.
They are clicking on the lens icon and seeing the search and then mess around with it.
Can we make the dashboard just read-only. (no funny business of checking the source code, commands, etc)

0 Karma
1 Solution

renjith_nair
Legend

@zacksoft,

You can set below options to hide the links in panel

<option name="link.visible">false</option>

Also you could hide the edit button by including below in dashboard/form tag

<dashboard hideEdit="true">

Permissions of dashboard could be set to "read only" (edit permissions)

However users could still open a search bar and execute searches

---
What goes around comes around. If it helps, hit it with Karma 🙂

View solution in original post

renjith_nair
Legend

@zacksoft,

You can set below options to hide the links in panel

<option name="link.visible">false</option>

Also you could hide the edit button by including below in dashboard/form tag

<dashboard hideEdit="true">

Permissions of dashboard could be set to "read only" (edit permissions)

However users could still open a search bar and execute searches

---
What goes around comes around. If it helps, hit it with Karma 🙂

AnilPujar
Path Finder

Any idea? how to hide in studio dashboard?

0 Karma

zacksoft
Contributor

@renjith.nair
Could you please guide me where to add these two tags..
I get errors in Source while adding under form.
Here is how my dashboard sample looks like.

 <form>
      <dashboard hideEdit="true">
      <label>2.2 - Mayhem DB BSA Dashboard BURN</label>
      <fieldset submitButton="false" autoRun="true">
        <input type="time" token="field1">
          <label>Time-picker</label>
          <default>
            <earliest>-4h@m</earliest>
            <latest>now</latest>
          </default>
        </input>
      </fieldset>
      <row>
        <panel>
false
          <title>DB Configuration Lookup &lt; Data updated every 5 minutes &gt;</title>
          <table>
            <search>
              <query>host="host1.touchpiit.com" source="/apps/bsassian/Mayhem/logs/access_DB.log"| eval headers=split(_raw,";")
    | eval a=mvindex(headers,1)

    | eval b=mvindex(headers
    ......
    ......
    ......
    ......
    ......

      </panel>
      </row>
    </form>
0 Karma

renjith_nair
Legend

@zacksoft ,

Sure. Its in the form tag itself. It could be used for both dashboard and form tags. Here is an example for both hideEdit and link.visible

<!-- Hide Edit -->
<form hideEdit="true">
  <label>Hide Edit And Link</label>
  <fieldset submitButton="false">
    <input type="dropdown" token="field1">
      <label>Dummy</label>
    </input>
  </fieldset>
  <row>
    <panel>
      <table>
        <search>
          <query>index=_internal 
| stats count by sourcetype</query>
          <earliest>-15m</earliest>
          <latest>now</latest>
        </search>
        <option name="drilldown">none</option>
        <!-- Below option to hide the search button -->
        <option name="link.visible">false</option>
      </table>
    </panel>
  </row>
</form>
---
What goes around comes around. If it helps, hit it with Karma 🙂
0 Karma

VatsalJagani
SplunkTrust
SplunkTrust

Hello @zacksoft,

I don't know any way with access control we can restrict use for using that. But you can use css and JS to hide that button. You can use application.css and application.js to hide those through-out your app.

Hope this helps!!!

0 Karma

rajashaey
Explorer

Is it possible to do using python script having in backend?

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Can’t Make It to Boston? Stream .conf25 and Learn with Haya Husain

Boston may be buzzing this September with Splunk University and .conf25, but you don’t have to pack a bag to ...

Splunk Lantern’s Guide to The Most Popular .conf25 Sessions

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...

Unlock What’s Next: The Splunk Cloud Platform at .conf25

In just a few days, Boston will be buzzing as the Splunk team and thousands of community members come together ...