我有这个 Laravel 范围代码public function apply(Builder $builder, Model $model){ $builder->whereDoesntHave('getPermissionData');}到目前为止一切正常,我需要的是改善这样的条件public function apply(Builder $builder, Model $model){ /* if($builder->whereHas('getPermissionData')) { check the relation and do some code here } */ $builder->whereDoesntHave('getPermissionData');}这可能吗
1 回答
- 1 回答
- 0 关注
- 134 浏览
添加回答
举报
0/150
提交
取消