mirror of
https://github.com/crmeb/CRMEB.git
synced 2025-12-15 21:32:50 +00:00
修复文章提示不存在
This commit is contained in:
parent
ef1089196c
commit
84869acc8b
@ -21,7 +21,9 @@ class ArticleCategory extends ModelBasic
|
||||
public static function cidByArticleList($cid, $first, $limit, $field = '*')
|
||||
{
|
||||
$model = Db::name('article');
|
||||
if ($cid) $model->where("CONCAT(',',cid,',')", 'LIKE', "'%,$cid,%'");
|
||||
return $model->field($field)->where('status', 1)->where('hide', 0)->order('sort DESC,add_time DESC')->limit($first, $limit)->select();
|
||||
//if ($cid) $model->where("CONCAT(',',cid,',')", 'LIKE', "'%,$cid,%'");
|
||||
if ($cid) $model->where('cid',$cid);
|
||||
return $model->field($field)->where('status', 1)->where('hide', 0)->order('sort DESC,add_time DESC')->limit($first, $limit)->select();
|
||||
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user