Hi,
I am using JIRA 7.3.0 server. Two custom field 'Tester' is there in my JIRA and i want to move and make it only one custom field 'Tester'. How can i do by using script runnner?
Thanks,
venky.
How can I copy the value of Release Version (Custom Field) to Fix Version/s (System Field) in create screen?
Could you please help me?
Inset all issue keys to script
import com.atlassian.jira.component.ComponentAccessor import com.atlassian.jira.event.type.EventDispatchOption import com.atlassian.jira.issue.IssueManager import com.atlassian.jira.issue.MutableIssue import com.atlassian.jira.issue.UpdateIssueRequest import com.atlassian.jira.issue.fields.CustomField import com.atlassian.jira.user.ApplicationUser IssueManager issueManager = ComponentAccessor.getIssueManager(); UpdateIssueRequest updateIssueRequest = UpdateIssueRequest.builder().eventDispatchOption(EventDispatchOption.ISSUE_UPDATED).sendMail(false).build(); ApplicationUser curUser = ComponentAccessor.getJiraAuthenticationContext().getUser() CustomField copyFrom = ComponentAccessor.getCustomFieldManager().getCustomFieldObjectByName("copyFromName") CustomField copyTo = ComponentAccessor.getCustomFieldManager().getCustomFieldObjectByName("copyToName") MutableIssue issue; for(String key: getIssuesKeysForUpdate()) { issue = issueManager.getIssueObject(key) issue.setCustomFieldValue( copyTo, issue.getCustomFieldValue(copyFrom)) issueManager.updateIssue( curUser, issue, updateIssueRequest ) } public List<String> getIssuesKeysForUpdate(){ return Arrays.asList( "key-1", "key-2" ) }
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Atlassian Government Cloud has achieved FedRAMP Authorization at the Moderate level! Join our webinar to learn how you can accelerate mission success and move work forward faster in cloud, all while ensuring your critical data is secure.
Register NowOnline forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.