You've already forked lubo_comment_query
							
							支持直接从评论中一键生成节目
This commit is contained in:
		| @@ -10,9 +10,16 @@ class VideoQueryController extends BaseController | ||||
| { | ||||
|     public function info(Request $request, Videos $video) | ||||
|     { | ||||
|         $pivots = $video->program_pivots; | ||||
|         if (sizeof($pivots) === 0) { | ||||
|             $comment = $video->comments()->where("is_top", "=", 1)->first(); | ||||
|         } else { | ||||
|             $comment = null; | ||||
|         } | ||||
|         return view("video.index", [ | ||||
|             "video" => $video, | ||||
|             "video_pivots" => $video->program_pivots | ||||
|             "video_pivots" => $pivots, | ||||
|             "comment" => $comment, | ||||
|         ]); | ||||
|     } | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user