Can I hide the commits OR source OR subversion tab on an issue view screen?

Andre van der Elst August 15, 2013

We've just started using Stash in addition to Subversion. Now we have 3 tabs related to sourcecode on the issue view screen, Commits (cvs) , Subversion, Source (Stash).

Is there a way to disable the unneeded tabs per project ? I know about the 'view source' permissions, but this hides all the tabs instead of the unneeded ones only.

5 answers

1 accepted

2 votes
Answer accepted
richie_gee
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 16, 2013

Hi there,

In simple, for SVN subversion plugin, the user need to be in View Version Control permission to able to see the commit on the subversion tab.

For source tab, the user need to be in 'View Development Tools' permission to be able to view the commit on the source tab.

For Commit tab, the user need to be able to log work to see the tab.

To hide, remove the user from the permission.

Hope this is what you are looking for, cheers :)

Andre van der Elst August 18, 2013

Hi Richie,

it is what I'm looking for, but there's no 'View Development Tools' permission in the permission scheme. Maybe this is added in a newer Jira version ? (I'm running 6.0.6)

richie_gee
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 18, 2013

Hi there,

You are in the latest version, and it has been changed to "View Issue Source Tab" permission for the user to view the Source Tab.

If you are not using the commit tab, you can disable it entirely from the system plugin "DVCS Connector Plugin" then the commit tab will no longer be visible. Or similar to the source tab, removing the permission should remove the commit tab as well.

Cheers!

tanja3981 May 22, 2015

Hi there I'm on JIRA 6.3.4, and I can't find neither "View issues source tab" nor "View Version control permission". Was it renamed again?

0 votes
Avinash Gautam January 10, 2018

Hi All,

 

I am using JIRA 7.3.7 and tried the above solution for changing project permission for "View  Development Tool". But still i see it is not working.

I have made the "View Development Tools" permission for Jira-admins or with admin role. But i have tested and get to know that even a user in just a User role is been able to see commits in the "Subversion ALM" tab in the issues. 

 

Please let me know how to achieve this as this is  very important for our security for users. We are using a large number of users for single project in JIRA. Let me know if you need any other  info or details.  Thanks!

 

--Aviansh Gautam

Yves Martin
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 10, 2018

 Hello

"Subversion ALM" is not official Atlassian Subversion plugin (which is no longer supported) and I guess it does not honor "View Development Tools" permission.

Please report issue to plugin vendor support at https://marketplace.atlassian.com/plugins/com.kintosoft.jira.subversion-plus/server/support

so that this permission checking may be added.

Regards

0 votes
Andre van der Elst August 18, 2013

Thanks Richie,

I guess what I want just isn't possible yet. (only show the 'source' OR 'commits' OR 'subversion' tab depending on what the project is using, and hide the 2 empty tabs, and all this on a per project basis not for all projects)

Yves Martin
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
September 18, 2013

As permission scheme is on a per project basis, it is possible to hide all tabs for a project, or display only "source" or only "commits.

0 votes
Błażej O_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 15, 2013

You can do it easily using javascript (jQuery).

Go to Administration->System->User Interface->Announecement Banner and add following code:

<script type="text/javascript">
jQuery(document).ready(
    function()
    {
    if (jQuery("#project-name-val").text().indexOf("---paste-your-project-name-here---") != -1)
       {
       jQuery("#subversion-commits-tabpanel").attr("style", "display: none;");
       }
    }
);

This way you can disable the desired panel only for certain project. If you want to disable for more than one project you can simply add multiple condition in if like this:

if ( (jQuery("#project-name-val").text().indexOf("project1") != -1 ) && (jQuery("#project-name-val").text().indexOf("project2") != -1 ) )

You can disable any element on the issue screen like this. Right-click element in browser, choose "inspect element" and check the id of the DIV containing it. Usually it should be something like "XXXXXXX-module". Copy the id and paste it to this line:

jQuery("#PASTE-ID-HERE").attr("style", "display: none;");

0 votes
Alex Perez
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 15, 2013

Paste this into the annoucement banner section in order to disable the "Subversion" tab:

<style type="text/css">

#subversion-commits-tabpanel { display: none; }

</style>

Or if you can code the relation between project and hidden tabs, take a look to this approach.

Edit: Also, you can disable the "Subversion" tab by disabling the module "Subversion Changes Tab Panel" from the subversion plugin, or the CVS by disabling the "CVS tab panel" module from "Issue tab Panels" system plugin.

HTH

Suggest an answer

Log in or Sign up to answer