diff --git a/CRM/Upgrade/Incremental/MessageTemplates.php b/CRM/Upgrade/Incremental/MessageTemplates.php index 35db89aaf868..62aa413cfa1a 100644 --- a/CRM/Upgrade/Incremental/MessageTemplates.php +++ b/CRM/Upgrade/Incremental/MessageTemplates.php @@ -121,6 +121,51 @@ protected function getTemplateUpdates() { ['name' => 'pledge_acknowledge', 'type' => 'html'], ], ], + [ + 'version' => '5.20.alpha1', + 'upgrade_descriptor' => ts('Aditional email greetings and translation fixes'), + 'templates' => [ + ['name' => 'contribution_recurring_billing', 'type' => 'html'], + ['name' => 'contribution_recurring_billing', 'type' => 'text'], + ['name' => 'contribution_recurring_cancelled', 'type' => 'html'], + ['name' => 'contribution_recurring_cancelled', 'type' => 'text'], + ['name' => 'contribution_recurring_edit', 'type' => 'html'], + ['name' => 'contribution_recurring_edit', 'type' => 'text'], + ['name' => 'contribution_recurring_notify', 'type' => 'html'], + ['name' => 'contribution_recurring_notify', 'type' => 'text'], + ['name' => 'event_registration_receipt', 'type' => 'html'], + ['name' => 'event_registration_receipt', 'type' => 'text'], + ['name' => 'membership_autorenew_billing', 'type' => 'html'], + ['name' => 'membership_autorenew_billing', 'type' => 'text'], + ['name' => 'participant_cancelled', 'type' => 'html'], + ['name' => 'participant_cancelled', 'type' => 'text'], + ['name' => 'participant_confirm', 'type' => 'html'], + ['name' => 'participant_confirm', 'type' => 'text'], + ['name' => 'participant_expired', 'type' => 'html'], + ['name' => 'participant_expired', 'type' => 'text'], + ['name' => 'participant_transferred', 'type' => 'html'], + ['name' => 'participant_transferred', 'type' => 'text'], + ['name' => 'pcp_supporter_notify', 'type' => 'html'], + ['name' => 'pcp_supporter_notify', 'type' => 'text'], + ['name' => 'pledge_reminder', 'type' => 'html'], + ['name' => 'pledge_reminder', 'type' => 'text'], + ['name' => 'contribution_offline_receipt', 'type' => 'html'], + ['name' => 'contribution_offline_receipt', 'type' => 'text'], + ['name' => 'membership_autorenew_cancelled', 'type' => 'html'], + ['name' => 'membership_autorenew_cancelled', 'type' => 'text'], + ['name' => 'membership_offline_receipt', 'type' => 'html'], + ['name' => 'membership_offline_receipt', 'type' => 'text'], + ['name' => 'payment_or_refund_notification', 'type' => 'html'], + ['name' => 'payment_or_refund_notification', 'type' => 'text'], + ['name' => 'pcp_owner_notify', 'type' => 'html'], + ['name' => 'pcp_owner_notify', 'type' => 'text'], + ['name' => 'petition_confirmation_needed.tpl', 'type' => 'html'], + ['name' => 'petition_confirmation_needed.tpl', 'type' => 'text'], + ['name' => 'petition_sign.tpl', 'type' => 'html'], + ['name' => 'petition_sign.tpl', 'type' => 'text'], + ], + ], + ]; } diff --git a/tests/phpunit/CRM/Core/Payment/AuthorizeNetIPNTest.php b/tests/phpunit/CRM/Core/Payment/AuthorizeNetIPNTest.php index 67b81caae588..8ca640090982 100644 --- a/tests/phpunit/CRM/Core/Payment/AuthorizeNetIPNTest.php +++ b/tests/phpunit/CRM/Core/Payment/AuthorizeNetIPNTest.php @@ -255,7 +255,7 @@ public function testIPNPaymentMembershipRecurSuccessNoLeakage() { 'Email Address: anthony_anderson@civicrm.org', 'Honor', 'This membership will be automatically renewed every', - 'Dear Mr. Anthony Anderson II', + 'Dear Anthony', 'Thanks for your auto renew membership sign-up', 'In Memory of', ]); @@ -281,7 +281,7 @@ public function testIPNPaymentMembershipRecurSuccessNoLeakage() { 'Last Name: Anderson', 'Email Address: antonia_anderson@civicrm.org', 'This membership will be automatically renewed every', - 'Dear Mrs. Antonia Anderson II', + 'Dear Antonia', 'Thanks for your auto renew membership sign-up', ]); @@ -316,7 +316,7 @@ public function testIPNPaymentMembershipRecurSuccessNoLeakageOnlineThenOffline() 'Last Name: Anderson', 'Email Address: anthony_anderson@civicrm.org', 'This membership will be automatically renewed every', - 'Dear Mr. Anthony Anderson II', + 'Dear Anthony', 'Thanks for your auto renew membership sign-up', ]); @@ -337,7 +337,7 @@ public function testIPNPaymentMembershipRecurSuccessNoLeakageOnlineThenOffline() 'Membership Start Date:', 'Transaction #: hers', 'This membership will be automatically renewed every', - 'Dear Mrs. Antonia Anderson II', + 'Dear Antonia', 'Thanks for your auto renew membership sign-up', ], [ diff --git a/xml/templates/message_templates/contribution_offline_receipt_html.tpl b/xml/templates/message_templates/contribution_offline_receipt_html.tpl index 8a840cef62c2..dc54a2490a4e 100644 --- a/xml/templates/message_templates/contribution_offline_receipt_html.tpl +++ b/xml/templates/message_templates/contribution_offline_receipt_html.tpl @@ -21,7 +21,7 @@ - + {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if} {if $formValues.receipt_text}

{$formValues.receipt_text|htmlize}

{else} diff --git a/xml/templates/message_templates/contribution_offline_receipt_text.tpl b/xml/templates/message_templates/contribution_offline_receipt_text.tpl index 6b46e34259eb..434bcd3e0f89 100644 --- a/xml/templates/message_templates/contribution_offline_receipt_text.tpl +++ b/xml/templates/message_templates/contribution_offline_receipt_text.tpl @@ -1,3 +1,5 @@ +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} + {if $formValues.receipt_text} {$formValues.receipt_text} {else}{ts}Thank you for your support.{/ts}{/if} diff --git a/xml/templates/message_templates/contribution_recurring_billing_html.tpl b/xml/templates/message_templates/contribution_recurring_billing_html.tpl index f2b9d4884239..14df6973eb56 100644 --- a/xml/templates/message_templates/contribution_recurring_billing_html.tpl +++ b/xml/templates/message_templates/contribution_recurring_billing_html.tpl @@ -21,7 +21,7 @@ -

