I have a JMWE Field Required Validator in a workflow that successfully requires a user to provide a field if the value of another field is true. This field is a simple select dropdown with Yes and No.
In the same workflow I have two post functions that uses the same code to determine whether to Copy Issue Fields from another issue, and a Create Issue post function. This returns false. This Nunjucks code is identical except for the necessity of providing {{. What am I doing wrong?
The syntax is different between post functions and conditions/Validators, because the latter are limited to Atlassian's Jira expressions.
You can use the Issue Fields help tab of the editor to find out how to access your field from Nunjucks.
I followed your advice, and yes it led me to the fact that I needed the fields part
{{ issue.fields.customfield_20423.value == "Yes" }}
So I'm accepting this answer.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Try
{{ issue.fields.customfield_20423 == "Yes" }}
in the nunchuck condition
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I saw @David Fischer 's answer first, but this was definitely the right direction. However, it didnt work because I would still need the .value on the end. I probably would have worked it out from your answer tho as I'd already stated the suffix in my attempt. Thanks!
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.