CRM-13054: Add crmRegions to EventInfo template.
authorFrank J. Gómez <fgomez@confluencecorp.com>
Wed, 17 Jul 2013 07:13:39 +0000 (03:13 -0400)
committerFrank J. Gómez <fgomez@confluencecorp.com>
Wed, 17 Jul 2013 07:13:39 +0000 (03:13 -0400)
templates/CRM/Event/Page/EventInfo.tpl

index 90b9da97eadf20074a6255a38a3f5b2eae9ea0c5..d50365a8914969755a5c35b7acab800f377d0c9f 100644 (file)
 {/if}
 <div class="vevent crm-event-id-{$event.id} crm-block crm-event-info-form-block">
   <div class="event-info">
-  {if $event.summary}
-      <div class="crm-section event_summary-section">
+  {* Display top buttons only if the page is long enough to merit duplicate buttons *}
+  {if $event.summary or $event.description}
+    {crmRegion name="event-page-eventinfo-actionlinks-top"}
+      <div class="actionlinks-top">
         {if $allowRegistration}
           <div class="action-link section register_link-section register_link-top">
             <a href="{$registerURL}" title="{$registerText}" class="button crm-register-button"><span>{$registerText}</span></a>
           </div>
         {/if}
+      </div>
+    {/crmRegion}
+  {/if}
+
+  {if $event.summary}
+      <div class="crm-section event_summary-section">
         {$event.summary}
       </div>
   {/if}
   {if $event.description}
       <div class="crm-section event_description-section summary">
-          {* Put the top register link to the right of description if no summary *}
-          {if $allowRegistration && !$event.summary}
-              <div class="action-link section register_link-section register_link-top">
-                <a href="{$registerURL}" title="{$registerText}" class="button crm-register-button"><span>{$registerText}</span></a>
-              </div>
-          {/if}
           {$event.description}
       </div>
   {/if}
 
     {include file="CRM/Custom/Page/CustomDataView.tpl"}
 
-  {if $allowRegistration}
-        <div class="action-link section register_link-section register_link-bottom">
+    {crmRegion name="event-page-eventinfo-actionlinks-bottom"}
+      <div class="actionlinks-bottom">
+        {if $allowRegistration}
+          <div class="action-link section register_link-section register_link-bottom">
             <a href="{$registerURL}" title="{$registerText}" class="button crm-register-button"><span>{$registerText}</span></a>
-        </div>
-    {/if}
+          </div>
+        {/if}
+      </div>
+    {/crmRegion}
     { if $event.is_public }
         <br />{include file="CRM/Event/Page/iCalLinks.tpl"}
     {/if}