We're testing an upgrade to v9.4 from v8.19, and the custom scripts we have for ScriptRunner scripted fields are no longer rendering on the issue view page.
Our scripts output AJS code to update, for example, the ghx-issues-in-epic-table
In the upgraded JIRA product, when viewing an issue the developer tools are showing the error: "TypeError: AJS.$ is not a function", and the table and field are not displaying as expected.
I have read over the changes in Preparing for JIRA 9.0 documentation but it's not clear to me how this applies to our usage within the ScriptRunner Scripted Fields.
Any help or experience with the same challenges would be much appreciated.
Thanks.
Thanks for the help, we found the solution we were looking for.
Starting with the details on this Preparing for JIRA 9.0 page, and the details outlined here, we tracked down how to add the resourcePhaseCheckpoint.defer option in our script and this has resolved the issue.
ie.
It might be helpful to consult this page: https://bitbucket.org/atlassian/platform-module-usage/wiki/aui.md
And review the AUI dependency change associated with your jira upgrade, then review the AUI changelog. E.g. https://aui.atlassian.com/aui/latest/docs/upgrades/aui-9.html#9.2-to-9.3
Also, from your old and new versions of jira, you can run "AJS.version" in your developer panel to get the specific AUI version used in each.
For example, I'm on Jira 8.20.26 and AUI version is 9.2.3-4dc984d9f
That being said, I don't think there are any changes that would cause AJS.$ to error out.
I'm early in my 9.x exploration (waiting for 9.5 LTS), and I've not encountered this (and I do use some AJS.$ functions). So perhaps a more specific/detailed example would help.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It may also be worth reaching out to the support team at Adaptavist, the ScriptRunner vendor
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.