Simplify formatting in text versions of workflow messages
authorEileen McNaughton <emcnaughton@wikimedia.org>
Sat, 23 Sep 2023 12:34:59 +0000 (00:34 +1200)
committerEileen McNaughton <emcnaughton@wikimedia.org>
Sat, 23 Sep 2023 12:34:59 +0000 (00:34 +1200)
tests/templates/message_templates/event_online_receipt_text.tpl
xml/templates/message_templates/event_offline_receipt_text.tpl
xml/templates/message_templates/event_online_receipt_text.tpl

index 884c9ccf8c9e6192965f884f8f1224841f3d9838..b66a190e0847c00a9729e71274b6160770eede46 100644 (file)
@@ -11,9 +11,6 @@ isOnWaitlist:::{$isOnWaitlist}
 isRequireApproval:::{$isRequireApproval}
 {/if}
 participant_status:::{$participant_status}
-{if !empty($pricesetFieldsCount)}
-pricesetFieldsCount:::{$pricesetFieldsCount}
-{/if}
 {if !empty($isPrimary)}
 isPrimary:::{$isPrimary}
 {/if}
index 01c536252b4c3f6f58ed7b0292ae248c378ef13f..966d9d8e6a5b9c28dc580c5cac3a1d7bbc76a655 100644 (file)
@@ -4,38 +4,38 @@
 {/if}
 
 {if !empty($isOnWaitlist)}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {ts}You have been added to the WAIT LIST for this event.{/ts}
 
 {ts}If space becomes available you will receive an email with a link to a web page where you can complete your registration.{/ts}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {elseif !empty($isRequireApproval)}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {ts}Your registration has been submitted.{/ts}
 
 {ts}Once your registration has been reviewed, you will receive an email with a link to a web page where you can complete the registration process.{/ts}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {elseif $isPrimary && {contribution.balance_amount|boolean} && {contribution.is_pay_later|boolean}}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {$pay_later_receipt}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {/if}
 
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {ts}Event Information and Location{/ts}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {event.title}
 {event.start_date|crmDate}{if {event.end_date|boolean}}-{if '{event.end_date|crmDate:"%Y%m%d"}' === '{event.start_date|crmDate:"%Y%m%d"}'}{event.end_date|crmDate:"Time"}{else}{event.end_date}{/if}{/if}
 
 {if !empty($email)}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {ts}Registered Email{/ts}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {$email}
 {/if}
 {if {event.is_monetary|boolean}} {* This section for Paid events only.*}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {event.fee_label}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {if !empty($lineItem)}{foreach from=$lineItem item=value key=priceset}
 
@@ -99,7 +99,7 @@
 {ts 1=$priceset+1}Participant %1{/ts}
 {/if}
 {/if}
----------------------------------------------------------{if !empty($pricesetFieldsCount)}--------------------{/if}
+-----------------------------------------------------------------------------
 
 {capture assign=ts_item}{ts}Item{/ts}{/capture}
 {capture assign=ts_qty}{ts}Qty{/ts}{/capture}
 {capture assign=ts_total}{ts}Total{/ts}{/capture}
 {capture assign=ts_participant_total}{if !empty($pricesetFieldsCount)}{ts}Total Participants{/ts}{/if}{/capture}
 {$ts_item|string_format:"%-30s"} {$ts_qty|string_format:"%5s"} {$ts_each|string_format:"%10s"} {if !empty($dataArray)} {$ts_subtotal|string_format:"%10s"} {$ts_taxRate|string_format:"%10s"} {$ts_taxAmount|string_format:"%10s"} {/if} {$ts_total|string_format:"%10s"} {if !empty($ts_participant_total)}{$ts_participant_total|string_format:"%10s"}{/if}
-----------------------------------------------------------{if !empty($pricesetFieldsCount)}--------------------{/if}
+------------------------------------------------------------------------------
 
 {foreach from=$value item=line}
 {if !empty($pricesetFieldsCount)}{capture assign=ts_participant_count}{$line.participant_count}{/capture}{/if}
 {/if}
 
 {if $isPrimary && {contribution.balance_amount|boolean} && {contribution.is_pay_later|boolean}}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {$pay_later_receipt}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {/if}
 
 {/if}
 {if !empty($billingName)}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {ts}Billing Name and Address{/ts}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {$billingName}
 {$address}
 ===========================================================
 {ts}Credit Card Information{/ts}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {$credit_card_type}
 {$credit_card_number}
 
 {if !empty($customGroup)}
 {foreach from=$customGroup item=value key=customName}
-=========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+==============================================================================
 
 {$customName}
-=========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+==============================================================================
 
 {foreach from=$value item=v key=n}
 {$n}: {$v}
