From f2f51ab132248ff3be1ce04016a009c67c9a2cd6 Mon Sep 17 00:00:00 2001 From: Michael Abashian Date: Wed, 2 Mar 2016 09:46:07 -0500 Subject: [PATCH 1/3] Added host case to the GetTargetTitle factory --- awx/ui/client/src/helpers/ActivityStream.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/awx/ui/client/src/helpers/ActivityStream.js b/awx/ui/client/src/helpers/ActivityStream.js index 6a59bee789..acd345cb68 100644 --- a/awx/ui/client/src/helpers/ActivityStream.js +++ b/awx/ui/client/src/helpers/ActivityStream.js @@ -49,6 +49,9 @@ export default case 'schedule': rtnTitle = 'SCHEDULES'; break; + case 'host': + rtnTitle = 'HOSTS'; + break; } return rtnTitle; From b967caedaaa4610e894c3072a9a785e5c67a0b0b Mon Sep 17 00:00:00 2001 From: Michael Abashian Date: Wed, 2 Mar 2016 10:04:23 -0500 Subject: [PATCH 2/3] Strip the extra query params when the user uses the activity stream dropdown nav. --- .../streamDropdownNav/stream-dropdown-nav.directive.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/awx/ui/client/src/activity-stream/streamDropdownNav/stream-dropdown-nav.directive.js b/awx/ui/client/src/activity-stream/streamDropdownNav/stream-dropdown-nav.directive.js index b7c71e338a..2fde904199 100644 --- a/awx/ui/client/src/activity-stream/streamDropdownNav/stream-dropdown-nav.directive.js +++ b/awx/ui/client/src/activity-stream/streamDropdownNav/stream-dropdown-nav.directive.js @@ -42,7 +42,7 @@ export default ['templateUrl', function(templateUrl) { } else { // Attach the taget to the query parameters - $state.go('activityStream', {target: $scope.streamTarget}); + $state.go('activityStream', {target: $scope.streamTarget}, {inherit: false}); } } From 3c85e9e639d3d593ecd3d5e8cacabefee477872b Mon Sep 17 00:00:00 2001 From: Michael Abashian Date: Wed, 2 Mar 2016 10:16:40 -0500 Subject: [PATCH 3/3] Removed reload: true since it's not needed to force a transition when going to the activity stream. Changed the "Dashboard" dropdown to "All Activity." --- .../streamDropdownNav/stream-dropdown-nav.directive.js | 4 ++-- awx/ui/client/src/helpers/ActivityStream.js | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/awx/ui/client/src/activity-stream/streamDropdownNav/stream-dropdown-nav.directive.js b/awx/ui/client/src/activity-stream/streamDropdownNav/stream-dropdown-nav.directive.js index 2fde904199..a589a37a83 100644 --- a/awx/ui/client/src/activity-stream/streamDropdownNav/stream-dropdown-nav.directive.js +++ b/awx/ui/client/src/activity-stream/streamDropdownNav/stream-dropdown-nav.directive.js @@ -15,8 +15,8 @@ export default ['templateUrl', function(templateUrl) { $scope.streamTarget = ($state.params && $state.params.target) ? $state.params.target : 'dashboard'; $scope.options = [ + {label: 'All Activity', value: 'dashboard'}, {label: 'Credentials', value: 'credential'}, - {label: 'Dashboard', value: 'dashboard'}, {label: 'Hosts', value: 'host'}, {label: 'Inventories', value: 'inventory'}, {label: 'Inventory Scripts', value: 'inventory_script'}, @@ -38,7 +38,7 @@ export default ['templateUrl', function(templateUrl) { if($scope.streamTarget && $scope.streamTarget == 'dashboard') { // Just navigate to the base activity stream - $state.go('activityStream', {}, {inherit: false, reload: true}); + $state.go('activityStream', {}, {inherit: false}); } else { // Attach the taget to the query parameters diff --git a/awx/ui/client/src/helpers/ActivityStream.js b/awx/ui/client/src/helpers/ActivityStream.js index acd345cb68..05171b2bdc 100644 --- a/awx/ui/client/src/helpers/ActivityStream.js +++ b/awx/ui/client/src/helpers/ActivityStream.js @@ -16,7 +16,7 @@ export default function () { return function (target) { - var rtnTitle = 'DASHBOARD'; + var rtnTitle = 'ALL ACTIVITY'; switch(target) { case 'project':