{ts 1=$contact.display_name}Dear %1{/ts},

+ {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if}

{ts 1=$amount 2=$recur_frequency_interval 3=$recur_frequency_unit}Billing details for your recurring contribution of %1, every %2 %3 have been updated.{/ts}

@@ -62,4 +62,4 @@ - \ No newline at end of file + diff --git a/xml/templates/message_templates/contribution_recurring_billing_text.tpl b/xml/templates/message_templates/contribution_recurring_billing_text.tpl index 37e7ed750216..c71682e9074e 100644 --- a/xml/templates/message_templates/contribution_recurring_billing_text.tpl +++ b/xml/templates/message_templates/contribution_recurring_billing_text.tpl @@ -1,4 +1,4 @@ -{ts 1=$contact.display_name}Dear %1{/ts}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} {ts 1=$amount 2=$recur_frequency_interval 3=$recur_frequency_unit}Billing details for your recurring contribution of %1, every %2 %3 have been updated.{/ts} @@ -20,4 +20,4 @@ {ts}Expires{/ts}: {$credit_card_exp_date|truncate:7:''|crmDate} -{ts 1=$receipt_from_email}If you have questions please contact us at %1{/ts} \ No newline at end of file +{ts 1=$receipt_from_email}If you have questions please contact us at %1{/ts} diff --git a/xml/templates/message_templates/contribution_recurring_cancelled_html.tpl b/xml/templates/message_templates/contribution_recurring_cancelled_html.tpl index 674333e079fb..d04dd909a3be 100644 --- a/xml/templates/message_templates/contribution_recurring_cancelled_html.tpl +++ b/xml/templates/message_templates/contribution_recurring_cancelled_html.tpl @@ -21,7 +21,7 @@ -

{ts 1=$contact.display_name}Dear %1{/ts},

