The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 
  • Community
  • Q&A
  • Jira
  • Questions
  • Automation: Update Checkbox Custom Field with Additional Value (Not clearing what is already there)

Automation: Update Checkbox Custom Field with Additional Value (Not clearing what is already there)

Celina Kincaid
Contributor
May 16, 2024

I have an automation rule that infers what to set for the checkbox field but it is only 'setting' that value and overwrites any existing checked boxes. 

Can I read in any preset values to a variable and then include them in the 'set' rule?  I have tried this using a smart value for a variable and then the new value but the UI doesn't allow this. 

Does anyone have another secret?

Thank you!

3 answers

2 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

1 vote
Answer accepted
Kalyan Sattaluri
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 Champions.
May 16, 2024

Hello @Celina Kincaid 

To update the field, instead of overwriting it, you need go to down to the "Advanced Edit" section and provide the JSON there.

 

{
"update": {
"Multi Select": [{ "add": {"value": "Approval A is set"}}]
}
}

 

Like in below screenshot.

If you have smart value, you can pass that aswell like below..

{
"update": {
"Multi Select": [{ "add": {"value": "{{some_smartvalue}}"}}]
}
}

image.png

Reference:

https://community.atlassian.com/t5/Automation-questions/Update-checkbox-field-select-additional-values-with-automation/qaq-p/2245770

https://support.atlassian.com/cloud-automation/docs/advanced-field-editing-using-json/#:~:text=child%22%3A%20%7B%20%22id%22%20%3A%2010115%20%7D%20%7D-,Multi%2Dselect%20custom%20field,-Select%20multiple%20values

 

Please try and share if issues. Hope it helps. Thanks!

 

 

 

 

1 vote
Answer accepted
Trudy P Claspill
Community Champion
May 16, 2024

Hello @Celina Kincaid 

I think doing something like this with the Advanced JSON Editing option might work, but I haven't tested it.

replace customfield_12345 with your checkbox custom field.

{
    "update": {
        "customfield_12345": [{
                "add": { "value": "option1" }
        }]
    }
}

 I inferred this from the following documentation, looking at examples for setting a Checkbox field and for adding another value to a multiple selection field.

https://support.atlassian.com/cloud-automation/docs/advanced-field-editing-using-json/#Checkbox-custom-field

0 votes
Celina Kincaid
Contributor
May 20, 2024

Thank you both!  That worked perfectly!

DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events