-
Type:
Bug
-
Resolution: Fixed
-
Priority:
Medium
-
Affects Version/s: 4.5.2, 4.7.1
-
Component/s: API - Front end, Documentation (Developer), Plugin Development
-
None
-
Environment:
Atlassian plugins SDK v 6.2.2 with BB server 4.5.2 and 4.7.1
In the developer documentation at https://developer.atlassian.com/bitbucket/server/docs/latest/reference/api-changelog.html#Pull_request_toolbar_plugins_moved_and_deprecated , the recommended upgrade path for plugins using bitbucket.pull-request.toolbar.actions is to convert the relevant web-item to a client-web-item and stick it under bitbucket.pullrequest.action .
This does not work. A client-web-item with location bitbucket.pullrequest.action does not show up on the list of pull request actions, but one with location bitbucket.branch.list.actions.dropdown shows up in the list of branch actions. The location bitbucket.pullrequest.action also shows up with ?web.items so it's definitely valid, but something else is going wrong ![]()
Here's the atlassian-plugin.xml I used:
<atlassian-plugin key="${atlassian.plugin.key}" name="${project.name}" plugins-version="2">
<plugin-info>
<description>${project.description}</description>
<version>${project.version}</version>
<vendor name="${project.organization.name}" url="${project.organization.url}" />
<param name="plugin-icon">images/pluginIcon.png</param>
<param name="plugin-logo">images/pluginLogo.png</param>
</plugin-info>
<!-- add our i18n resource -->
<resource type="i18n" name="i18n" location="bug"/>
<!-- add our web resources -->
<web-resource key="bug-resources" name="bug Web Resources">
<dependency>com.atlassian.auiplugin:ajs</dependency>
<resource type="download" name="bug.css" location="/css/bug.css"/>
<resource type="download" name="bug.js" location="/js/bug.js"/>
<resource type="download" name="images/" location="/images"/>
<context>bug</context>
</web-resource>
<client-web-item key="branch-item" name="A branch item" section="bitbucket.branch.list.actions.dropdown" weight="100">
<label>Branch item</label>
<link>/plugins/servlet/branch</link>
</client-web-item>
<client-web-item key="pull-request-action-item" name="A pull request item" section="bitbucket.pullrequest.action" weight="100">
<label>Pull request</label>
<link>/plugins/servlet/pullrequest</link>
</client-web-item>
</atlassian-plugin>
It can be easily reproduced with a pull request and looking at the other actions, and looking at the branch operations dropdown for comparison.