You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
Next: Root
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
The Atlassian Community can help you and your team get more value out of Atlassian products and practices.
def customFieldManager = ComponentAccessor.getCustomFieldManager()
def emailField = customFieldManager.getCustomFieldObjectByName("Email du client")
def clientEmail = issue.getCustomFieldValue(emailField)
Hi @ghalia sidi amemou , and Welcome
This error "variable CustomFieldManager mask a binding variable of the same name" means that you have already defined a variable with the name "customFieldManager" earlier in your code, and you are trying to redefine it again in the current block of code.
To resolve this issue, you can try changing the name of one of the variables.
def cfManager = ComponentAccessor. getCustomFieldManager()
And then use cfManager instead of customFieldManager in the following lines of code.
Or, just use the customFieldManager provided by the binding, and don't try to override it because that is of no use other than to execute more code for no benefit.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Radek Dostál I agree, this is also better than my solution, 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.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.