server/onyx/tpl/bootstrap/public/home.tpl

56 lines
1.5 KiB
Smarty

{extends file="public/layout.tpl"}
{block name=head2}
<meta http-equiv="refresh" content="{10*(count($teams)+1)}">
{/block}
{block name=main}
{if isset($teams)}
<div id="carousel-team" class="carousel slide">
<div class="carousel-inner">
<div class="item active">
<div class="well">
<table class="table" style="font-size: 14px;">
<thead>
<tr>
<th></th>
{for $i=1 to $nbExoMax}
<th class="text-center">Exercice {$i}</th>
{/for}
</tr>
</thead>
<tbody>
{$total=0}
{foreach from=$themes item=theme}
<tr>
<th>{$theme->get_name()}</th>
{$themeID=$theme->get_id()}
{foreach from=$theme->get_exercices_ordered() item=exo}
{$teamName=""}
{for $i=0 to $nbExoMax}
{$teamName=$exo->first_to_solve_exercice()}
{/for}
{if $teamName != ""}
<td class="success text-center">{$teamName|replace:"_":" "}</td>
{else}
<td class="danger text-center"></td>
{/if}
{/foreach}
</tr>
{/foreach}
</tbody>
</table>
</div>
</div>
{foreach from=$teams item=my_team key=k}
<div class="item">
<div class="well">
{include file="summary.tpl"}
</div>
</div>
{/foreach}
</div>
</div>
{/if}
{/block}