コード例 #1
0
 /**
  * Display a listing of the resource.
  *
  * @return \Illuminate\Http\Response
  */
 public function index()
 {
     $list = Posts::orderBy('created_at', 'desc')->cates()->get();
     return response()->json($list);
 }