/admin/ highscores
This commit is contained in:
@@ -2,6 +2,11 @@
|
||||
<html lang="en">
|
||||
<?php
|
||||
require_once (__DIR__ . '/../internals/base.php');
|
||||
require_once (__DIR__ . '/../internals/highscores.php');
|
||||
require_once (__DIR__ . '/../internals/alephnoteStatistics.php');
|
||||
|
||||
Database::connect();
|
||||
|
||||
?>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
@@ -23,18 +28,22 @@ require_once (__DIR__ . '/../internals/base.php');
|
||||
|
||||
<div class="contentheader"><h1>Admin</h1><hr/></div>
|
||||
|
||||
<!------------------------------------------>
|
||||
|
||||
<div class="boxedcontent">
|
||||
<div class="bc_header">Version</div>
|
||||
|
||||
<div class="bc_data">
|
||||
<div><b style="display:inline-block; min-width: 100px">Branch: </b><span><?php echo exec('git rev-parse --abbrev-ref HEAD'); ?></span></div>
|
||||
<div><b style="display:inline-block; min-width: 100px">Commit: </b><span><?php echo exec('git rev-parse HEAD'); ?></span></div>
|
||||
<div><b style="display:inline-block; min-width: 100px">Date: </b><span><?php echo exec('git log -1 --format=%cd'); ?></span></div>
|
||||
<div><b style="display:inline-block; min-width: 100px">Message: </b><span><?php echo nl2br(exec('git log -1')); ?></span></div>
|
||||
<div class="bc_data keyvaluelist kvl_100">
|
||||
<div><span>Branch:</span> <span><?php echo exec('git rev-parse --abbrev-ref HEAD'); ?></span></div>
|
||||
<div><span>Commit:</span> <span><?php echo exec('git rev-parse HEAD'); ?></span></div>
|
||||
<div><span>Date:</span> <span><?php echo exec('git log -1 --format=%cd'); ?></span></div>
|
||||
<div><span>Message:</span><span><?php echo nl2br(trim(exec('git log -1'))); ?></span></div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<!------------------------------------------>
|
||||
|
||||
<div class="boxedcontent">
|
||||
<div class="bc_header">ExtendedGitGraph</div>
|
||||
|
||||
@@ -46,6 +55,46 @@ require_once (__DIR__ . '/../internals/base.php');
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="boxedcontent">
|
||||
<div class="bc_header">AlephNote</div>
|
||||
|
||||
<div class="bc_data">
|
||||
<div class="keyvaluelist kvl_200">
|
||||
<div><span>Total users:</span> <span><?php echo 0; ?></span></div>
|
||||
<div><span>Users on latest version:</span> <span><?php echo 0; ?></span></div>
|
||||
<div><span>Active users:</span> <span><?php echo 0; ?></span></div>
|
||||
</div>
|
||||
|
||||
<div id="an_ajax_target"></div>
|
||||
|
||||
<a class="button" href="javascript:showAlephNoteData('<?php echo $CONFIG['ajax_secret'] ?>')">Show</a>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="boxedcontent">
|
||||
<div class="bc_header">Highscores</div>
|
||||
|
||||
<div class="bc_data keyvaluelist kvl_300">
|
||||
|
||||
<?php foreach (Highscores::getAllGames() as $game): ?>
|
||||
|
||||
<div><span><?php echo '[' . $game['NAME'] . '] Entries:' ?></span> <span><a href="/Highscores/list?gameid=<?php echo $game['ID']; ?>"><?php echo Highscores::getEntryCountFromGame($game['ID']); ?></a></span></div>
|
||||
<div><span><?php echo '[' . $game['NAME'] . '] Highscore:' ?></span> <span><?php
|
||||
$hs = Highscores::getOrderedEntriesFromGame($game['ID'], 1)[0];
|
||||
echo $hs['POINTS'] . ' (' . $hs['PLAYER'] . ') @ ' . $hs['TIMESTAMP'];
|
||||
?></span></div>
|
||||
<div><span><?php echo '[' . $game['NAME'] . '] Last Update:' ?></span> <span><?php echo Highscores::getNewestEntriesFromGame($game['ID'], 1)[0]['TIMESTAMP']; ?></span></div>
|
||||
|
||||
<hr />
|
||||
|
||||
<?php endforeach; ?>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user