@@ -44,15 +44,15 @@ |
||
| 44 | 44 | { |
| 45 | 45 | $now = Carbon::now()->subDays($days)->setTime(0, 0); |
| 46 | 46 | $logs = $this->getTable()->where('user_id', $user->username) |
| 47 | - ->where('time', $now, '>') |
|
| 48 | - ->orderBy('time', 'asc') |
|
| 49 | - ->get(); |
|
| 47 | + ->where('time', $now, '>') |
|
| 48 | + ->orderBy('time', 'asc') |
|
| 49 | + ->get(); |
|
| 50 | 50 | |
| 51 | 51 | if ($logs->count() < 10) { |
| 52 | 52 | $logs = $this->getTable()->where('user_id', $user->username) |
| 53 | - ->limit(10) |
|
| 54 | - ->orderBy('time', 'desc') |
|
| 55 | - ->get(); |
|
| 53 | + ->limit(10) |
|
| 54 | + ->orderBy('time', 'desc') |
|
| 55 | + ->get(); |
|
| 56 | 56 | $logs = $logs->reverse(); |
| 57 | 57 | } |
| 58 | 58 | |
@@ -40,9 +40,9 @@ discard block |
||
| 40 | 40 | protected function mapApiRoutes() |
| 41 | 41 | { |
| 42 | 42 | Route::prefix('judge') |
| 43 | - // ->middleware('judge') |
|
| 44 | - ->namespace($this->namespace) |
|
| 45 | - ->group(base_path('routes/judge.php')); |
|
| 43 | + // ->middleware('judge') |
|
| 44 | + ->namespace($this->namespace) |
|
| 45 | + ->group(base_path('routes/judge.php')); |
|
| 46 | 46 | } |
| 47 | 47 | |
| 48 | 48 | /** |
@@ -55,15 +55,15 @@ discard block |
||
| 55 | 55 | protected function mapWebRoutes() |
| 56 | 56 | { |
| 57 | 57 | Route::middleware('web') |
| 58 | - ->namespace($this->namespace) |
|
| 59 | - ->group(base_path('routes/web.php')); |
|
| 58 | + ->namespace($this->namespace) |
|
| 59 | + ->group(base_path('routes/web.php')); |
|
| 60 | 60 | } |
| 61 | 61 | |
| 62 | 62 | private function mapAdminRoutes() |
| 63 | 63 | { |
| 64 | 64 | Route::prefix('admin') |
| 65 | - ->middleware('admin') |
|
| 66 | - ->namespace($this->namespace) |
|
| 67 | - ->group(base_path('routes/admin.php')); |
|
| 65 | + ->middleware('admin') |
|
| 66 | + ->namespace($this->namespace) |
|
| 67 | + ->group(base_path('routes/admin.php')); |
|
| 68 | 68 | } |
| 69 | 69 | } |