|
@@ -98,7 +98,7 @@ class Article extends Model
|
|
|
$ids = get_all_categories(ArticleCategory::lst(['cid'=>$where['cid']]),$where['ifyid']);
|
|
|
$xwhere['article_category_id'] =['in',$ids];
|
|
|
}
|
|
|
- if(isset($where['key']) && $where['key']!='') $xwhere['article_category_id'] = ['like',"%{$where['key']}%"];
|
|
|
+ if(isset($where['key']) && $where['key']!='') $xwhere['title|info'] = ['like',"%{$where['key']}%"];
|
|
|
$list = $model->where($xwhere)->order('sort desc,id desc')->page($where['page'],$where['limit'])->select();
|
|
|
$count = $model->where($xwhere)->count();
|
|
|
return compact('count','list');
|