Merge pull request #80 from ansible/teams_error

fix of the teams list console errors
This commit is contained in:
jlmitch5
2015-02-18 16:28:56 -05:00

View File

@@ -202,6 +202,7 @@ export function TeamsEdit($scope, $rootScope, $compile, $location, $log, $routeP
} }
$scope.teamLoadedRemove = $scope.$on('teamLoaded', function () { $scope.teamLoadedRemove = $scope.$on('teamLoaded', function () {
CheckAccess({ scope: $scope }); CheckAccess({ scope: $scope });
if ($scope.organization_url) {
Rest.setUrl($scope.organization_url); Rest.setUrl($scope.organization_url);
Rest.get() Rest.get()
.success(function (data) { .success(function (data) {
@@ -216,6 +217,11 @@ export function TeamsEdit($scope, $rootScope, $compile, $location, $log, $routeP
for (var set in relatedSets) { for (var set in relatedSets) {
$scope.search(relatedSets[set].iterator); $scope.search(relatedSets[set].iterator);
} }
} else {
$scope.organization_name = "";
master.organization_name = "";
Wait('stop');
}
}); });
// Retrieve detail record and prepopulate the form // Retrieve detail record and prepopulate the form