From 945916b29c5b0f13ef5fdb962a21583cb648f6d8 Mon Sep 17 00:00:00 2001 From: John Mitchell Date: Fri, 8 Jan 2016 16:14:28 -0500 Subject: [PATCH] updates to list indicator --- awx/ui/client/src/app.js | 6 ++++-- .../src/shared/list-generator/list-generator.factory.js | 6 +++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/awx/ui/client/src/app.js b/awx/ui/client/src/app.js index 2ef538b4fc..96339eaafa 100644 --- a/awx/ui/client/src/app.js +++ b/awx/ui/client/src/app.js @@ -1063,10 +1063,12 @@ var tower = angular.module('Tower', [ var list = $location.$$path.split("/")[1]; var id = $location.$$path.split("/")[2]; - delete $rootScope.listBeingEdited - delete $rootScope.rowBeingEdited + delete $rootScope.listBeingEdited; + delete $rootScope.rowBeingEdited; $rootScope.$broadcast("EditIndicatorChange", list, id); + } else { + $rootScope.$broadcast("RemoveIndicator"); } // this line removes the query params attached to a route diff --git a/awx/ui/client/src/shared/list-generator/list-generator.factory.js b/awx/ui/client/src/shared/list-generator/list-generator.factory.js index b730704bf1..cfb2238b03 100644 --- a/awx/ui/client/src/shared/list-generator/list-generator.factory.js +++ b/awx/ui/client/src/shared/list-generator/list-generator.factory.js @@ -175,7 +175,11 @@ export default ['$location', '$compile', '$rootScope', 'SearchWidget', 'Paginate this.scope.$on("EditIndicatorChange", function(e, list, id) { e.targetScope.listBeingEdited = list; e.targetScope.rowBeingEdited = id; - console.log(list, id); + }); + + this.scope.$on("RemoveIndicator", function(e) { + delete e.targetScope.listBeingEdited; + delete e.targetScope.rowBeingEdited; }); this.scope.isHiddenByOptions = function(options) {