Dear Developers,
We are currently developing a User Delegation Plugin for Jira Data Center 9.12.8, which is also integrated with Jira Service Management (JSM).
In our implementation, users raise delegation requests from the Customer Portal, where they need to select the following details:
-
Delegatee Name
-
Start Date
-
End Date
-
Project Name
Issue Description
We are facing a specific issue with the Delegatee Name user picker:
-
Users with Agent access are able to successfully search and select users from the dropdown.
-
However, users with only Customer access (JSM portal users) are not able to retrieve the user list.
-
For customer users, the dropdown shows “Searching…” indefinitely and does not return any results.
We are currently using the following REST API in our implementation:
AJS.$(".rua-protal-select-delegatee").auiSelect2({
placeholder: "choose user",
minimumInputLength: 2,
ajax: {
url: baseUrl + '/rest/api/2/user/picker',
dataType: 'json',
data: function (term) {
return {
query: term,
showAvatar: true
}
},
results: function (data) {
console.log("************** results data.users", data.users)
return {
results: data.users.map(user => ({ id: user.key, key: user.key, name: user.name, displayName: user.displayName }))
};
}
},
processResults: function (data) {
return {
results: data
};
},
formatResult: function (option) {
return "<div id='" + option.key + "' value='" + option.name + "'>" + option.displayName + "</div>";
},
formatSelection: function (option) {
return "<div class='rua-protal-select-delegatee-selected' id='" + option.key + "' value='" + option.name + "'>" + option.displayName + "</div>";
}
});
This API works correctly for agents but fails for customers in the JSM portal context.
Concern
We would like to understand:
-
Why does
/rest/api/2/user/pickernot work for customer users in JSM? -
Is there any supported approach or API that allows both Agent and Customer users to retrieve a filtered user list (for example, users from a specific group) in the customer portal?
-
What is the recommended best practice for implementing a user picker in JSM Customer Portal apps?
Objective
Our goal is to allow both Agents and Customers to search and select users (filtered by a specific group) during delegation request creation in the portal.
We would appreciate your guidance on the correct or supported approach for this requirement.