-
$goodsShow = Goods::where('cate_id','=',$cate_id)
-
->where(function($query){
-
$query->where('status','<','61')
-
->orWhere(function($query){
-
$query->where('status', '91');
-
});
-
})->first();
-
这一段其实执行的就是
where cate_id = $cate_id AND (status < 61 OR status = 91)
06-25
18
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
04-17
455
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
12-01
411
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
“相关推荐”对你有帮助么?
-
非常没帮助
-
没帮助
-
一般
-
有帮助
-
非常有帮助
提交