mirror of
https://github.com/ansible/awx.git
synced 2026-01-15 03:40:42 -03:30
PR feedback implemented.
This commit is contained in:
parent
ec2e5a0224
commit
07ab1e7787
@ -437,10 +437,10 @@ angular.module('HostsHelper', [ 'RestServices', 'Utilities', listGenerator.name,
|
||||
|
||||
.factory('HostsEdit', ['$rootScope', '$location', '$log', '$stateParams', 'Rest', 'Alert', 'HostForm', 'GenerateForm',
|
||||
'Prompt', 'ProcessErrors', 'GetBasePath', 'HostsReload', 'ParseTypeChange', 'Wait', 'Find', 'SetStatus', 'ApplyEllipsis',
|
||||
'ToJSON', 'ParseVariableString', 'CreateDialog', 'TextareaResize', 'ParamPass',
|
||||
'ToJSON', 'ParseVariableString', 'CreateDialog', 'TextareaResize',
|
||||
function($rootScope, $location, $log, $stateParams, Rest, Alert, HostForm, GenerateForm, Prompt, ProcessErrors,
|
||||
GetBasePath, HostsReload, ParseTypeChange, Wait, Find, SetStatus, ApplyEllipsis, ToJSON,
|
||||
ParseVariableString, CreateDialog, TextareaResize, ParamPass) {
|
||||
ParseVariableString, CreateDialog, TextareaResize) {
|
||||
return function(params) {
|
||||
|
||||
var parent_scope = params.host_scope,
|
||||
|
||||
@ -142,7 +142,7 @@ function copyHostsDirectiveController($compile, $state, $scope, Rest, ProcessErr
|
||||
setWidgets: false
|
||||
});
|
||||
$scope.refreshHostsOnGroupRefresh = true;
|
||||
}
|
||||
};
|
||||
|
||||
var performCopy = function() {
|
||||
var list = GroupList,
|
||||
@ -229,9 +229,10 @@ function copyHostsDirectiveController($compile, $state, $scope, Rest, ProcessErr
|
||||
copy_choice: copy_choice,
|
||||
name: name,
|
||||
cancel: cancel,
|
||||
allowSave: allowSave
|
||||
})
|
||||
};
|
||||
allowSave: allowSave,
|
||||
performCopy: performCopy
|
||||
});
|
||||
}
|
||||
|
||||
export default ['$compile', '$state', '$scope', 'Rest', 'ProcessErrors', 'CreateDialog', 'GetBasePath', 'Wait', 'generateList', 'GroupList', 'SearchInit',
|
||||
'PaginateInit', 'ParamPass', 'Store', copyHostsDirectiveController
|
||||
|
||||
@ -400,16 +400,12 @@ function InventoriesManage($log, $scope, $rootScope, $location,
|
||||
|
||||
$scope.copyGroup = function(id) {
|
||||
PreviousSearchParams = Store('group_current_search_params');
|
||||
// GroupsCopy({
|
||||
// scope: $scope,
|
||||
// group_id: id
|
||||
// });
|
||||
var params = {
|
||||
scope: $scope
|
||||
}
|
||||
ParamPass.set(params);
|
||||
$location.search('groups', null);
|
||||
$state.go('inventoryManage.copy.group', {group_id: id});
|
||||
var params = {
|
||||
scope: $scope
|
||||
};
|
||||
ParamPass.set(params);
|
||||
$location.search('groups', null);
|
||||
$state.go('inventoryManage.copy.group', {group_id: id});
|
||||
};
|
||||
|
||||
$scope.deleteGroup = function (id) {
|
||||
@ -433,7 +429,7 @@ function InventoriesManage($log, $scope, $rootScope, $location,
|
||||
host_id: null,
|
||||
selected_group_id: $scope.selected_group_id,
|
||||
inventory_id: $scope.inventory.id
|
||||
}
|
||||
};
|
||||
ParamPass.set(params);
|
||||
$state.go('inventoryManage.addHost');
|
||||
};
|
||||
@ -445,7 +441,7 @@ function InventoriesManage($log, $scope, $rootScope, $location,
|
||||
mode: 'edit',
|
||||
host_id: host_id,
|
||||
inventory_id: $scope.inventory.id
|
||||
}
|
||||
};
|
||||
ParamPass.set(params);
|
||||
$state.go('inventoryManage.editHost', {host_id: host_id});
|
||||
};
|
||||
@ -461,17 +457,11 @@ function InventoriesManage($log, $scope, $rootScope, $location,
|
||||
|
||||
hostScope.copyHost = function(id) {
|
||||
PreviousSearchParams = Store('group_current_search_params');
|
||||
// HostsCopy({
|
||||
// group_scope: $scope,
|
||||
// host_scope: hostScope,
|
||||
// host_id: id
|
||||
// });
|
||||
|
||||
var params = {
|
||||
group_scope: $scope,
|
||||
host_scope: hostScope,
|
||||
host_id: id
|
||||
}
|
||||
};
|
||||
|
||||
ParamPass.set(params);
|
||||
|
||||
|
||||
@ -99,7 +99,6 @@ function manageHostsDirectiveController($rootScope, $location, $log, $stateParam
|
||||
scope: scope,
|
||||
field_id: 'host_variables',
|
||||
});
|
||||
//scope.$emit('hostVariablesLoaded');
|
||||
scope.parseType = 'yaml';
|
||||
ParseTypeChange({
|
||||
scope: scope,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user