Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.



Code Block
import com.atlassian.jira.component.ComponentAccessor
import com.atlassian.jira.issue.Issue
import com.atlassian.jira.user.ApplicationUser

Issue issueOrigin = ComponentAccessor.getIssueManager().getIssueObject("ISSUE-1")

//// When using this script in the script console uncomment the next line:
Issue issueDestination = ComponentAccessor.getIssueManager().getIssueObject("ISSUE-2")
//// When using this script in a transition uncomment the next line:
//Issue issueDestination = issue

ApplicationUser loggedInUser = ComponentAccessor.jiraAuthenticationContext.getLoggedInUser()
IssuePropertyService issuePropertyService = ComponentAccessor.getComponentOfType(IssuePropertyService.class)

def allProperties = issuePropertyService.getProperties(loggedInUser,
for(def property : allProperties){
        EntityPropertyService.SetPropertyValidationResult result =
            	  new EntityPropertyService.PropertyInput(property.value, property.key))
            issuePropertyService.setProperty(loggedInUser, result)

Installation instructions

  • If used in a transition:

    • Change the issue key in line 7 to the key of the issue you want to copy the forms from.

    • Comment line 10 and uncomment line 12

  • If used in the script console:

    • Change the issue key in line 7 to the key of the issue you want to copy the forms from.

    • Change the issue key in line 10 to the key of the issue you want to copy the forms to.

Possible use cases

This script copies all of the forms, including values which have been entered in form fields, from one issue to another. All related form information such as the current status (open/submitted/locked), format and conditions will be maintained.

This script can be useful for passing information when creating related issues, or child issues. It can also be used in a regular transitions to pass information between teams who are working on a coordinated effort (such as HR, Facilities and IT teams working to onboard new employees).


  • The script will override any forms already on the destination issue. If you do not want to override existing forms on the destination issue, it is recommended that you use the ProForma API for (starting from v1.1.0) for copying forms to another issue.

  • Users performing the action need to have edit issue permissions for both issuespermission to view the source issue and to edit the destination issue.

  • You may need to refresh the destination issue to see the newly added forms.