diff --git a/awx/ui/static/js/helpers/Groups.js b/awx/ui/static/js/helpers/Groups.js index c9ca93508f..492241a776 100644 --- a/awx/ui/static/js/helpers/Groups.js +++ b/awx/ui/static/js/helpers/Groups.js @@ -259,7 +259,8 @@ angular.module('GroupsHelper', [ 'RestServices', 'Utilities', 'ListGenerator', ' $('#source_form').addClass('squeeze'); } if(scope.source.value==="custom"){ - invUrl = GetBasePath('inventory_scripts'); + // need to filter the possible custom scripts by the organization defined for the current inventory + invUrl = GetBasePath('inventory_scripts') + '?organization='+scope.$parent.inventory.organization; LookUpInit({ url: invUrl, scope: scope,