Add a loby when the challenge isn't started
This commit is contained in:
parent
19f744a11c
commit
9feade7286
@ -130,6 +130,17 @@ else if ($n && $p[0] == SALT_USER)
|
||||
require("public/home.php");
|
||||
$page = "teams/list";
|
||||
}
|
||||
|
||||
else if (empty($VAR["start_challenge"]) || $VAR["start_challenge"] < time())
|
||||
{
|
||||
$TEAM = new Team($p[1]);
|
||||
$template->assign("my_team", $TEAM);
|
||||
$template->assign("themes", Theme::get_themes());
|
||||
|
||||
require("team/me.php");
|
||||
$page = "teams/lobby";
|
||||
}
|
||||
|
||||
else
|
||||
{
|
||||
$TEAM = new Team($p[1]);
|
||||
|
@ -9,7 +9,7 @@ if (count($p) > 2)
|
||||
switch($p[2])
|
||||
{
|
||||
case "start":
|
||||
file_put_contents($VAR["misc_dir"]."/challenge_started", time());
|
||||
file_put_contents($VAR["misc_dir"]."/challenge_started", time() + 42);
|
||||
break;
|
||||
|
||||
case "init":
|
||||
|
55
onyx/tpl/bootstrap/teams/lobby.tpl
Normal file
55
onyx/tpl/bootstrap/teams/lobby.tpl
Normal file
@ -0,0 +1,55 @@
|
||||
{extends file="layout.tpl"}
|
||||
|
||||
{block name=head}
|
||||
<link href="/css/home.css" rel="stylesheet">
|
||||
<link href="/css/score.css" rel="stylesheet">
|
||||
<meta http-equiv="refresh" content="30">
|
||||
{block name=head2}{/block}
|
||||
{/block}
|
||||
|
||||
{block name=end}
|
||||
<script src="/js/countdown.js"></script>
|
||||
<script type="text/javascript">
|
||||
update_end();
|
||||
</script>
|
||||
{/block}
|
||||
|
||||
{block name=content}
|
||||
{include file="clock.tpl"}
|
||||
<div class="container" style="margin-top: 25px">
|
||||
<div class="alert alert-success">
|
||||
<strong>Bienvenue sur le serveur du challenge !</strong>
|
||||
Vous êtes connecté en tant qu'équipe <em>{$my_team->get_name()}</em>.
|
||||
Le challenge n'est pas encore commencé.<br>
|
||||
Profitez-en pour vérifier l'exactitude des informations ci-dessous.
|
||||
</div>
|
||||
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">Information sur l'équipe</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
{if not empty($members)}
|
||||
<table class="table table-striped table-hover">
|
||||
<thead><tr>
|
||||
<th>Prénom</th>
|
||||
<th>Nom</th>
|
||||
<th>Pseudonyme</th>
|
||||
<th>Entreprise</th>
|
||||
</tr></thead>
|
||||
<tbody>
|
||||
{foreach from=$members item=member}
|
||||
</tr>
|
||||
<td>{$member->firstname}</td>
|
||||
<td>{$member->lastname}</td>
|
||||
<td>{$member->nickname}</td>
|
||||
<td>{$member->company}</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
</tbody>
|
||||
</table>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
Loading…
Reference in New Issue
Block a user