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: 

About validation against custom fields for label attributes

青山 明
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.
October 4, 2022

I want to validate field values during transitions in jira service management workflows. Field value validation uses regular expression checking. However, it seems that validation cannot be set for custom fields with label attributes. Is it not possible to set it? If not possible, is there any other way if I want to validate custom field value for label attribute?

1 answer

1 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
Nic Brough -Adaptavist-
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.
October 4, 2022

Labels are not simple strings, they're effectively handled as options - that is the data in the database for them is not a string, but an identifier for an object that has a display/search name (the label the users have entered).  The regex validator is looking at the object, not the name of it when you apply it to labels.

You'll need to write code to do validation of labels.

青山 明
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.
October 4, 2022

In conclusion, is it not possible to check the value of a custom field in the label attribute in the optional validation of the workflow?

Nic Brough -Adaptavist-
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.
October 4, 2022

Not with the validator you are using, you'll need to find or write something that can work with labels.

青山 明
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.
October 4, 2022

I am asking whether it is possible to check the input value to the label attribute custom field. How is it?

Nic Brough -Adaptavist-
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.
October 4, 2022

Yes it is, as I said before.

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

Atlassian Community Events