ct as $key=>$value){ $category[] = $value->category; } return [ 'id' => $topic['id'], 'name' => $topic['name'], 'img' => $topic['img'], 'is_suggest' => $topic['is_suggest'], 'is_hot' => $topic['is_hot'], 'is_open' => $topic['is_open'], 'desc' => $topic['desc'], 'post_count' => 0, 'follow_count' => 0, 'page_count' => 0, 'created_at' => Carbon::parse($topic['created_at'])->toDateTimeString(), 'category_list'=>$category, 'circle_id'=>$topic['circle_id'], 'base_count'=>$topic['base_count'], ]; } }