Reduce PHP warnings on Contribution
authorlarssandergreen <lars@wildsight.ca>
Sat, 10 Jun 2023 19:00:38 +0000 (13:00 -0600)
committerlarssandergreen <lars@wildsight.ca>
Sat, 10 Jun 2023 19:00:38 +0000 (13:00 -0600)
CRM/Contribute/Form/Contribution.php
templates/CRM/Contribute/Form/Contribution.tpl
templates/CRM/Core/BillingBlock.tpl

index d4500ecd1fceabc80c33fa00f9f903cac26ef418..c66e456e5fa3b22d621d36bac52bdccae6e4ada3 100644 (file)
@@ -850,9 +850,11 @@ class CRM_Contribute_Form_Contribution extends CRM_Contribute_Form_AbstractEditP
           $trxnId->freeze();
         }
         $financialType->freeze();
-        $this->assign('freezeFinancialType', TRUE);
+        $freezeFinancialType = TRUE;
+
       }
     }
+    $this->assign('freezeFinancialType', $freezeFinancialType ?? FALSE);
 
     if ($this->_action & CRM_Core_Action::VIEW) {
       $this->freeze();
index 21aa7a9d562ce81c1ae2188a3b68207a9e23397a..e7c1e8e6c96966b132ae246885a291de104e86f2 100644 (file)
@@ -22,7 +22,7 @@
       {elseif $contactId}
         {ts 1=$displayName}Use this form to submit a new contribution on behalf of %1.{/ts}
       {else}
-        {ts 1=$displayName}Use this form to submit a new contribution.{/ts}
+        {ts}Use this form to submit a new contribution.{/ts}
       {/if}
       {if $contributionMode == 'live'}
         {ts}<strong>A LIVE transaction will be submitted</strong> using the selected payment processor.{/ts}
index d873f64aa1e6618e9c426d17397b6a4e56de675e..3702d00fb3f50dedeb61f434b75f523ced6ddf03 100644 (file)
@@ -39,7 +39,7 @@
         {/foreach}
       </div>
     </fieldset>
-    {if $paymentAgreementTitle}
+    {if !$isBackOffice && $paymentAgreementTitle}
       <div id="payment_notice">
         <fieldset class="crm-public-form-item crm-group payment_notice-group">
           <legend>{$paymentAgreementTitle}</legend>