* Fix bug #22064#22065.

This commit is contained in:
mayue
2022-04-28 06:43:05 +00:00
parent 8d8b999608
commit aeda6fbe78
4 changed files with 56 additions and 5 deletions
+27 -1
View File
@@ -352,7 +352,14 @@ function loadExecutionRelated(executionID)
$('#taskIdBox').innerHTML = '<select id="task"></select>'; // Reset the task.
loadProductStories(currentProductID);
loadTestTasks(currentProductID);
loadProjectTeamMembers(currentProjectID);
if(typeof(currentProjectID) == 'undefined')
{
loadProductMembers(currentProductID);
}
else
{
loadProjectTeamMembers(currentProjectID);
}
currentProjectID != 0 ? loadProjectBuilds(currentProjectID) : loadProductBuilds(currentProductID);
}
@@ -482,6 +489,25 @@ function loadExecutionBuilds(executionID, num)
}
}
/**
* Load product members.
*
* @param productID
* @access public
* @return void
*/
function loadProductMembers(productID)
{
link = createLink('bug', 'ajaxGetProductMembers', 'productID=' + productID + '&selectedUser=' + $('#assignedTo').val());
$.get(link, function(data)
{
if(!data) data = '<select id="assignedTo" name="assignedTo" class="form-control"></select>';
$('#assignedTo').replaceWith(data);
$('#assignedTo_chosen').remove();
$("#assignedTo").chosen();
});
}
/**
* Load project members.
*