Hi,
I am trying to use lister to clone a ticket when the original ticket is resolved and update the ticket cloned ticket with CF x to CF Y
My current settings are:
condition:
cfValues['Request Type']?.value == 'X'
Additional issue actions:
import com.atlassian.jira.component.ComponentAccessor
import com.atlassian.jira.issue.Issue
import com.atlassian.jira.issue.ModifiedValue
def cf = ComponentAccessor.getCustomFieldManager().getCustomFieldObjectByName("Request Type")
issue.setCustomFieldValue(cf,'Y')
issue.setAssignee(null)
I also tried:
def cf = customFieldManager.getCustomFieldObjects(issue).find {it.name == 'Request Type'}
issue.setCustomFieldValue(cf,'Y')
issue.setAssignee(null)
so the ticket is cloned and the relevant fields are copied but the request type is X and not being modified to Y. It is not even showing up on the cloned ticket so I believe the value is being 'null'...
any idea what I am doing wrong?
thanks,