Файл: _modules/main/donat/journal/index.php
Строк: 31
<?php
# mark core v1.0
# author Drk in
# date 24.10.19
# core
require_once ( $_SERVER['DOCUMENT_ROOT']."/_core/system.php" );
# user
system::access(true);
# meta
$title = 'Магазин - журнал операций:: '.domain;
# head
require_once ( head );
echo '<div class="fights fights-about"><div class="grid">Журнал операций</div></div>';
$cn = DB :: $dbh -> querySingle("SELECT count(id) FROM journal WHERE user = ?;", array($user['id']));
if ($cn == 0)echo '<div class="dialog"><h1 class="pda">КПК</h1><p>› Cписок операций пуст<br></p></div>';
$page = new page($cn);
$limit = $cn > $page -> elements ? $page -> limit : null;
$query = DB :: $dbh -> query("SELECT id FROM journal WHERE user = ? ORDER BY time DESC {$limit}", array($user['id']));
while ($act = $query -> fetch()):
$act = cache_journal::get($act['id']);
echo '
<div class="fights fights-about">
<span class="pull-right small" style="color: #ccc;">
'.system::time($act['time']).'
</span>
'.($act['sn'] == 0 ? '<font color="#ff6837">-':'<font color="#61a961">+').''.$act['price'].'</font> <img src="'.ico.'dollar.png" width="10px">
<br>'.system::check($act['mess']).'
</div>
';
endwhile;
$page -> get('?');
echo'
<div class="fights-link" style="margin: 5px;"><a href="/main/donat">Вернуться назад</a></div>
<div class="line"></div>
';
# foot
require_once ( foot );
?>