+ {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if}

{ts 1=$amount 2=$recur_frequency_interval 3=$recur_frequency_unit}Your recurring contribution of %1, every %2 %3 has been cancelled as requested.{/ts}

diff --git a/xml/templates/message_templates/contribution_recurring_cancelled_text.tpl b/xml/templates/message_templates/contribution_recurring_cancelled_text.tpl index f10d37432f5c..0b23d8eac013 100644 --- a/xml/templates/message_templates/contribution_recurring_cancelled_text.tpl +++ b/xml/templates/message_templates/contribution_recurring_cancelled_text.tpl @@ -1,3 +1,3 @@ -{ts 1=$contact.display_name}Dear %1{/ts}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} {ts 1=$amount 2=$recur_frequency_interval 3=$recur_frequency_unit}Your recurring contribution of %1, every %2 %3 has been cancelled as requested.{/ts} diff --git a/xml/templates/message_templates/contribution_recurring_edit_html.tpl b/xml/templates/message_templates/contribution_recurring_edit_html.tpl index 0ef701f9c28b..c1a9ae77ca12 100644 --- a/xml/templates/message_templates/contribution_recurring_edit_html.tpl +++ b/xml/templates/message_templates/contribution_recurring_edit_html.tpl @@ -21,7 +21,7 @@ -

{ts 1=$contact.display_name}Dear %1{/ts},

+ {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if}

{ts}Your recurring contribution has been updated as requested:{/ts}

{ts 1=$amount 2=$recur_frequency_interval 3=$recur_frequency_unit}Recurring contribution is for %1, every %2 %3(s){/ts}{if $installments}{ts 1=$installments} for %1 installments{/ts}{/if}.

diff --git a/xml/templates/message_templates/contribution_recurring_edit_text.tpl b/xml/templates/message_templates/contribution_recurring_edit_text.tpl index b1e038b5da3d..af99606cd180 100644 --- a/xml/templates/message_templates/contribution_recurring_edit_text.tpl +++ b/xml/templates/message_templates/contribution_recurring_edit_text.tpl @@ -1,8 +1,8 @@ -{ts 1=$contact.display_name}Dear %1{/ts}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} {ts}Your recurring contribution has been updated as requested:{/ts} {ts 1=$amount 2=$recur_frequency_interval 3=$recur_frequency_unit}Recurring contribution is for %1, every %2 %3(s){/ts} {if $installments}{ts 1=$installments} for %1 installments.{/ts}{/if} -{ts 1=$receipt_from_email}If you have questions please contact us at %1.{/ts} \ No newline at end of file +{ts 1=$receipt_from_email}If you have questions please contact us at %1.{/ts} diff --git a/xml/templates/message_templates/contribution_recurring_notify_html.tpl b/xml/templates/message_templates/contribution_recurring_notify_html.tpl index e2b09248355a..201a5596f398 100644 --- a/xml/templates/message_templates/contribution_recurring_notify_html.tpl +++ b/xml/templates/message_templates/contribution_recurring_notify_html.tpl @@ -21,7 +21,7 @@ -

{ts 1=$displayName}Dear %1{/ts},

+ {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if} diff --git a/xml/templates/message_templates/contribution_recurring_notify_text.tpl b/xml/templates/message_templates/contribution_recurring_notify_text.tpl index b0db9b5a31d2..19251cdba918 100644 --- a/xml/templates/message_templates/contribution_recurring_notify_text.tpl +++ b/xml/templates/message_templates/contribution_recurring_notify_text.tpl @@ -1,4 +1,4 @@ -{ts 1=$displayName}Dear %1{/ts}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} {if $recur_txnType eq 'START'} {if $auto_renew_membership} diff --git a/xml/templates/message_templates/event_registration_receipt_html.tpl b/xml/templates/message_templates/event_registration_receipt_html.tpl index 3436a1903486..cb732bcc1ed1 100644 --- a/xml/templates/message_templates/event_registration_receipt_html.tpl +++ b/xml/templates/message_templates/event_registration_receipt_html.tpl @@ -9,7 +9,7 @@ {capture assign=labelStyle }style="padding: 4px; border-bottom: 1px solid #999; background-color: #f7f7f7;"{/capture} {capture assign=valueStyle }style="padding: 4px; border-bottom: 1px solid #999;"{/capture} -

