Knowledge Base Article

Removing the duplicate button for specific dashboards in Sisense

Removing the duplicate button for specific dashboards in Sisense

Disclaimer: This post outlines a potential custom workaround for a specific use case or provides instructions regarding a specific task. The solution may not work in all scenarios or Sisense versions, so we strongly recommend testing it in your environment before deployment. If you need further assistance with this, please let us know.

INTRODUCTION

Sisense offers a powerful platform for data analysis and visualization. To further tailor the user experience, Sisense provides a robust plugin framework that allows for extending the core functionality beyond the standard out-of-the-box features. 

This document will guide you through a custom add-on that addresses a specific need: removing the "Duplicate" button from the dashboard options for designated dashboards. This can be useful in scenarios where certain dashboards should not be easily duplicated, such as critical or highly curated reports. This add-on leverages the Sisense plugin framework to manipulate the user interface based on a configuration.

Plugin Location Folder

Similar to all Sisense plugins, custom add-ons are also stored within the Sisense plugins directory: /opt/sisense/storage/plugins. Each custom add-on resides in its own folder, containing at a minimum the following files:

  • plugin.json
  • addon.js (or a similar name reflecting the add-on's purpose)
  • Potentially other configuration files (like config.js in this case)

GETTING STARTED (Installation Steps)

To begin, upload the unzipped folder of the add-on hideDuplicateButton to the plugins directory for your custom add-on (e.g., hideDuplicateButton). In order to install the plugin, you could use either below options:

  1. Upload the zipped or unzipped file. up to you, into your Linux Sisense server, and move the unzipped folder under /opt/sisense/storage/plugins
  2. Navigate to Sisense UI -> Admin -> File Management -> plugins and upload the unzipped folder into the plugins folder

The core logic for this add-on will primarily reside in a JavaScript file.

config.js

This file acts as the configuration for your add-on, informing Sisense about its exact dashboard that needs to be affected by the add-on and the scripts it utilizes. Here's an example of what your config.js file might look like for this add-on:

 

const hiddenDashboardIdsList = [
    '67f02b0175cf4b0033c93943',
    '67f02b0175cf4b0033c93943'
];

module.exports = { hiddenDashboardIdsList };

In this example, "config.js" contains an array of 2 dashboards, which means if you opened the dashboard on Sisense UI, the duplicate option would not be accessible on UI for the end users, as on the left side dashboard navigation panel, and as on the dashboard 3 dots menu, for example:

 


[ALT Text: Screenshot of a software interface showing a list of projects on the left and a context menu open with options. Red text reads "Duplicate button is not presented."] 

[ALT text: "A workspace interface showing a 'Widget' button with options like Delete and Export. The filters panel includes Category, Brand as 'ABC', and Country 'Albania'. A note in red text reads 'No Duplicate Option'."] 

 
Important to notice, the add-on would not affect any dashboards, if you, however and check the dashboard duplicate option on the dashboard which is not specified in config.js, for example:
 
[ALT Text: Menu showing options like Rename, Delete, and Share for a dashboard item. Text indicates limited options for some items, lacking "duplicate."]
 
This post outlines a potential custom workaround for a specific use case or provides instructions regarding a specific task. The solution may not work in all scenarios or Sisense versions, so we strongly recommend testing it in your environment before deployment. If you need further assistance with this, please let us know. 

Conclusion: 

This article describes a custom Sisense plugin that removes the "Duplicate" button from specified dashboards. The plugin, stored in the /opt/sisense/storage/plugins directory, uses a config.js file to list the IDs of dashboards where the duplicate option should be disabled. This prevents users from easily duplicating critical or curated reports.

Published 05-19-2025
No CommentsBe the first to comment