$where=" and (`title` like '%".$searchValue."%' or `code` like '%".$searchValue."%') ";
$where.=" and (mw.`title` like '".$searchValue."%' or mw.`code` = '".$searchValue."') ";
}
}
$model=newModel();
$model=newModel();
//======================
//======================
$fields="count(id) count";
$fields="count(1) count";
//返回列表(limit分页)
//返回列表(limit分页)
if($queryType=="list"){
if($queryType=="list"){
$where.=$sort." ".$limit;
$where.=$sort." ".$limit;
$fields=" *,case `status` when 1 then '<font color=green>上线</font>' when 2 then '<font color=red>下线</font>' when 0 then '<font>未知</font>' end as `status` ";