JSW/JSM DC 9.12.8/5.12.8, ScriptRunner 8.32.0
I have a UI fragment of type "Create Constrained Issue Web Item". The preview show me this:
<web-item key='request-new-analysis' name='ScriptRunner generated web item - request-new-analysis' section='operations-restore' weight='10'>
<label>Request New Analysis</label>
<condition class='script://jiraHelper.project?.key == "TSD" jiraHelper.project.projectCategory.id == 10001 // "Service Desk" && issue.status.id == '10101' // Waiting for Support'>
<param name='£trackingParameters' value='{"scriptName":"com.onresolve.scriptrunner.canned.jira.fragments.CreateConstrainedIssueWebItem"}' />
<param name='£fragmentParameters' value='{"id":"675644f3-3e44-4826-a609-1c4c311fb5ee"}' />
</condition>
<styleClass>sr-create-bound-issue request-new-analysis </styleClass>
<link linkId='request-new-analysis'>https://jira-test/secure/CreateIssue.jspa?pid=10201&issuetype=10403</link>
</web-item>I have a behavior with an initialization script. Here, I test the reason of why the behavior script is called.
If, and only if, the behavior is called because the UI fragment was used, then I see 2 entries in the execution history, just milliseconds apart, even in parallel. All other ways to raise the create issue screen lead only to a single call.
In the HTTP logs I can clearly see that 2 POST requests to the URL as in the UI fragment's preview are issued.
Can anyone explain why the create issue is called twice? How can I prevent this from happening?
Thanks in advance for your replies!
Reinhard