diff --git a/awx/ui/client/legacy-styles/lists.less b/awx/ui/client/legacy-styles/lists.less index 6aae815332..5f154e2a80 100644 --- a/awx/ui/client/legacy-styles/lists.less +++ b/awx/ui/client/legacy-styles/lists.less @@ -427,6 +427,11 @@ table, tbody { cursor: not-allowed; } +.List-action--notificationAdd { + text-align: right; + font-size: 11px; +} + .List-dropdownButton { border: none; } diff --git a/awx/ui/client/src/notifications/notification-templates-list/add-notifications-action.partial.html b/awx/ui/client/src/notifications/notification-templates-list/add-notifications-action.partial.html new file mode 100644 index 0000000000..af71530737 --- /dev/null +++ b/awx/ui/client/src/notifications/notification-templates-list/add-notifications-action.partial.html @@ -0,0 +1,4 @@ +
+
GO TO NOTIFICATIONS TO
+
ADD A NEW TEMPLATE
+
diff --git a/awx/ui/client/src/notifications/notifications.list.js b/awx/ui/client/src/notifications/notifications.list.js index c836e87476..24e1aa35c7 100644 --- a/awx/ui/client/src/notifications/notifications.list.js +++ b/awx/ui/client/src/notifications/notifications.list.js @@ -8,7 +8,7 @@ * used in the related tabs */ -export default ['i18n', function(i18n){ +export default ['i18n', 'templateUrl', function(i18n, templateUrl){ return { // These tooltip fields are consumed to build disabled related tabs tooltips in the form > add view dataPlacement: 'top', @@ -58,12 +58,8 @@ export default ['i18n', function(i18n){ }, actions: { add: { - label: i18n._('Add Notification'), - mode: 'all', // One of: edit, select, all - ngClick: 'addNotificationTemplate()', - awToolTip: i18n._('Create a new notification template'), - actionClass: 'btn List-buttonSubmit', - buttonContent: '+ ' + i18n._('ADD NOTIFICATION TEMPLATE'), + type: 'template', + template: templateUrl('notifications/notification-templates-list/add-notifications-action'), ngShow: 'current_user.is_superuser || (current_user_admin_orgs && current_user_admin_orgs.length > 0)' } } diff --git a/awx/ui/client/src/shared/list-generator/list-actions.partial.html b/awx/ui/client/src/shared/list-generator/list-actions.partial.html index 026852ef3a..a837b52ef0 100644 --- a/awx/ui/client/src/shared/list-generator/list-actions.partial.html +++ b/awx/ui/client/src/shared/list-generator/list-actions.partial.html @@ -1,6 +1,7 @@ +