有时候搜索要用到比如select * from user where id > ? and (pid = ? or uid = ? )
$user = User::where('id','>','10')
    ->where(function($q1) use($pid,$uid){
        $q1->orWhere('pid',$pid)
        ->orWhere('uid',$uid);
    })->get();
如果还有条件,在->get()前继续写,按照上面方式继续写即可!
当你能力不能满足你的野心的时候,你就该沉下心来学习