Dear {contact.display_name},

+ {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if} {if $is_pay_later}

This is being sent to you as an acknowledgement that you have registered one or more members for the following workshop, event or purchase. Please note, however, that the status of your payment is pending, and the registration for this event will not be completed until your payment is received. diff --git a/xml/templates/message_templates/event_registration_receipt_text.tpl b/xml/templates/message_templates/event_registration_receipt_text.tpl index 695b53d60432..7ce744673c77 100644 --- a/xml/templates/message_templates/event_registration_receipt_text.tpl +++ b/xml/templates/message_templates/event_registration_receipt_text.tpl @@ -1,4 +1,5 @@ -Dear {contact.display_name}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} + {if $is_pay_later} This is being sent to you as an acknowledgement that you have registered one or more members for the following workshop, event or purchase. Please note, however, that the status of your payment is pending, and the registration for this event will not be completed until your payment is received. {else} diff --git a/xml/templates/message_templates/membership_autorenew_billing_html.tpl b/xml/templates/message_templates/membership_autorenew_billing_html.tpl index a8ec69f11623..9ff740f8b7d0 100644 --- a/xml/templates/message_templates/membership_autorenew_billing_html.tpl +++ b/xml/templates/message_templates/membership_autorenew_billing_html.tpl @@ -21,7 +21,7 @@ -

{ts 1=$contact.display_name}Dear %1{/ts},

+ {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if}

{ts 1=$membershipType}Billing details for your automatically renewed %1 membership have been updated.{/ts}

diff --git a/xml/templates/message_templates/membership_autorenew_billing_text.tpl b/xml/templates/message_templates/membership_autorenew_billing_text.tpl index 8df337a3a21b..dcd942971c9e 100644 --- a/xml/templates/message_templates/membership_autorenew_billing_text.tpl +++ b/xml/templates/message_templates/membership_autorenew_billing_text.tpl @@ -1,4 +1,4 @@ -{ts 1=$contact.display_name}Dear %1{/ts}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} {ts 1=$membershipType}Billing details for your automatically renewed %1 membership have been updated.{/ts} @@ -20,4 +20,4 @@ {ts}Expires{/ts}: {$credit_card_exp_date|truncate:7:''|crmDate} -{ts 1=$receipt_from_email}If you have questions please contact us at %1{/ts} \ No newline at end of file +{ts 1=$receipt_from_email}If you have questions please contact us at %1{/ts} diff --git a/xml/templates/message_templates/membership_autorenew_cancelled_html.tpl b/xml/templates/message_templates/membership_autorenew_cancelled_html.tpl index 77e11ff632f1..a06f666d5daa 100644 --- a/xml/templates/message_templates/membership_autorenew_cancelled_html.tpl +++ b/xml/templates/message_templates/membership_autorenew_cancelled_html.tpl @@ -21,7 +21,7 @@ - + {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if}

{ts 1=$membershipType}The automatic renewal of your %1 membership has been cancelled as requested. This does not affect the status of your membership - you will receive a separate notification when your membership is up for renewal.{/ts}

diff --git a/xml/templates/message_templates/membership_autorenew_cancelled_text.tpl b/xml/templates/message_templates/membership_autorenew_cancelled_text.tpl index 51cec8cff6a7..15387b63decd 100644 --- a/xml/templates/message_templates/membership_autorenew_cancelled_text.tpl +++ b/xml/templates/message_templates/membership_autorenew_cancelled_text.tpl @@ -1,3 +1,5 @@ +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} + {ts 1=$membershipType}The automatic renewal of your %1 membership has been cancelled as requested. This does not affect the status of your membership - you will receive a separate notification when your membership is up for renewal.{/ts} =========================================================== diff --git a/xml/templates/message_templates/membership_offline_receipt_html.tpl b/xml/templates/message_templates/membership_offline_receipt_html.tpl index 8d5347a721c6..deebf480ef65 100644 --- a/xml/templates/message_templates/membership_offline_receipt_html.tpl +++ b/xml/templates/message_templates/membership_offline_receipt_html.tpl @@ -21,6 +21,7 @@ + {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if} {if $formValues.receipt_text_signup}

{$formValues.receipt_text_signup|htmlize}

