vgi as $key=>$value){ // $videoInfo = $this->getVideo($value->post_id); // if($videoInfo){ // $value['username']= $videoInfo['username']; // $value['topic']= $videoInfo['topic']; // $value['video']= $videoInfo['video']; // $value['pv']= $videoInfo['pv']; // $value['praise_count']= $videoInfo['praise_count']; // } // $video[] = $value; // } return [ 'id' => $videoGroup['id'], 'name' => $videoGroup['name'], 'created_at' => Carbon::parse($videoGroup['created_at'])->toDateTimeString(), 'video_list'=>$video ]; } // public function getVideo($id) { // try { // // $sign = generateSign(['id'=>$id], config('customer.app_secret')); // // $url = config("customer.manage_service_url").'/community/post/detail'; // $url = 'https://manage.dev.caihongxingqiu.com/community/post/detail'; // //$url = 'http://localhost:8080/userInfo'; // $array = [ // 'json' => ['id'=>$id], 'query' => [], 'http_errors' => false,'headers'=>['Authorization'=>"Bearer ".JWTAuth::getToken()] // ]; // $res = http($url,$array,true,'get'); // return $res; // } catch (\Exception $e) { // return []; // } // } }