mirror of
https://github.com/NNTmux/newznab-tmux.git
synced 2026-08-28 17:01:16 +00:00
Fix site stats admin page
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
2019-03-20 DariusIII
|
||||
* Fix: Fix site stats admin page
|
||||
* Chg: Update return type declarations on adult postprocessing classes
|
||||
* Chg: Update dariusiii/rarinfo (v2.7.4 => v2.7.4.1)
|
||||
* Chg: Update dariusiii/rarinfo (v2.7.3 => v2.7.4)
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Support\Facades\DB;
|
||||
use Watson\Rememberable\Rememberable;
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
@@ -276,8 +277,7 @@ class Category extends Model
|
||||
->with('parent')
|
||||
->remember(config('nntmux.cache_expiry_long'))
|
||||
->where('r.adddate', '>', now()->subWeek())
|
||||
->selectRaw('CONCAT(cp.title, " > ", categories.title) as title')
|
||||
->selectRaw('COUNT(r.id) as count')
|
||||
->select(['root_categories_id', DB::raw('COUNT(r.id) as count'), 'title'])
|
||||
->join('releases as r', 'r.categories_id', '=', 'categories.id')
|
||||
->groupBy('title')
|
||||
->orderBy('count', 'desc')
|
||||
|
||||
@@ -106,7 +106,7 @@
|
||||
|
||||
{foreach from=$recent item=result}
|
||||
<tr class="{cycle values=",alt"}">
|
||||
<td width="75%">{$result->title}</td>
|
||||
<td>{$result->parent->title} > {$result->title}</td>
|
||||
<td>{$result.count}</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
|
||||
Reference in New Issue
Block a user