where([ ['uid', $uid], ['state', 0], ['validity_time', '>', time()] ])->whereIn('type', $types)->orderBy('get_time', 'desc')->get(); return $tickets; } }