From 14a3a6073e4610849a0f8e8cae357c1f3ac3b8d3 Mon Sep 17 00:00:00 2001 From: Jake McDermott Date: Mon, 30 Oct 2017 13:37:45 -0400 Subject: [PATCH] append credential types documentation link to help popovers --- .../client/src/credential-types/add/add.controller.js | 10 ++++++++-- .../src/credential-types/edit/edit.controller.js | 10 ++++++++-- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/awx/ui/client/src/credential-types/add/add.controller.js b/awx/ui/client/src/credential-types/add/add.controller.js index bc7e284fd2..8f0842c27d 100644 --- a/awx/ui/client/src/credential-types/add/add.controller.js +++ b/awx/ui/client/src/credential-types/add/add.controller.js @@ -37,8 +37,14 @@ export default ['Rest', 'Wait', callback: 'loadCredentialKindOptions' }); - $scope.inputs_help_text = _.get(options, 'actions.POST.inputs.help_text', "Specification for credential type inputs"); - $scope.injectors_help_text = _.get(options, 'actions.POST.injectors.help_text', "Specification for credential type injector"); + const docs_url = 'https://docs.ansible.com/ansible-tower/latest/html/userguide/credential_types.html#getting-started-with-credential-types'; + const docs_help_text = `

Getting Started with Credential Types`; + + const api_inputs_help_text = _.get(options, 'actions.POST.inputs.help_text', "Specification for credential type inputs."); + const api_injectors_help_text = _.get(options, 'actions.POST.injectors.help_text', "Specification for credential type injector."); + + $scope.inputs_help_text = api_inputs_help_text + docs_help_text; + $scope.injectors_help_text = api_injectors_help_text + docs_help_text; if (!options.actions.POST) { $state.go("^"); diff --git a/awx/ui/client/src/credential-types/edit/edit.controller.js b/awx/ui/client/src/credential-types/edit/edit.controller.js index 42cd0ebadd..a2d35974d2 100644 --- a/awx/ui/client/src/credential-types/edit/edit.controller.js +++ b/awx/ui/client/src/credential-types/edit/edit.controller.js @@ -36,8 +36,14 @@ export default ['Rest', 'Wait', callback: 'choicesReadyCredentialTypes' }); - $scope.inputs_help_text = _.get(options, 'actions.POST.inputs.help_text', "Specification for credential type inputs"); - $scope.injectors_help_text = _.get(options, 'actions.POST.injectors.help_text', "Specification for credential type injector"); + const docs_url = 'https://docs.ansible.com/ansible-tower/latest/html/userguide/credential_types.html#getting-started-with-credential-types'; + const docs_help_text = `

Getting Started with Credential Types`; + + const api_inputs_help_text = _.get(options, 'actions.POST.inputs.help_text', "Specification for credential type inputs."); + const api_injectors_help_text = _.get(options, 'actions.POST.injectors.help_text', "Specification for credential type injector."); + + $scope.inputs_help_text = api_inputs_help_text + docs_help_text; + $scope.injectors_help_text = api_injectors_help_text + docs_help_text; }); }