{elseif $formValues.receipt_text_renewal} diff --git a/xml/templates/message_templates/membership_offline_receipt_text.tpl b/xml/templates/message_templates/membership_offline_receipt_text.tpl index 7df285af46b2..ee4ede9e8a0a 100644 --- a/xml/templates/message_templates/membership_offline_receipt_text.tpl +++ b/xml/templates/message_templates/membership_offline_receipt_text.tpl @@ -1,3 +1,5 @@ +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} + {if $formValues.receipt_text_signup} {$formValues.receipt_text_signup} {elseif $formValues.receipt_text_renewal} diff --git a/xml/templates/message_templates/participant_cancelled_html.tpl b/xml/templates/message_templates/participant_cancelled_html.tpl index 4a882c1259b3..062f610cb7d2 100644 --- a/xml/templates/message_templates/participant_cancelled_html.tpl +++ b/xml/templates/message_templates/participant_cancelled_html.tpl @@ -21,7 +21,7 @@ -

{ts 1=$contact.display_name}Dear %1{/ts},

+ {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if}

{ts}Your Event Registration has been cancelled.{/ts}

diff --git a/xml/templates/message_templates/participant_cancelled_text.tpl b/xml/templates/message_templates/participant_cancelled_text.tpl index b4430b33d194..684983682f1e 100644 --- a/xml/templates/message_templates/participant_cancelled_text.tpl +++ b/xml/templates/message_templates/participant_cancelled_text.tpl @@ -1,4 +1,4 @@ -{ts 1=$contact.display_name}Dear %1{/ts}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} {ts}Your Event Registration has been cancelled.{/ts} diff --git a/xml/templates/message_templates/participant_confirm_html.tpl b/xml/templates/message_templates/participant_confirm_html.tpl index ca6816d166f3..d457043646aa 100644 --- a/xml/templates/message_templates/participant_confirm_html.tpl +++ b/xml/templates/message_templates/participant_confirm_html.tpl @@ -21,7 +21,7 @@ -

{ts 1=$contact.display_name}Dear %1{/ts},

+ {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if} {if !$isAdditional and $participant.id} @@ -33,13 +33,13 @@ {capture assign=confirmUrl}{crmURL p='civicrm/event/confirm' q="reset=1&participantId=`$participant.id`&cs=`$checksumValue`" a=true h=0 fe=1}{/capture} - Go to a web page where you can confirm your registration online + {ts}Go to a web page where you can confirm your registration online{/ts} {/if} {if $event.allow_selfcancelxfer } This event allows for self-cancel or transfer - {capture assign=selfService}{crmURL p='civicrm/event/selfsvcupdate' q="reset=1&pid=`$participantID`&{contact.checksum}" h=0 a=1 fe=1}{/capture} + {capture assign=selfService}{crmURL p='civicrm/event/selfsvcupdate' q="reset=1&pid=`$participantID`&{contact.checksum}" h=0 a=1 fe=1}{/capture} {ts}Self service cancel transfer{/ts} {/if} diff --git a/xml/templates/message_templates/participant_confirm_text.tpl b/xml/templates/message_templates/participant_confirm_text.tpl index e8f90132b5c1..dbadd748349a 100644 --- a/xml/templates/message_templates/participant_confirm_text.tpl +++ b/xml/templates/message_templates/participant_confirm_text.tpl @@ -1,4 +1,5 @@ -{ts 1=$contact.display_name}Dear %1{/ts}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} + {if !$isAdditional and $participant.id} =========================================================== diff --git a/xml/templates/message_templates/participant_expired_html.tpl b/xml/templates/message_templates/participant_expired_html.tpl index a11ff72685cf..290a37cf2466 100644 --- a/xml/templates/message_templates/participant_expired_html.tpl +++ b/xml/templates/message_templates/participant_expired_html.tpl @@ -21,7 +21,7 @@ -

{ts 1=$contact.display_name}Dear %1{/ts},

+ {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if}

{ts 1=$event.event_title}Your pending event registration for %1 has expired because you did not confirm your registration.{/ts}

