From 0bbe9d5ec8e284a741d1b9206e81e949ba8dd459 Mon Sep 17 00:00:00 2001 From: Bradley Taylor Date: Fri, 31 Dec 2021 11:13:12 +0000 Subject: [PATCH] Use JS escaping for {ts} calls in a JS context --- templates/CRM/Campaign/Form/Task/Interview.tpl | 2 +- templates/CRM/Contact/Form/Edit/Lock.tpl | 4 ++-- templates/CRM/Contact/Form/Merge.tpl | 8 ++++---- templates/CRM/Contact/Form/ShareAddress.tpl | 2 +- templates/CRM/Contribute/Form/Contribution.tpl | 4 ++-- templates/CRM/Event/Form/SelfSvcUpdate.tpl | 2 +- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/templates/CRM/Campaign/Form/Task/Interview.tpl b/templates/CRM/Campaign/Form/Task/Interview.tpl index 2987636b71..5c5d29a94f 100644 --- a/templates/CRM/Campaign/Form/Task/Interview.tpl +++ b/templates/CRM/Campaign/Form/Task/Interview.tpl @@ -311,7 +311,7 @@ var surveyActivityIds = {/literal}{$surveyActivityIds}{literal}; if (interview.errors[error]) errorList = errorList + '
  • ' + interview.errors[error] + '
  • '; } if ( errorList ) { - var allErrors = ' {/literal}{ts}Please correct the following errors in the survey fields below:{/ts}{literal}'; + var allErrors = ' {/literal}{ts escape='js'}Please correct the following errors in the survey fields below:{/ts}{literal}'; CRM.$('#responseErrors').show( ).html(allErrors); } } diff --git a/templates/CRM/Contact/Form/Edit/Lock.tpl b/templates/CRM/Contact/Form/Edit/Lock.tpl index bca56db29b..da62b6d41b 100644 --- a/templates/CRM/Contact/Form/Edit/Lock.tpl +++ b/templates/CRM/Contact/Form/Edit/Lock.tpl @@ -7,7 +7,7 @@ CRM.$(function($) { $('
    ') .appendTo($('#update_modified_date')); $('