Hello,
here is the rule that I am running. It is not working, and Rule automation audit logs show success.
Scenario - User is populating the custom field to populated custom field 1 and based on it, i would like to populate custom field 2.
The rule runs perfectly fine however the custom field 2 does not get populated.
Any help in this regard is greatly appreciated.
{
"trigger": {
"type": "issue_created"
},
"condition": {
"type": "field_condition",
"field": "customfield_1",
"operator": "equals",
"value": "Service 1"
},
"action": {
"type": "edit_issue",
"fields": {
"customfield_2": [
{
"Value": "Team 1"
}
]
}
}
}
Here is the output -
Hi @Umesh Kulkarni,
It is hard to tell what is wrong by the information you are providing. But if your custom field 2 really is the team custom field I think it is, then very likely the value "Team 1" is not a correct value for that field.
If you perform a JQL search for all issues having the Team field filled out, you might see that the team name gets converted into a long sort of hashed code, which is the actual value you would need to fill out.
Hope this helps!
Thanks for taking a look. I tried with the hashed code but that did not work.
Please let me know what more information can help check this issue further.
here are current details -
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Before anything else, @Umesh Kulkarni: why are you trying to use json in the additional fields instead of using the simple editor:
And, secondly, if the field you are trying to set were an unsupported field, why are you including trigger and condition settings in your json? These are already in your rule, I would assume. Normal syntax to set a value for a field would be something like this:
{
"fields": {
"Custom Field Name": {
"value": "red"
}
}
}
I would recommend only to revert to the advanced json syntax if you can't find your field under the list of supported fields.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for your continued support.
I gave a try to use additional fields because the usual way did not work. I am using custom fields as mentioned in my earlier post and i kept getting validation errors like shown in the screenshot below. This query does work well when searched from within "Assets" but JIRA rule automation gives error.
for this input it gave error - (data was not an array (Team))
{
"fields": {
"Custom Field Name": {
"value": "red"
}
}
}
so instead I used the below earlier, but it gives same behavior that is the rule runs successfully however the issue is not edited.
{
"fields": {
"customfield_2": [{
"value": "Tried putting here the value as well as hashed id"
}
]
}
}
Any further guidance is much appreciated.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.