{ts 1=$domain.phone 2=$domain.email}Please contact us at %1 or send email to %2 if you have questions diff --git a/xml/templates/message_templates/participant_expired_text.tpl b/xml/templates/message_templates/participant_expired_text.tpl index be649c11daee..56acebfb5f14 100644 --- a/xml/templates/message_templates/participant_expired_text.tpl +++ b/xml/templates/message_templates/participant_expired_text.tpl @@ -1,4 +1,4 @@ -{ts 1=$contact.display_name}Dear %1{/ts}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} {ts 1=$event.event_title}Your pending event registration for %1 has expired because you did not confirm your registration.{/ts} diff --git a/xml/templates/message_templates/participant_transferred_html.tpl b/xml/templates/message_templates/participant_transferred_html.tpl index 26cbf37e1524..9a21f1b010de 100644 --- a/xml/templates/message_templates/participant_transferred_html.tpl +++ b/xml/templates/message_templates/participant_transferred_html.tpl @@ -21,7 +21,7 @@ -

{ts 1=$contact.display_name}Dear %1{/ts},

+ {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if}

{ts 1=$to_participant}Your Event Registration has been Transferred to %1.{/ts}

diff --git a/xml/templates/message_templates/participant_transferred_text.tpl b/xml/templates/message_templates/participant_transferred_text.tpl index aeac8a7ba159..449594828ee4 100644 --- a/xml/templates/message_templates/participant_transferred_text.tpl +++ b/xml/templates/message_templates/participant_transferred_text.tpl @@ -1,4 +1,4 @@ -{ts 1=$contact.display_name}Dear %1{/ts}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} {ts 1=$to_participant}Your Event Registration has been transferred to %1.{/ts} diff --git a/xml/templates/message_templates/payment_or_refund_notification_html.tpl b/xml/templates/message_templates/payment_or_refund_notification_html.tpl index 6095b4d23fec..50e626d2b8d7 100644 --- a/xml/templates/message_templates/payment_or_refund_notification_html.tpl +++ b/xml/templates/message_templates/payment_or_refund_notification_html.tpl @@ -20,9 +20,9 @@ - {if $emailGreeting}{$emailGreeting},{/if} + {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if} {if $isRefund}

{ts}A refund has been issued based on changes in your registration selections.{/ts}

{else} diff --git a/xml/templates/message_templates/payment_or_refund_notification_text.tpl b/xml/templates/message_templates/payment_or_refund_notification_text.tpl index 2f166dd3d44b..af199323627d 100644 --- a/xml/templates/message_templates/payment_or_refund_notification_text.tpl +++ b/xml/templates/message_templates/payment_or_refund_notification_text.tpl @@ -1,4 +1,5 @@ -{if $emailGreeting}{$emailGreeting}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} + {/if}{if $isRefund} {ts}A refund has been issued based on changes in your registration selections.{/ts} {else} diff --git a/xml/templates/message_templates/pcp_owner_notify_html.tpl b/xml/templates/message_templates/pcp_owner_notify_html.tpl index 9e4b6d29d66c..6ceb77c35a33 100644 --- a/xml/templates/message_templates/pcp_owner_notify_html.tpl +++ b/xml/templates/message_templates/pcp_owner_notify_html.tpl @@ -10,6 +10,7 @@ {capture assign=labelStyle }style="padding: 4px; border-bottom: 1px solid #999; background-color: #f7f7f7;"{/capture} {capture assign=valueStyle }style="padding: 4px; border-bottom: 1px solid #999;"{/capture} + {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if}

{ts}You have received a donation at your personal page{/ts}: {$page_title}

{ts}Your fundraising total has been updated.{/ts}
{ts}The donor's information is listed below. You can choose to contact them and convey your thanks if you wish.{/ts}
diff --git a/xml/templates/message_templates/pcp_owner_notify_text.tpl b/xml/templates/message_templates/pcp_owner_notify_text.tpl index 4c7f7841afc6..964eabff6221 100644 --- a/xml/templates/message_templates/pcp_owner_notify_text.tpl +++ b/xml/templates/message_templates/pcp_owner_notify_text.tpl @@ -2,6 +2,8 @@ {ts}Personal Campaign Page Owner Notification{/ts} =========================================================== +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} + {ts}You have received a donation at your personal page{/ts}: {$page_title} >> {$pcpInfoURL} diff --git a/xml/templates/message_templates/pcp_supporter_notify_html.tpl b/xml/templates/message_templates/pcp_supporter_notify_html.tpl index d0e429b5cba5..a3e2c389e57d 100644 --- a/xml/templates/message_templates/pcp_supporter_notify_html.tpl +++ b/xml/templates/message_templates/pcp_supporter_notify_html.tpl @@ -21,7 +21,7 @@ -

