diff --git a/app/service/MatchService.php b/app/service/MatchService.php index 8180664..9cc7dc1 100644 --- a/app/service/MatchService.php +++ b/app/service/MatchService.php @@ -199,10 +199,10 @@ class MatchService // 如果是本科及以上,可以匹配"本科"、"本科及以上"等要求 $query->where(function($q) { $q->where('education_require', 'like', '%本科%') - ->orWhere('education_require', 'like', '%硕士%') - ->orWhere('education_require', 'like', '%博士%') - ->orWhere('education_require', '=', '') - ->orWhereNull('education_require'); + ->where('education_require', 'like', '%硕士%', 'or') + ->where('education_require', 'like', '%博士%', 'or') + ->where('education_require', '=', '', 'or') + ->where('education_require', 'null', '', 'or'); }); } } @@ -215,9 +215,9 @@ class MatchService if (!empty($resume['gender'])) { $query->where(function($q) use ($resume) { $q->where('sex_require', '不限制') - ->orWhere('sex_require', $resume['gender']) - ->orWhere('sex_require', '') - ->orWhereNull('sex_require'); + ->where('sex_require', $resume['gender'], 'or') + ->where('sex_require', '', 'or') + ->where('sex_require', 'null', '', 'or'); }); }