Added date to cache reports list; reverse order of cache reports list

This commit is contained in:
flopp
2012-08-13 01:54:25 +02:00
committed by following
parent ea2be4b47a
commit 66869d74ce
2 changed files with 5 additions and 4 deletions
+3 -2
View File
@@ -113,13 +113,14 @@
$rs = sql("SELECT `cr`.`id`,
IF(`cr`.`status`=1,'(*) ', '') AS `new`,
`c`.`name`,
`u`.`username`
`u`.`username`,
`cr`.`lastmodified`
FROM `cache_reports` `cr`
INNER JOIN `caches` `c` ON `c`.`cache_id` = `cr`.`cacheid`
INNER JOIN `user` `u` ON `u`.`user_id` = `cr`.`userid`
WHERE `cr`.`status` < 3
AND (`cr`.`adminid` IS NULL OR `cr`.`adminid`=&1)
ORDER BY `cr`.`status` DESC, `cr`.`lastmodified` DESC",
ORDER BY `cr`.`status` DESC, `cr`.`lastmodified` ASC",
$login->userid);
$tpl->assign_rs('reportedcaches', $rs);
+1 -1
View File
@@ -28,7 +28,7 @@
{if $list == true}
<ul>
{foreach from=$reportedcaches item=rc}
<li><a href="adminreports.php?id={$rc.id}">{$rc.new|escape}{$rc.name|escape} reported by {$rc.username|escape}</a></li>
<li><a href="adminreports.php?id={$rc.id}">{$rc.new|escape}{$rc.name|escape} reported by {$rc.username|escape} ({$rc.lastmodified|date_format:$opt.format.datelong})</a></li>
{foreachelse}
<li>{t}No reported caches{/t}</li>
{/foreach}