From d8356d0b4db625fb7165ac01eb4d8c1765306e84 Mon Sep 17 00:00:00 2001 From: Coleman Watts Date: Tue, 17 Mar 2015 15:47:07 -0400 Subject: [PATCH] CRM-15706 - Add help to various MailingUI fields --- js/angular-crm-ui.js | 5 +- js/angular-crmMailing/directives.js | 2 +- js/angular-crmMailingAB/directives.js | 1 + partials/crmMailing/headerFooter.html | 4 +- partials/crmMailing/mailing.html | 2 +- partials/crmMailing/summary.html | 4 +- partials/crmMailingAB/joint-mailing.html | 6 +-- partials/crmMailingAB/setup.html | 4 +- templates/CRM/Mailing/MailingUI.hlp | 62 ++++++++++++++++++++++++ 9 files changed, 77 insertions(+), 13 deletions(-) create mode 100644 templates/CRM/Mailing/MailingUI.hlp diff --git a/js/angular-crm-ui.js b/js/angular-crm-ui.js index 2ae109d1a0..e59e7427c3 100644 --- a/js/angular-crm-ui.js +++ b/js/angular-crm-ui.js @@ -126,7 +126,7 @@ require: '^crmUiIdScope', restrict: 'EA', scope: { - // {title, name, help} + // {title, name, help, helpFile} crmUiField: '=' }, templateUrl: function(tElement, tAttrs){ @@ -136,7 +136,8 @@ transclude: true, link: function (scope, element, attrs, crmUiIdCtrl) { $(element).addClass('crm-section'); - scope.crmUiHelpFile = scope.$parent.crmUiHelpFile; // propagate default + // Inherit helpFile from parent scope if not specified + scope.crmUiHelpFile = scope.crmUiField.helpFile || scope.$parent.crmUiHelpFile; } }; }) diff --git a/js/angular-crmMailing/directives.js b/js/angular-crmMailing/directives.js index 646d285848..80a022a327 100644 --- a/js/angular-crmMailing/directives.js +++ b/js/angular-crmMailing/directives.js @@ -28,7 +28,7 @@ }); scope.crmMailingConst = CRM.crmMailing; scope.ts = CRM.ts(null); - scope.crmUiHelpFile = 'CRM/Mailing/Form/Upload'; + scope.crmUiHelpFile = 'CRM/Mailing/MailingUI'; scope[directiveName] = attr[directiveName] ? scope.$parent.$eval(attr[directiveName]) : {}; $q.when(crmMetadata.getFields('Mailing'), function(fields) { scope.mailingFields = fields; diff --git a/js/angular-crmMailingAB/directives.js b/js/angular-crmMailingAB/directives.js index d5f170c58f..7cf79d7313 100644 --- a/js/angular-crmMailingAB/directives.js +++ b/js/angular-crmMailingAB/directives.js @@ -21,6 +21,7 @@ scope.crmMailingConst = CRM.crmMailing; scope.crmMailingABCriteria = crmMailingABCriteria; scope.ts = CRM.ts(null); + scope.crmUiHelpFile = 'CRM/Mailing/MailingUI'; var fieldsModel = $parse(attr[directiveName]); scope.fields = fieldsModel(scope.$parent); diff --git a/partials/crmMailing/headerFooter.html b/partials/crmMailing/headerFooter.html index 165ecd9812..2e611c5a6c 100644 --- a/partials/crmMailing/headerFooter.html +++ b/partials/crmMailing/headerFooter.html @@ -4,7 +4,7 @@ Required vars: mailing, crmMailingConst -->
-
+
-
+
-
+
-
+
-
+
-
+
-