I'm using Jira Cloud and Advanced Roadmaps. I have the Team field set up and I use it to filter work items and display them on boards. We have two teams working in a single Jira project.
I want to use Scriptrunner Behaviours to show/hide various fields when the Team field has a specific team selected. So far, I can show/hide fields with a change to any field EXCEPT the Team field. I'm doing this to show or hide a field successfully:
logger.info('Debugging : Script for behaviour Team Change is running');
const ticketIMXField = getFieldById('customfield_12335');
const teamField = getFieldById('customfield_12405');
{
switch (teamField.getValue().value) {
case 'Front of House':
ticketIMXField.setVisible(false);
break;
case 'QA Team':
ticketIMXField.setVisible(true);
}logger.info(teamField.getName())
logger.info(teamField.getValue().value)
}
When I try to use the Team field in line in place of 'customfield_12405', I get errors like this:
Looking at the field in the Jira API, I see it has a type of 'team'. I'm not sure what to try next to solve this issue.
Hi Drew,
I can confirm that Behaviours in Jira cloud only support the field types documented on this page.
Unfortunately, Advanced Roadmaps fields are not supported, as behaviours only support the standard Jira custom field types documented in the page above.
This means you will not be able to write a behaviour based on the Teams field.
I hope this helps.
Regards,
Kristian
Hi Kristian, thank you for the quick response! Do you happen to know if this is being worked on, or if there is a feature request I can vote on for this?
- Drew Nedderman
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
HI Drew,
We have a feature request board located here that you can raise your use case to, so the product owners see it.
The field's behaviour support is the one Atlassian supports in the UI Modifications API, which it uses, so Atlassian would need to support these before they could be added to behaviours.
Regards,
Kristian
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Kristian, thank you for the information. I contacted Atlassian support, and they pointed me to this feature suggestion for supporting the Team field in Jira Automation. They noted that once Jira Automation is updated, it will also be accessible via the UI Modifications API.
https://jira.atlassian.com/browse/AUTO-525
Thank you!
- Drew Nedderman
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you for this, Drew. Once it is supported in UI Modifications, then we will look to add support for it in Behaviours.
Regards,
Kristian
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.