mirror of
https://gitee.com/ulthon/ulthon_information.git
synced 2026-03-03 16:24:28 +08:00
优化分类说明
This commit is contained in:
@@ -21,10 +21,11 @@ class Index extends Common
|
||||
{
|
||||
//
|
||||
$sub_category = [];
|
||||
$current_category = [];
|
||||
|
||||
if(!empty($this->request->param('category_id'))){
|
||||
$sub_category = Category::where('pid',$this->request->param('category_id'))->where('type',3)->select();
|
||||
|
||||
$current_category = Category::find($this->request->param('category_id'));
|
||||
if(empty($this->request->param('sub_category_id'))){
|
||||
$categorys = [$this->request->param('category_id')];
|
||||
|
||||
@@ -52,6 +53,7 @@ class Index extends Common
|
||||
|
||||
$list_post = $model_post->paginate();
|
||||
|
||||
View::assign('current_category',$current_category);
|
||||
View::assign('sub_category',$sub_category);
|
||||
|
||||
View::assign('list_post',$list_post);
|
||||
|
||||
Reference in New Issue
Block a user