From 145d9bb7583867ea18591e0602c22db781801cd3 Mon Sep 17 00:00:00 2001 From: Leigh Johnson Date: Fri, 8 Jul 2016 10:11:43 -0400 Subject: [PATCH] update tooltips in job list on status change, resolves #2811 --- awx/ui/client/src/helpers/Jobs.js | 7 +++++++ awx/ui/client/src/lists/AllJobs.js | 3 ++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/awx/ui/client/src/helpers/Jobs.js b/awx/ui/client/src/helpers/Jobs.js index 5be8d23d06..28727b700e 100644 --- a/awx/ui/client/src/helpers/Jobs.js +++ b/awx/ui/client/src/helpers/Jobs.js @@ -231,6 +231,12 @@ export default search_params = params.searchParams, spinner = (params.spinner === undefined) ? true : params.spinner, key; + var buildTooltips = function(data){ + data.forEach((val) => { + val.status_tip = 'Job ' + val.status + ". Click for details."; + }); + }; + GenerateList.inject(list, { mode: 'edit', id: id, @@ -260,6 +266,7 @@ export default scope.$on('PostRefresh', function(){ JobsControllerInit({ scope: scope, parent_scope: parent_scope }); JobsListUpdate({ scope: scope, parent_scope: parent_scope, list: list }); + buildTooltips(scope.jobs); parent_scope.$emit('listLoaded'); }); diff --git a/awx/ui/client/src/lists/AllJobs.js b/awx/ui/client/src/lists/AllJobs.js index 04bbaad493..955d239dc4 100644 --- a/awx/ui/client/src/lists/AllJobs.js +++ b/awx/ui/client/src/lists/AllJobs.js @@ -21,7 +21,8 @@ export default label: '', searchLabel: 'Status', columnClass: 'col-lg-1 col-md-1 col-sm-2 col-xs-2 List-staticColumn--smallStatus', - awToolTip: "Job {{ all_job.status }}. Click for details.", + dataTipWatch: 'all_job.status_tip', + awToolTip: "{{ all_job.status_tip }}", awTipPlacement: "right", dataTitle: "{{ all_job.status_popover_title }}", icon: 'icon-job-{{ all_job.status }}',