Condition 'user_is_admin' is not working in WebItems section of atlassian-connect.json file

Hi Everyone,

I have a user account access in jira product let’s take it as a domain name. So, In ideal case I should not have access to add addon or not even a manage apps section of jira.

But, If I hit the url https://domain_name/plugins/servlet/ac/PRODUCT_KEY/CONFIG_KEY directly I am getting the configuration page.
In ideal case it should not be showing .

And they have used this condition in webitem section of atlassian-connect.json file for above config page.

1st code change:


{
"condition":"user_is_logged_in",
"invert":false
},
{
"condition": "user_is_admin",
"invert": false
}

2nd code change:


"conditions":[
        {
          "and": [
            {
              "condition": "user_is_logged_in",
              "invert": false
            },
            {
              "condition": "user_is_admin",
              "invert": false
            }
          ]
        }
      ]

both are not working.

Can anyone suggest any other way that only allows admin user to see the configure page.

Thanks In advance.
Akshay.

@AkshayMehta could you please let us know what type of Connect module you are using? You mention web items, but they don’t come with an associated page.

The Admin Page module has the behavior you describe.

Hi @epehrson ,
I’m using Location-based module to connect the app.
In the WebItem section I’ve set the url ,location ,context ,tooltip ,key ,name and the conditions.

edit 1:
After some R&D , I got to know that we can’t use ‘user_is_admin’ or ‘user_is_sysadmin’ condition in the WebItem’s conditions section. I’ve tested that , conditions did not worked.

@AkshayMehta the Web Item module doesn’t come with a page accessible via /plugins/servlet/ac/. Are you using a Configure Page as well?

Both user_is_admin and user_is_sysadmin are supported everywhere conditions are supported.