Are you in the loop? Keep up with the latest by making sure you're subscribed to Community Announcements. Just click Watch and select Articles.

×
Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Clear value of drop down select list field from an automation rule?

I have to write an automation rule that will clear data from 2 custom (drop down select) fields when the epic is removed from the card/issue and the cards/issues sub-tasks.  

The rule currently will update the card when an Epic is changed, but I now need to expand the rule for when the Epic is removed.

The current rule is: 

When value changes for Parent Link (Any changes to the field value; for Edit issue)

  • Issue Type is one of Story, Spike, Task, Bug, SecurityRisk, Dependency Task, Technical Debt, Improvement, Discovery, Production Support. Sub-task, In-Sprint Defect task
  • THEN edit issue fields 'project', Copy from Parent issue
  • THEN edit issue fields 'work type', copy from Parent issue
  • Branch: For JQL 'parentEpic = {{issue}}
    • THEN edit issue fields 'project', Copy from Parent issue
    • THEN edit issue fields 'work type', copy from Parent issue

1 answer

1 accepted

0 votes
Answer accepted
Bill Sheboy
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.
Oct 18, 2023 • edited

Hi @Ann Rumenapp 

To do that you would need an additional rule, using the generic Issue Updated trigger, followed by a check on the changelog to determine if the parent field was cleared.  Then you could update, as needed.

Here is some information on the changelog to help you create the advanced compare condition you will need: https://support.atlassian.com/cloud-automation/docs/jira-smart-values-issues/#--changelog--

Kind regards,
Bill

My problem is how to clear a drop down select list field.  When I update the fields in a then condition, it makes me select one of the options and doesn't allow me to just clear the field.  Is there JSON code somewhere that does this?

Bill Sheboy
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.
Oct 18, 2023

If you select the multi-select field with Issue Edit and do not select any options, it will clear it.

If instead you need to remove specific values, you may want to use a JSON edit to use "remove" or:

  • expand all of the current values
  • remove the ones, as needed
  • format the result as JSON for a field update

Here is the syntax for the JSON edit: https://support.atlassian.com/cloud-automation/docs/advanced-field-editing-using-json/#Multi-select-custom-field

Suggest an answer

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

Atlassian Community Events