1
0
mirror of https://github.com/ansible/awx.git synced 2024-10-31 23:51:09 +03:00

Merge pull request #137 from mabashian/7361-group-navigation

Take the user to a groups groups tab when clicked from a groups list
This commit is contained in:
Michael Abashian 2017-08-02 10:23:56 -04:00 committed by GitHub
commit 29c5ec7787
8 changed files with 19 additions and 4 deletions

View File

@ -56,6 +56,10 @@
$state.go('inventories.edit.groups.edit', {inventory_id: $scope.inventory_id, group_id: id});
};
$scope.goToGroupGroups = function(id){console.log();
$state.go('inventories.edit.groups.edit.nested_groups', {inventory_id: $scope.inventory_id, group_id: id});
};
$scope.associateGroup = function() {
$state.go('.associate', {inventory_id: $scope.inventory_id});
};

View File

@ -30,7 +30,7 @@ export default ['i18n', function(i18n) {
name: {
label: i18n._('Groups'),
key: true,
ngClick: "editGroup(group.id)",
ngClick: "goToGroupGroups(group.id)",
columnClass: 'col-lg-6 col-md-6 col-sm-6 col-xs-6',
class: 'InventoryManage-breakWord',
}

View File

@ -31,7 +31,7 @@
name: {
label: i18n._('Groups'),
key: true,
ngClick: "editGroup(group.id)",
ngClick: "goToGroupGroups(group.id)",
columnClass: 'col-lg-6 col-md-6 col-sm-6 col-xs-6',
class: 'InventoryManage-breakWord',
}

View File

@ -84,6 +84,9 @@
$scope.editGroup = function(id){
$state.go('inventories.edit.groups.edit', {group_id: id});
};
$scope.goToGroupGroups = function(id){
$state.go('inventories.edit.groups.edit.nested_groups', {group_id: id});
};
$scope.deleteGroup = function(group){
$scope.toDelete = {};
angular.extend($scope.toDelete, group);

View File

@ -128,6 +128,10 @@
$state.go('inventories.edit.groups.edit', {group_id: id});
};
$scope.goToGroupGroups = function(id){
$state.go('inventories.edit.groups.edit.nested_groups', {group_id: id});
};
var cleanUpStateChangeListener = $rootScope.$on('$stateChangeSuccess', function(event, toState, toParams) {
if (toState.name === "inventories.edit.groups.edit.nested_groups.edit") {
$scope.rowBeingEdited = toParams.group_id;

View File

@ -31,7 +31,7 @@
name: {
label: i18n._('Groups'),
key: true,
ngClick: "editGroup(nested_group.id)",
ngClick: "goToGroupGroups(nested_group.id)",
columnClass: 'col-lg-6 col-md-6 col-sm-6 col-xs-6',
class: 'InventoryManage-breakWord',
}

View File

@ -118,6 +118,10 @@
$state.go('inventories.edit.groups.edit', {group_id: id});
};
$scope.goToGroupGroups = function(id){
$state.go('inventories.edit.groups.edit.nested_groups', {group_id: id});
};
$scope.setAdhocPattern = function(){
var pattern = _($scope.groupsSelected)
.map(function(item){

View File

@ -31,7 +31,7 @@
name: {
label: i18n._('Groups'),
key: true,
ngClick: "editGroup(nested_group.id)",
ngClick: "goToGroupGroups(nested_group.id)",
columnClass: 'col-lg-6 col-md-6 col-sm-6 col-xs-6',
class: 'InventoryManage-breakWord',
}