CRM-20889: Toggle check_number field on backoffice form as payment form fields
[civicrm-core.git] / templates / CRM / Event / Form / EventFees.tpl
index e481c82a84883d2a47cfe146debe55b44ec9d728..09d92e517b9322e1246791e11caa3a03a5006918 100644 (file)
  +--------------------------------------------------------------------+
 *}
 {assign var=isRecordPayment value=1 }
-{if $isFTPermissionDenied}
-  <script>
-  {literal}
-    CRM.alert(ts('You do not have all the permissions needed for this page.'), 'Permission Denied', 'error');
-  {/literal}
-  </script>
-{/if}
 {if $paid} {* We retrieve this tpl when event is selected - keep it empty if event is not paid *}
     <table class="form-layout">
     {if $priceSet}
@@ -95,7 +88,6 @@
                     <td>{include file="CRM/common/jcalendar.tpl" elementName=receive_date}</td>
                 </tr>
                 <tr class="crm-event-eventfees-form-block-payment_instrument_id"><td class="label">{$form.payment_instrument_id.label}<span class="crm-marker"> *</span></td><td>{$form.payment_instrument_id.html} {help id="payment_instrument_id" file="CRM/Contribute/Page/Tab.hlp"}</td></tr>
-                <tr id="checkNumber" class="crm-event-eventfees-form-block-check_number"><td class="label">{$form.check_number.label}</td><td>{$form.check_number.html|crmAddClass:six}</td></tr>
                 {if $showTransactionId }
                     <tr class="crm-event-eventfees-form-block-trxn_id"><td class="label">{$form.trxn_id.label}</td><td>{$form.trxn_id.html}</td></tr>
                 {/if}
            </fieldset>
            </td>
         </tr>
-
-        {* Record contribution field only present if we are NOT in submit credit card mode (! participantMode). *}
-        {include file="CRM/common/showHideByFieldValue.tpl"
-            trigger_field_id    ="record_contribution"
-            trigger_value       =""
-            target_element_id   ="payment_information"
-            target_element_type ="table-row"
-            field_type          ="radio"
-            invert              = 0
-        }
     {/if}
     </table>
 
 {/if}
 
-{* credit card block when it is live or test mode*}
-{if $participantMode and $paid}
-  <div class="spacer"></div>
+{if $action neq 2}
   {include file='CRM/Core/BillingBlockWrapper.tpl'}
 {/if}
+
 {if ($email OR $batchEmail) and $outBound_option != 2}
     <fieldset id="send_confirmation_receipt"><legend>{if $paid}{ts}Registration Confirmation and Receipt{/ts}{else}{ts}Registration Confirmation{/ts}{/if}</legend>
       <table class="form-layout" style="width:auto;">
 }
 {/if}
 
-{if $paid and ($action eq 1 or ( $action eq 2 and !$hasPayment) ) and !$participantMode}
-{include file="CRM/common/showHideByFieldValue.tpl"
-    trigger_field_id    ="payment_instrument_id"
-    trigger_value       = '4'
-    target_element_id   ="checkNumber"
-    target_element_type ="table-row"
-    field_type          ="select"
-    invert              = 0
-}
-{/if}
-
 {if $context eq 'standalone' and $outBound_option != 2 }
 <script type="text/javascript">
 {literal}