使用 scope 后无法进行分页?
使用scope 后无法进行分页
public function scopePublished($query){
$query->where('published_at', '<=', Carbon::now())->paginate(config('options.article_per_page'));
}
没有返回totel和page
推荐文章: