|
@@ -61,14 +61,14 @@ public function title(){
|
|
}
|
|
}
|
|
$pid=isset($this->post['pid']) && $this->post['pid'] !==""? intval($this->post['pid']) :"";
|
|
$pid=isset($this->post['pid']) && $this->post['pid'] !==""? intval($this->post['pid']) :"";
|
|
if($pid!==""){
|
|
if($pid!==""){
|
|
- $where[]=['pid',"=",$pid];
|
|
|
|
|
|
+ $where[]=["pid","=",$pid];
|
|
}
|
|
}
|
|
$status=isset($this->post['status']) && $this->post['status'] !==""? intval($this->post['status']) :"";
|
|
$status=isset($this->post['status']) && $this->post['status'] !==""? intval($this->post['status']) :"";
|
|
if($status!==""){
|
|
if($status!==""){
|
|
$where[]=['status',"=",$status];
|
|
$where[]=['status',"=",$status];
|
|
}
|
|
}
|
|
- $list = Db::name('cat')->where(['is_del'=>0])->select();
|
|
|
|
- return app_show(0, "获取成功", $list);
|
|
|
|
|
|
+ $list = Db::name('cat')->where([$where])->select();
|
|
|
|
+ return app_show(0, "获取成功",$list);
|
|
}
|
|
}
|
|
public function create()
|
|
public function create()
|
|
{
|
|
{
|