Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Deleted user
0 / 0 points
Next:
badges earned

Your Points Tracker
Challenges
Leaderboard
  • Global
  • Feed

Badge for your thoughts?

You're enrolled in our new beta rewards program. Join our group to get the inside scoop and share your feedback.

Join group
Recognition
Give the gift of kudos
You have 0 kudos available to give
Who do you want to recognize?
Why do you want to recognize them?
Kudos
Great job appreciating your peers!
Check back soon to give more kudos.

Past Kudos Given
No kudos given
You haven't given any kudos yet. Share the love above and you'll see it here.

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Is there a way to add a context value from automation?

So I have a project that a stakeholder wants to edit the summary and then that would then add a context value to a custom field drop down.

So example I edit the summary to Business name A and this then would create a new context field value for custom field drop down"Example drop down"

Does anyone know if this is possible with? Automation for Jira/ Scriptrunner etc?

2 answers

1 accepted

1 vote
Answer accepted

As far as i understand, you want to add a specific value to a customfield, when the summary of an issue is edited to contain a certain phrase (business name).

You should be able to achieve this with Automation for Jira with a rule containing the following:

Trigger: Field Value Changed (Summary)
If Condition: Issue Fields Condition (Summary equals/contains "specific business name")
Action: Edit Issue (Context Field, set to the needed value)

If the above fails, you might need place "Re-fetch Issue Data" action after the Trigger, to make sure the issue details have been saved correctly before the condition checks the Summary value. 

Note that if you have several specific business names you need to automatically set custom field values for, you can either branch out the rule with more conditions, or you can create separate rules for each business name.

I thought that this is what I needed to do and in the past I did this but couldn't remember. Thank you so much for the guidance. I appreciate the help.

Like Jakob KN likes this

@Jakob KNCan this be used to create a new value context that doesn't exist in the context value now when the summary is edited?

Summary says Business A but then edited to Business D, Business A is in the custom field drop down as a value but Business D is not. Will it add Business D as a new context value in the custom field drop down?

It's not possible to create new values for a dropdown custom field through automation. 
You can only make the automation rule choose from the values that already exist. 

If you expect many different values, you could instead use a single line text field to minimize administrative overhead of adding new options to the custom field. 

Like Aaron Geister likes this

That is what I thought. With script runner it can create new value though correct? Just not with Automation for Jira?

I'm not a 100% sure if it's possible with scriptrunner, but it could very well be, since Scriptrunner is extremely versatile. 

If you manage this with scriptrunner, you'll however risk that duplicates are added to the field, such as:
-Business A / Busness A
-Business B / Business-B
-Business C / Business C QA tasks

Duplicates could be cause either by typo's, variations in naming, or if there's extra info in the summary either before or after the business name. 

(of course, with automation for Jira, you'll still have a risk that the value in the custom field isn't set automatically, if the user misspells the business name)

Like Aaron Geister likes this

Yes, I agree with your thought. We have now refrained from doing this by automation and making this a manual task as it would be safer and prevent mistakes. It would be nice if we could add context to drop down by automation but I see the issue with doing so.

Thanks again and you logic and guidance is valued.

Like Jakob KN likes this

Click the Actions icon (the three parallel lines) and select Admin -> Context Type . Click the Actions menu (the vertical ellipsis) for the Terraform_Namespace and select Add Context Value. Enter an ID and Name for the new context value.

 

MyAARPMedicare

@Sines ParkerI know how to change the context value in Jira what I am asking is if we can do that by automation from another field like "Summary". Example Summary is edited for a new context like Business A. Then when the field is edited with the name Business A then it will change the context value of a Customer field drop down and add this value to that drop down.

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Jira Service Management

ThinkTilt is joining the Atlassian Family!

This morning, Atlassian announced the acquisition of ThinkTilt , the maker of ProForma, a no-code/low code form builder with 700+ customers worldwide. ThinkTilt helps IT empower any team in their or...

852 views 30 33
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you