Can "Reports" be restricted down to specific user group?

REE February 13, 2013

Hi,

I was wondering if we can restrict access to "Reports" on the Summary page of a JIRA project to a specific user group.

I would like only administrators and Project leads to be able to run the reports.

Thank You

2 answers

1 accepted

2 votes
Answer accepted
Renjith Pillai
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.
February 16, 2013

While this is not a secure way, it will help avoiding people from directly using the links available on the project summary page.

Add this to your announcement banner (change the group name from "jira-administrators" to whatever needed)

<script type='text/javascript'>
AJS.$(document).ready(function () {

    AJS.$.getJSON(AJS.contextPath() + '/rest/api/latest/user?expand=groups&username=' + AJS.$('#header-details-user-fullname').attr('data-username'), function (data) {
        var allowed = false;
        var membership = "jira-administrators";
        AJS.$(data.groups.items).each(function (aa) {
            if (this.name == membership) {
                allowed = true;
            }
        });
        if (!allowed) {
            AJS.$('#fragprojectreports').hide();
        }
    });
});
</script>

REE February 17, 2013

Thank you :)

REE February 17, 2013

This works, however once you click off the summary page and click on another tab (Issues) for example and click back on Summary page. You can see the reports.

Is there any other alternative?

Thank you

Renjith Pillai
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.
February 20, 2013

Browsers do not call the ready function when back button is pressed and I guess it is tricky to get that done. Diff browsers may behave differently too. A complete solution will require coding as Nic said.

0 votes
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
February 13, 2013

No, not without coding.

It's pretty pointless too - your users can still get at the data that the reports show, so why make it difficult for them?

REE February 13, 2013

ah...

We need it restricted for our clients, so thats why i thought maybe we could apply a user group restriction.

Will the coding allow that?

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
February 13, 2013

You'll need code to remove the options from the menu, and code to prevent them using the urls directly (although only someone who knows Jira would work out how to get there). But yes, it's possible.

My point about it being pointless stands though - there's nothing to stop your users simply grabbing a download of a list of issues and generating their own (possibly inaccurate) versions from the raw data.

REE February 13, 2013

I will relay this back to our JIRA administrator and we can what is decided.

Thank you so much :)

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events