{ts}Dear supporter{/ts},

+ {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if}

{ts 1="$contribPageTitle"}Thanks for creating a personal campaign page in support of %1.{/ts}

diff --git a/xml/templates/message_templates/pcp_supporter_notify_text.tpl b/xml/templates/message_templates/pcp_supporter_notify_text.tpl index 6f00d5cc0dad..872ce3f2776f 100644 --- a/xml/templates/message_templates/pcp_supporter_notify_text.tpl +++ b/xml/templates/message_templates/pcp_supporter_notify_text.tpl @@ -1,4 +1,5 @@ -{ts}Dear supporter{/ts}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} + {ts 1="$contribPageTitle"}Thanks for creating a personal campaign page in support of %1.{/ts} {if $pcpStatus eq 'Approved'} diff --git a/xml/templates/message_templates/petition_confirmation_needed_html.tpl b/xml/templates/message_templates/petition_confirmation_needed_html.tpl index 2d30dc11c79d..657000a8e609 100644 --- a/xml/templates/message_templates/petition_confirmation_needed_html.tpl +++ b/xml/templates/message_templates/petition_confirmation_needed_html.tpl @@ -1,3 +1,5 @@ +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if} +

Thank you for signing {$petition.title}.

In order to complete your signature, we must confirm your e-mail. diff --git a/xml/templates/message_templates/petition_confirmation_needed_text.tpl b/xml/templates/message_templates/petition_confirmation_needed_text.tpl index 8549b39b4c41..1bf5583ac1aa 100644 --- a/xml/templates/message_templates/petition_confirmation_needed_text.tpl +++ b/xml/templates/message_templates/petition_confirmation_needed_text.tpl @@ -1,3 +1,5 @@ +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} + Thank you for signing {$petition.title}. In order to complete your signature, we must confirm your e-mail. diff --git a/xml/templates/message_templates/petition_sign_html.tpl b/xml/templates/message_templates/petition_sign_html.tpl index 6dfbaab34d57..386527c9b668 100644 --- a/xml/templates/message_templates/petition_sign_html.tpl +++ b/xml/templates/message_templates/petition_sign_html.tpl @@ -1,3 +1,5 @@ +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if} +

Thank you for signing {$petition.title}.

{include file="CRM/Campaign/Page/Petition/SocialNetwork.tpl" petition_id=$survey_id noscript=true emailMode=true} diff --git a/xml/templates/message_templates/petition_sign_text.tpl b/xml/templates/message_templates/petition_sign_text.tpl index 8e8a555dfbf3..f95137e86996 100644 --- a/xml/templates/message_templates/petition_sign_text.tpl +++ b/xml/templates/message_templates/petition_sign_text.tpl @@ -1 +1,3 @@ +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} + Thank you for signing {$petition.title}. diff --git a/xml/templates/message_templates/pledge_reminder_html.tpl b/xml/templates/message_templates/pledge_reminder_html.tpl index c2e42a57748e..f59fd86f4ba1 100644 --- a/xml/templates/message_templates/pledge_reminder_html.tpl +++ b/xml/templates/message_templates/pledge_reminder_html.tpl @@ -21,7 +21,7 @@ -

{ts 1=$contact.display_name}Dear %1{/ts},

+ {assign var="greeting" value="{contact.email_greeting}"}{if $greeting}

{$greeting},

{/if}

{ts 1=$next_payment|truncate:10:''|crmDate}This is a reminder that the next payment on your pledge is due on %1.{/ts}

diff --git a/xml/templates/message_templates/pledge_reminder_text.tpl b/xml/templates/message_templates/pledge_reminder_text.tpl index 2761c3d36ac8..6ff194224f21 100644 --- a/xml/templates/message_templates/pledge_reminder_text.tpl +++ b/xml/templates/message_templates/pledge_reminder_text.tpl @@ -1,4 +1,4 @@ -{ts 1=$contact.display_name}Dear %1{/ts}, +{assign var="greeting" value="{contact.email_greeting}"}{if $greeting}{$greeting},{/if} {ts 1=$next_payment|truncate:10:''|crmDate}This is a reminder that the next payment on your pledge is due on %1.{/ts}