From a26a4326ba1784f2393e6cfce9728fb1ea772f55 Mon Sep 17 00:00:00 2001 From: Jared Tabor Date: Wed, 22 Jun 2016 13:41:50 -0700 Subject: [PATCH] Fixing add notificaiton template button for mgmt jobs --- .../notifications/notification.controller.js | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/awx/ui/client/src/management-jobs/notifications/notification.controller.js b/awx/ui/client/src/management-jobs/notifications/notification.controller.js index 0fed968d24..68bbfa7baa 100644 --- a/awx/ui/client/src/management-jobs/notifications/notification.controller.js +++ b/awx/ui/client/src/management-jobs/notifications/notification.controller.js @@ -19,11 +19,24 @@ export default var scope = $rootScope.$new(), url = GetBasePath('notification_templates'), defaultUrl = GetBasePath('system_job_templates'), - list = NotificationsList, + list, view = GenerateList, id = $stateParams.management_id; + list = _.cloneDeep(NotificationsList); + delete list.actions.add; list.listTitle = `${management_job.name}
Notifications`; + list.searchSize = "col-lg-12 col-md-12 col-sm-12 col-xs-12"; + list.searchRowActions = { + add: { + label: 'Add Notification', + mode: 'all', // One of: edit, select, all + ngClick: 'addNotificationTemplate()', + awToolTip: 'Create a new notification template', + actionClass: 'btn List-buttonSubmit', + buttonContent: '+ ADD NOTIFICATION TEMPLATE' + } + }; view.inject( list, { mode: 'edit', cancelButton: true,