Dynamically populate options in customfield type plugin (velocity template) on click of a button

Hi All,

I have a text field - user id  and i have created custom field type field plugin(Generic CF Type) - User Name

fetchUserNames.png


My requirement is to dynamically populate the options of a custom field User Name based on the value of a custom field User Id on click of a button Search available in the edit  velocity template of User Name field.

The custom field type plugin module populates the values on time of load of the screen,but not at run time when the user id is changed and search button is clicked. The search button should call a method in Java class which returns list of String objects.

 

I have read the following post -https://answers.atlassian.com/questions/153603 but could not find the solution.

Thanks 

Kapil

1 answer

1 accepted

Accepted Answer
0 votes

I have achieved this exposing REST service in the plugin and do an ajax call of the REST service in velocity file of that customfield

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Sep 18, 2018 in Jira

What modern development practices are at the heart of how your team delivers software?

Hey Community mates! Claire here from the Software Product Marketing team. We all know software development changes rapidly, and it's often tough to keep up. But from our research, we've found the h...

25,041 views 2 7
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you