[php8-compact] Further test fixes for php8
authorSeamus Lee <seamuslee001@gmail.com>
Mon, 14 Jun 2021 07:39:02 +0000 (07:39 +0000)
committerSeamus Lee <seamuslee001@gmail.com>
Mon, 14 Jun 2021 07:39:02 +0000 (07:39 +0000)
CRM/Core/Form/Date.php
templates/CRM/Form/body.tpl

index 24ff85f3a363f973178269480f63a30cbda03b2a..db4ac7019c1009ccf8fc2620a6ca6c897d3e6ad5 100644 (file)
@@ -165,12 +165,12 @@ class CRM_Core_Form_Date {
     &$form,
     $fieldName,
     $selector,
-    $from = '_from',
-    $to = '_to',
-    $fromLabel = 'From:',
-    $required = FALSE,
-    $dateFormat = 'searchDate',
-    $displayTime = FALSE,
+    $from,
+    $to,
+    $fromLabel,
+    $required,
+    $dateFormat,
+    $displayTime,
     $attributes
   ) {
     CRM_Core_Error::deprecatedFunctionWarning('function will be removed');
index 01c4c922731c524a40190581123019690ba948e2..3baf72cacdcf59b85a7d66ad98633d7c64fa48c8 100644 (file)
@@ -32,7 +32,7 @@
 {/if}
 
 {* Add all the form elements sent in by the hook  - formerly used by civiDiscount, now deprecated*}
-{if $beginHookFormElements}
+{if !empty($beginHookFormElements)}
   <table class="form-layout-compressed">
   {foreach from=$beginHookFormElements key=dontCare item=hookFormElement}
       <tr><td class="label nowrap">{$form.$hookFormElement.label}</td><td>{$form.$hookFormElement.html}</td></tr>