Ignore:
Timestamp:
May 13, 2010, 10:12:38 PM (14 years ago)
Author:
grum
Message:

Improve functionnalities for GPCTabSheet and GPCRequestBuilder classes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/GrumPluginClasses/templates/GPCTabSheet.tpl

    r5918 r6174  
    11{if isset($tabsheet) and count($tabsheet)}
    22<ul {if isset($tabsheet_classes)}class="{$tabsheet_classes}"{/if} {if isset($tabsheet_id)}id="{$tabsheet_id}"{/if} >
    3 {foreach from=$tabsheet key=name item=sheet}
    4   <li class="{if ($name == $tabsheet_selected)}selected_tab{else}normal_tab{/if}">
    5     <a href="{$sheet.url}"><span>{$sheet.caption}</span></a>
     3{foreach from=$tabsheet key=name item=sheet name=tabs}
     4  <li {if isset($tabsheet_id)}id="{$tabsheet_id}{$smarty.foreach.tabs.index}"{/if} class="{if ($name == $tabsheet_selected)}selected_tab{else}normal_tab{/if}">
     5    <a {if $sheet.url!=''}href="{$sheet.url}"{/if} {if $sheet.onClick!=''}onclick="{$sheet.onClick}"{/if} ><span>{$sheet.caption}</span></a>
    66  </li>
    77{/foreach}
    88</ul>
     9
     10  {if isset($tabsheet_id)}
     11  {literal}
     12  <script type="text/javascript">
     13    $('#{/literal}{$tabsheet_id}{literal} li').bind('click',
     14      function ()
     15      {
     16        $('#{/literal}{$tabsheet_id}{literal} li').removeClass('selected_tab').addClass('normal_tab');
     17        $(this).removeClass('normal_tab').addClass('selected_tab');
     18      }
     19    );
     20  {/literal}
     21  </script>
     22
     23  {/if}
     24
    925{/if}
Note: See TracChangeset for help on using the changeset viewer.