diff --git a/server/src/main/kotlin/com/fone/jobOpening/infrastructure/JobOpeningRepositoryImpl.kt b/server/src/main/kotlin/com/fone/jobOpening/infrastructure/JobOpeningRepositoryImpl.kt index 036719e5..6c425a55 100644 --- a/server/src/main/kotlin/com/fone/jobOpening/infrastructure/JobOpeningRepositoryImpl.kt +++ b/server/src/main/kotlin/com/fone/jobOpening/infrastructure/JobOpeningRepositoryImpl.kt @@ -103,7 +103,7 @@ class JobOpeningRepositoryImpl( from(entity(JobOpening::class)) where( and( - col(JobOpening::type).equal(request.type), + if (request.genders.isNotEmpty()) col(JobOpening::type).equal(request.type) else null, col(JobOpening::gender).inValues(request.genders), col(JobOpening::ageMax).greaterThanOrEqualTo(request.ageMin), col(JobOpening::ageMin).lessThanOrEqualTo(request.ageMax),