Can a subtask inherit a required field from its parent?

Esther Strom
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 10, 2020

I know that I can have a subtask inherit a value from its parent by using the Copy Field postfunction and choosing the same field name for both source and destination, then choosing Copy from Parent.

transition.pngThis works fine when the field being copied isn't a required field. But the Account field is, for us, required at the time of issue creation, and when I tried to use this postfunction, the create screen for the subtask doesn't automatically select the Account value from the parent.

 

Parent:

parent.png

 

Subtask creation:
subtask.png

How can I accomplish this?

2 answers

2 votes
Parvaneh Zand
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.
April 10, 2020

Hi @Esther Strom ,

First of all, you need to Move Down the Copy field value post function, it should be placed after the "Creates issue originally" function.

Post functions run after a transition is performed and they don't update field on screens automatically.

You can select a value for Account field manually on create issue screen. If this post function is added to the Create Issue transition (Before Open status!), the field will be updated to the new value after creation.

Esther Strom
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 13, 2020

I was told by an actual Atlassian employee that the copy field value postfunction should be in the location I have it; it works correctly for all of our other workflows that use that functionality. 

And we don't want to select a value for the Account field manually; the whole point of this is so that users don't have to select a value manually.

Parvaneh Zand
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.
April 13, 2020

Well, I'm afraid there is no easy solution to your question. I'm using Jira Server and I found a solution using Behaviours module ("Script Runner" add-on), which, unfortunately, is not supported on Cloud.

0 votes
John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 10, 2020

Hi Esther - If Parvaneh does not completely provide a solution for you then you can also do this with Automation For Jira. 

Esther Strom
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 13, 2020

Thanks, John. First, the newly-native automation rules have restrictions on how many executions per month you get. Second, it still doesn't handle populating the selection on the Create screen, which is what we need.

It's kind of silly that there's no existing native function to allow subtasks to inherit field values from their parents.

Abhinandan Shah February 1, 2021

@Esther Strom Hey Esther. Yes, completely agree, inheriting values from parent issue seems like a no-brainer must in subtasks, but I guess it isn't there. Were you able to find a solution to this? I'm in the exact same position right now.

The only solution I can think of is use a different scheme for subtask which doesn't have the required field, well required. But I don't really want to do that.

Esther Strom
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 19, 2021

@Abhinandan Shah we did what you don't want to do: created a separate field config for subtasks that has Account as optional, and separate subtask screens for create and edit. The create screen doesn't display the Account field (so a user doesn't select something on creation and then have it overwritten by the postfunction.)

Abhinandan Shah February 20, 2021

Thanks @Esther Strom 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events