Beispiel #1
0
 public function recent()
 {
     $logs = AVLog::orderBy('updated_at', 'DESC')->take(15)->get();
     foreach ($logs as $log) {
         $log->username = User::where('id', '=', $log->uid)->pluck('fullname');
     }
     return $logs->toJson();
 }