Option.tpl whitespace cleanup
authorColeman Watts <coleman@civicrm.org>
Wed, 24 Sep 2014 18:45:22 +0000 (14:45 -0400)
committerColeman Watts <coleman@civicrm.org>
Wed, 24 Sep 2014 18:45:26 +0000 (14:45 -0400)
templates/CRM/Price/Page/Option.tpl

index 99d3d0270e64fc9d597f6e5dc39d13e1b83f53e7..41626147fa02fadb684d1aff5fe2e57df5070fc6 100644 (file)
  +--------------------------------------------------------------------+
 *}
 {if ($action eq 1 or $action eq 2 or $action eq 4 or $action eq 8  and !$usedBy) and !$isReserved}
-    {include file="CRM/Price/Form/Option.tpl"}
+  {include file="CRM/Price/Form/Option.tpl"}
 {/if}
 
 {if $usedBy}
-    <div class='spacer'></div>
-    <div id="price_set_used_by" class="messages status no-popup">
+  <div class='spacer'></div>
+  <div id="price_set_used_by" class="messages status no-popup">
     <div class="icon inform-icon"></div>
-        {if $action eq 8}
-            {ts 1=$usedPriceSetTitle}Unable to delete the '%1' Price Field Option - it is currently in use by one or more active events  or contribution pages or contributions.{/ts}
-         {/if}
-
-  {if $usedBy.civicrm_event or $usedBy.civicrm_contribution_page}
-            {include file="CRM/Price/Page/table.tpl"}
-        {/if}
+    {if $action eq 8}
+      {ts 1=$usedPriceSetTitle}Unable to delete the '%1' Price Field Option - it is currently in use by one or more active events  or contribution pages or contributions.{/ts}
+    {/if}
 
-    </div>
+    {if $usedBy.civicrm_event or $usedBy.civicrm_contribution_page}
+      {include file="CRM/Price/Page/table.tpl"}
     {/if}
 
+  </div>
+{/if}
+
 
 
 {if $customOption}
 
-    <div id="field_page">
-     <p></p>
-        {strip}
-  {* handle enable/disable actions*}
-   {include file="CRM/common/enableDisableApi.tpl"}
-   {include file="CRM/common/crmeditable.tpl"}
-        <table id="options" class="row-highlight">
+  <div id="field_page">
+    <p></p>
+    {strip}
+      {* handle enable/disable actions*}
+      {include file="CRM/common/enableDisableApi.tpl"}
+      {include file="CRM/common/crmeditable.tpl"}
+      <table id="options" class="row-highlight">
         <thead>
-         <tr>
-            <th>{ts}Option Label{/ts}</th>
-            <th>{ts}Option Amount{/ts}</th>
+        <tr>
+          <th>{ts}Option Label{/ts}</th>
+          <th>{ts}Option Amount{/ts}</th>
           <th>{ts}Default{/ts}</th>
           <th>{ts}Financial Type{/ts}</th>
-            <th>{ts}Order{/ts}</th>
+          <th>{ts}Order{/ts}</th>
           <th>{ts}Enabled?{/ts}</th>
-            <th></th>
-         </tr>
+          <th></th>
+        </tr>
         </thead>
         {foreach from=$customOption item=row}
-      <tr id="price_field_value-{$row.id}" class="crm-entity {cycle values="odd-row,even-row"} {$row.class}{if NOT $row.is_active} disabled{/if}">
+          <tr id="price_field_value-{$row.id}" class="crm-entity {cycle values="odd-row,even-row"} {$row.class}{if NOT $row.is_active} disabled{/if}">
             <td class="crm-price-option-label crm-editable" data-field="label">{$row.label}</td>
             <td class="crm-price-option-value">{$row.amount|crmMoney}</td>
-      <td class="crm-price-option-is_default">{if $row.is_default}<img src="{$config->resourceBase}i/check.gif" alt="{ts}Default{/ts}" />{/if}</td>
-      <td class="nowrap crm-price-option-financial-type-id">{$row.financial_type_id}</td>
+            <td class="crm-price-option-is_default">{if $row.is_default}<img src="{$config->resourceBase}i/check.gif" alt="{ts}Default{/ts}" />{/if}</td>
+            <td class="nowrap crm-price-option-financial-type-id">{$row.financial_type_id}</td>
             <td class="nowrap crm-price-option-order">{$row.weight}</td>
             <td id="row_{$row.id}_status" class="crm-price-option-is_active">{if $row.is_active eq 1} {ts}Yes{/ts} {else} {ts}No{/ts} {/if}</td>
             <td>{$row.action|replace:'xx':$row.id}</td>
-        </tr>
+          </tr>
         {/foreach}
         </tbody>
-        </table>
-        {/strip}
-        {if $addMoreFields && !$isReserved}
-        <div class="action-link">
-            <a href="{crmURL q="reset=1&action=add&fid=$fid&sid=$sid"}" class="button"><span><div class="icon add-icon"></div> {ts 1=$fieldTitle}New Option for '%1'{/ts}</span></a>
-        </div>
-  {/if}
-    </div>
+      </table>
+    {/strip}
+    {if $addMoreFields && !$isReserved}
+      <div class="action-link">
+        <a href="{crmURL q="reset=1&action=add&fid=$fid&sid=$sid"}" class="button"><span><div class="icon add-icon"></div> {ts 1=$fieldTitle}New Option for '%1'{/ts}</span></a>
+      </div>
+    {/if}
+  </div>
 
 {else}
-    {if $action eq 16}
-        <div class="messages status no-popup">
-          <img src="{$config->resourceBase}i/Inform.gif" alt="{ts}status{/ts}"/>
-           {capture assign=crmURL}{crmURL p='civicrm/admin/price/field/option' q="action=add&fid=$fid&sid=$sid"}{/capture}{ts 1=$fieldTitle 2=$crmURL}There are no options for the price field '%1', <a href='%2'>add one</a>.{/ts}
-        </div>
-    {/if}
+  {if $action eq 16}
+    <div class="messages status no-popup">
+      <img src="{$config->resourceBase}i/Inform.gif" alt="{ts}status{/ts}"/>
+      {capture assign=crmURL}{crmURL p='civicrm/admin/price/field/option' q="action=add&fid=$fid&sid=$sid"}{/capture}{ts 1=$fieldTitle 2=$crmURL}There are no options for the price field '%1', <a href='%2'>add one</a>.{/ts}
+    </div>
+  {/if}
 {/if}