Hello. I’m trying to use an AUI Single Select in a Velocity template for a servlet plugin but it doesn’t seem to work. I do not want to activate the AUI component with JS when the page loads; I want to use the native AUI syntax in my Velocity template. Is that possible?
Specifically, I’m pulling in the Priority list using the Jira Server API and want to recreate the Priority dropdown using AUI.
Is my syntax wrong? I couldn’t find examples of how to use AUI like this inside Velocity templates. Developing for Jira Server 8.1.0.
In your atlassian-plugin.xml you are declaring a web resource module which has the resources you want to use. What you need to do is directly reference that web resource which you defined in the atlassian-plugin.xml by the web resource’s key and your plugin key. Just defining the web resource won’t do anything by itself.
Sorry if the way I submitted my code snippets was confusing. I do have the #requireResource("com.atlassian.auiplugin:aui-select") in my Velocity template.
Sorry, let me try to explain more clearly. You are trying to reference a web resource with the key “aui-select” from a plugin with the key “com.atlassian.auiplugin”. You actually want to reference the resource that you yourself created. So replace “com.atlassian.auiplugin” with your plugin key and replace “aui-select” with “form-plugin-resources”.