feat: contests order

This commit is contained in:
Baoshuo Ren 2022-09-20 19:44:40 +08:00
parent 4fabe53a51
commit d9be3be581
Signed by: baoshuo
GPG Key ID: 00CB9680AB29F51A

View File

@ -60,7 +60,7 @@ EOD;
$table_header .= '<th style="width:100px;">'.UOJLocale::get('contests::the number of registrants').'</th>'; $table_header .= '<th style="width:100px;">'.UOJLocale::get('contests::the number of registrants').'</th>';
$table_header .= '<th style="width:180px;">'.UOJLocale::get('appraisal').'</th>'; $table_header .= '<th style="width:180px;">'.UOJLocale::get('appraisal').'</th>';
$table_header .= '</tr>'; $table_header .= '</tr>';
echoLongTable(array('*'), 'contests', "status != 'finished'", 'order by id desc', $table_header, echoLongTable(array('*'), 'contests', "status != 'finished'", 'order by start_time desc, id desc', $table_header,
echoContest, echoContest,
array('page_len' => 40) array('page_len' => 40)
); );
@ -85,7 +85,7 @@ EOD;
<h4><?= UOJLocale::get('contests::ended contests') ?></h4> <h4><?= UOJLocale::get('contests::ended contests') ?></h4>
<?php <?php
echoLongTable(array('*'), 'contests', "status = 'finished'", 'order by id desc', $table_header, echoLongTable(array('*'), 'contests', "status = 'finished'", 'order by start_time desc, id desc', $table_header,
echoContest, echoContest,
array('page_len' => 40, array('page_len' => 40,
'print_after_table' => function() { 'print_after_table' => function() {