Hi all:
We are experiencing an issue in a Jira Server. We are trying to style a list customfield with aui-select2. To do that, we have added to the customfield description the following code:
<script type="text/javascript">
AJS.$("#customfield_10201").auiSelect2();
</script>
On a local Jira server with version 7.12.1, without any plugin, this code works fine but in a production Jira server, with version 7.11.2 it fails and shows the following error:
Uncaught TypeError: AJS.$(...).auiSelect2 is not a function
I've checked in the production environment that the Atlassian UI plugin is installed and enabled.
The AJS version is 7.9.0
Looking for a solution we've found that some users proprose to add the following code to a velocity template:
<span>$webResourceManager</span><span>.</span><span>requireResource</span><span>(</span><span>"com.atlassian.auiplugin:aui-select2"</span><span>)</span>
but, why is it working on our dev instance wihtout doing anything but not in our production instance?
Regards!