Issue type automation

Ahmed Ben Hena May 24, 2024

Hi , I wanted to know if it is possible to create issue types based on input from a custom field ? 

For example , we have a custom field called " Teams involved" , and we want to create an automated child issue based on the teams added to this custom field ; if "Teams involved" = Copy, 3D THEN create "Copy" and "3D" child issues linked to the trigger issue. 

Thanks!

1 answer

1 accepted

0 votes
Answer accepted
Trudy Claspill
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 24, 2024

Hello @Ahmed Ben Hena 

Welcome to the Atlassian community.

1. Do you mean you want to add a new issue of type "Copy", where "Copy" is another type of issue similar to Story, Task, and Bug?

2. Or do you want to add a new issue of some other issue type and add "Copy" as a value in the new issue?

Creating a brand new Issue Type is a very different task then creating a new issue. It is definitely possible to use an Automation Rule to create a new issue using an existing issue type (option 2). It will be more challenging to create an entirely new Issue Type, and then create a new issue of that type (option 1).

Ahmed Ben Hena May 27, 2024

Hello @Trudy Claspill 

Thanks for checking! 

I'm interested in the second option. We have existing issue types and want to leverage a custom field ("Teams Involved") to automatically assign the same value as the issue type. I've attached a screenshot of my attempt for one issue type, but manually repeating this for all types would be inefficient. Is there a way to automate this process using the custom field value to dynamically set the issue type?

Thanks!

teams test.png

Trudy Claspill
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 27, 2024

Based on the image you provided, this is what I think you are trying to do. Let me know if I have this correct.

When an issue is created

And that issue's type is Epic

Then create a new issue

  • The issue type for the new issue is based on the "Teams Involved" field in the Epic

 

Is the new issue supposed to be a child of the Epic?

What type of field is the "Teams Involved" field?

Are the values in the "Teams Involved" field exact matches for the issue type names?

Ahmed Ben Hena May 28, 2024

Hi ! 

Absolutely, that's exactly what we are aiming for! To answer your questions :

  • Yes the new issue type should be a child of the Epic
  • It is a custom field, specifically a select list with predefined options to chose from 
  • And yes, it is an exact match for the issue type names

Thanks!

Trudy Claspill
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 28, 2024

Hello,

You can use the Create Lookup Table action to create a table that uses your selection list values as Keys, associating them with the unique numeric IDs corresponding to the matching issue types.

Example with just one entry.

Screenshot 2024-05-28 at 7.46.01 AM.png

"Task" is a value from my selection list. 10002 is the unique numeric ID that is assigned to the Task issue type in my system.

Notice the text directly below the Lookup table variable name field. That shows you have to access the Values in the table. If the name of your selection list is "My Select List", for example, you would get the Value from the above table corresponding to the option in you selection list using a smart value like this:

{{issueTypeTable.get(issue.My Select List)}}

Note that you can use any name for the Lookup table variable name

Then in your Create Issue action you would use that value to set the Issue Type field. You have to type that smart value into the field, and then click on the area where what you type was mirrored below the entry field.

Screenshot 2024-05-28 at 7.52.02 AM.png

 

To get the unique numeric ID for the issue types you will have to go to the screen where issue types are listed in the Project settings. In Project Settings click on Issues (1), then Types (2), then hover your mouse over the issue type name (3), and the URL that displays at the bottom of the browser window will include the ID for that issue type (4).

Screenshot 2024-05-28 at 7.54.58 AM.png

 

For a Team Managed project the steps are similar, except (1) is "Issue Types" and it takes you straight to the list of issue so step 2 is skipped. Then you simply select the issue type, and in the details for that issue type are displayed. You don't have to hover your mouse over the issue type. And the URL field of the browser window include the ID for the issue type displayed.

Like Bill Sheboy likes this
Ahmed Ben Hena May 29, 2024

Thank you so much @Trudy Claspill . 

That was really helpful ! 

Like Trudy Claspill likes this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
AUG Leaders

Atlassian Community Events