index d2075564791bab7ec19cc446a59b4af041f819c6..8ea903cb261b41fe3f63b71a4188fb2d0f8fa573 100644 (file)
 {/if}
 
 {if !empty($isOnWaitlist)}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {ts}You have been added to the WAIT LIST for this event.{/ts}
 
 {if $isPrimary}
 {ts}If space becomes available you will receive an email with a link to a web page where you can complete your registration.{/ts}
 {/if}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {elseif !empty($isRequireApproval)}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {ts}Your registration has been submitted.{/ts}
 
 {ts}Once your registration has been reviewed, you will receive an email with a link to a web page where you can complete the registration process.{/ts}
 
 {/if}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {elseif $isPrimary && {contribution.balance_amount|boolean} && {contribution.is_pay_later|boolean}}
 
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {if {event.pay_later_receipt|boolean}}{event.pay_later_receipt}{/if}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {/if}
 
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {ts}Event Information and Location{/ts}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {event.title}
 {event.start_date|crmDate:"%A"} {event.start_date|crmDate}{if {event.end_date|boolean}}-{if $event.event_end_date|crmDate:"%Y%m%d" == $event.event_start_date|crmDate:"%Y%m%d"}{$event.event_end_date|crmDate:0:1}{else}{$event.event_end_date|crmDate:"%A"} {$event.event_end_date|crmDate}{/if}{/if}
@@ -82,10 +82,10 @@ You were registered by: {$payer.name}
 {/if}
 {if {event.is_monetary|boolean} and empty($isRequireApproval)} {* This section for Paid events only.*}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {event.fee_label}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {if !empty($lineItem)}{foreach from=$lineItem item=value key=priceset}
 
@@ -96,7 +96,7 @@ You were registered by: {$payer.name}
 
 {/if}
 {/if}
------------------------------------------------------------{if !empty($pricesetFieldsCount)}-----------------------------------------------------{/if}
+----------------------------------------------------------------------------------------------------------------
 
 {capture assign=ts_item}{ts}Item{/ts}{/capture}
 {capture assign=ts_qty}{ts}Qty{/ts}{/capture}
@@ -109,7 +109,7 @@ You were registered by: {$payer.name}
 {capture assign=ts_total}{ts}Total{/ts}{/capture}
 {if !empty($pricesetFieldsCount)}{capture assign=ts_participant_total}{ts}Total Participants{/ts}{/capture}{/if}
 {$ts_item|string_format:"%-30s"} {$ts_qty|string_format:"%5s"} {$ts_each|string_format:"%10s"} {if $isShowTax && {contribution.tax_amount|boolean}} {$ts_subtotal|string_format:"%10s"} {$ts_taxRate|string_format:"%10s"} {$ts_taxAmount|string_format:"%10s"} {/if} {$ts_total|string_format:"%10s"} {if !empty($ts_participant_total)}{$ts_participant_total|string_format:"%10s"}{/if}
------------------------------------------------------------{if !empty($pricesetFieldsCount)}-----------------------------------------------------{/if}
+----------------------------------------------------------------------------------------------------------------
 
 {foreach from=$value item=line}
 {if !empty($pricesetFieldsCount)}{capture assign=ts_participant_count}{$line.participant_count}{/capture}{/if}
@@ -181,22 +181,22 @@ You were registered by: {$payer.name}
 {/if}
 {if !empty($billingName)}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {ts}Billing Name and Address{/ts}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {$billingName}
 {$address}
 {/if}
 
 {if !empty($credit_card_type)}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {ts}Credit Card Information{/ts}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {$credit_card_type}
 {$credit_card_number}
@@ -207,10 +207,10 @@ You were registered by: {$payer.name}
 
 {if !empty($customPre)}
 {foreach from=$customPre item=customPr key=i}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {$customPre_grouptitle.$i}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {foreach from=$customPr item=customValue key=customName}
  {$customName}: {$customValue}
@@ -220,10 +220,10 @@ You were registered by: {$payer.name}
 
 {if !empty($customPost)}
 {foreach from=$customPost item=customPos key=j}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {$customPost_grouptitle.$j}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {foreach from=$customPos item=customValue key=customName}
  {$customName}: {$customValue}
@@ -233,17 +233,17 @@ You were registered by: {$payer.name}
 {if !empty($customProfile)}
 
 {foreach from=$customProfile.profile item=eachParticipant key=participantID}
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {ts 1=$participantID+2}Participant Information - Participant %1{/ts}
 
-==========================================================={if !empty($pricesetFieldsCount)}===================={/if}
+===============================================================================
 
 {foreach from=$eachParticipant item=eachProfile key=pid}
-----------------------------------------------------------{if !empty($pricesetFieldsCount)}--------------------{/if}
+------------------------------------------------------------------------------
 
 {$customProfile.title.$pid}
-----------------------------------------------------------{if !empty($pricesetFieldsCount)}--------------------{/if}
+------------------------------------------------------------------------------
 
 {foreach from=$eachProfile item=val key=field}
 {foreach from=$val item=v key=f}