这样么?
public function showUser(Request $request)
{
$userType = $request->get('type');
$result = DB::table('cmt_admin_users')
->where('type', $userType)
->get();
return response()->json($result->toArray());
}
或者你在 ready 的 console 打印这个试试:
console.log(response.data)