diff --git a/backend/core/src/main/java/org/opencdmp/query/ActionConfirmationQuery.java b/backend/core/src/main/java/org/opencdmp/query/ActionConfirmationQuery.java index 12cda1aa8..f7f06de8e 100644 --- a/backend/core/src/main/java/org/opencdmp/query/ActionConfirmationQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/ActionConfirmationQuery.java @@ -203,7 +203,7 @@ public class ActionConfirmationQuery extends QueryBase @Override protected Predicate applyFilters(QueryContext queryContext) { List predicates = new ArrayList<>(); - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(ActionConfirmationEntity._token), this.like)); } if (this.ids != null) { diff --git a/backend/core/src/main/java/org/opencdmp/query/DescriptionQuery.java b/backend/core/src/main/java/org/opencdmp/query/DescriptionQuery.java index e69754815..731fb3018 100644 --- a/backend/core/src/main/java/org/opencdmp/query/DescriptionQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/DescriptionQuery.java @@ -272,7 +272,7 @@ public class DescriptionQuery extends QueryBase { @Override protected Predicate applyFilters(QueryContext queryContext) { List predicates = new ArrayList<>(); - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(queryContext.CriteriaBuilder.or( this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(DescriptionEntity._description), this.like), this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(DescriptionEntity._label), this.like) diff --git a/backend/core/src/main/java/org/opencdmp/query/DescriptionTemplateQuery.java b/backend/core/src/main/java/org/opencdmp/query/DescriptionTemplateQuery.java index df790e8b5..b732aa76e 100644 --- a/backend/core/src/main/java/org/opencdmp/query/DescriptionTemplateQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/DescriptionTemplateQuery.java @@ -310,7 +310,7 @@ public class DescriptionTemplateQuery extends QueryBase { predicates.add(notInClause.not()); } - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(DmpBlueprintEntity._label), this.like)); } diff --git a/backend/core/src/main/java/org/opencdmp/query/DmpQuery.java b/backend/core/src/main/java/org/opencdmp/query/DmpQuery.java index 89024508d..959beb2bd 100644 --- a/backend/core/src/main/java/org/opencdmp/query/DmpQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/DmpQuery.java @@ -302,7 +302,7 @@ public class DmpQuery extends QueryBase { @Override protected Predicate applyFilters(QueryContext queryContext) { List predicates = new ArrayList<>(); - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(DmpEntity._label), this.like)); } if (this.ids != null) { diff --git a/backend/core/src/main/java/org/opencdmp/query/LanguageQuery.java b/backend/core/src/main/java/org/opencdmp/query/LanguageQuery.java index c9b7ac9c2..dc28f7a8a 100644 --- a/backend/core/src/main/java/org/opencdmp/query/LanguageQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/LanguageQuery.java @@ -148,7 +148,7 @@ public class LanguageQuery extends QueryBase { inClause.value(item); predicates.add(inClause); } - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(LanguageEntity._code), this.like)); } if (this.isActives != null) { diff --git a/backend/core/src/main/java/org/opencdmp/query/PrefillingSourceQuery.java b/backend/core/src/main/java/org/opencdmp/query/PrefillingSourceQuery.java index 3d73e7449..1db07cd5f 100644 --- a/backend/core/src/main/java/org/opencdmp/query/PrefillingSourceQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/PrefillingSourceQuery.java @@ -149,7 +149,7 @@ public class PrefillingSourceQuery extends QueryBase { inClause.value(item); predicates.add(inClause); } - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(queryContext.CriteriaBuilder.or(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(PrefillingSourceEntity._code), this.like), this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(PrefillingSourceEntity._label), this.like) )); diff --git a/backend/core/src/main/java/org/opencdmp/query/ReferenceQuery.java b/backend/core/src/main/java/org/opencdmp/query/ReferenceQuery.java index 42be7a255..6589e6ca9 100644 --- a/backend/core/src/main/java/org/opencdmp/query/ReferenceQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/ReferenceQuery.java @@ -269,7 +269,7 @@ public class ReferenceQuery extends QueryBase { inClause.value(item); predicates.add(inClause); } - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(queryContext.CriteriaBuilder.or(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(ReferenceEntity._label), this.like), this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(ReferenceEntity._description), this.like), this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(ReferenceEntity._reference), this.like) diff --git a/backend/core/src/main/java/org/opencdmp/query/ReferenceTypeQuery.java b/backend/core/src/main/java/org/opencdmp/query/ReferenceTypeQuery.java index 8500a37f0..7f23df2fd 100644 --- a/backend/core/src/main/java/org/opencdmp/query/ReferenceTypeQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/ReferenceTypeQuery.java @@ -150,7 +150,7 @@ public class ReferenceTypeQuery extends QueryBase { inClause.value(item); predicates.add(inClause); } - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(queryContext.CriteriaBuilder.or(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(ReferenceTypeEntity._code), this.like), this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(ReferenceTypeEntity._name), this.like) )); diff --git a/backend/core/src/main/java/org/opencdmp/query/StorageFileQuery.java b/backend/core/src/main/java/org/opencdmp/query/StorageFileQuery.java index 44221b782..6419bca73 100644 --- a/backend/core/src/main/java/org/opencdmp/query/StorageFileQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/StorageFileQuery.java @@ -167,7 +167,7 @@ public class StorageFileQuery extends QueryBase { @Override protected Predicate applyFilters(QueryContext queryContext) { List predicates = new ArrayList<>(); - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(StorageFileEntity._name), this.like)); } if (this.ids != null) { diff --git a/backend/core/src/main/java/org/opencdmp/query/SupportiveMaterialQuery.java b/backend/core/src/main/java/org/opencdmp/query/SupportiveMaterialQuery.java index 3f2b6dd4e..3b21565a9 100644 --- a/backend/core/src/main/java/org/opencdmp/query/SupportiveMaterialQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/SupportiveMaterialQuery.java @@ -166,7 +166,7 @@ public class SupportiveMaterialQuery extends QueryBase inClause.value(item); predicates.add(inClause); } - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(queryContext.CriteriaBuilder.or(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(SupportiveMaterialEntity._languageCode), this.like), this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(SupportiveMaterialEntity._payload), this.like) )); diff --git a/backend/core/src/main/java/org/opencdmp/query/TagQuery.java b/backend/core/src/main/java/org/opencdmp/query/TagQuery.java index d519ff765..f0b591cd2 100644 --- a/backend/core/src/main/java/org/opencdmp/query/TagQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/TagQuery.java @@ -228,7 +228,7 @@ public class TagQuery extends QueryBase { @Override protected Predicate applyFilters(QueryContext queryContext) { List predicates = new ArrayList<>(); - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(TagEntity._label), this.like)); } if (this.ids != null) { diff --git a/backend/core/src/main/java/org/opencdmp/query/TenantQuery.java b/backend/core/src/main/java/org/opencdmp/query/TenantQuery.java index 47d539ad5..c28793d26 100644 --- a/backend/core/src/main/java/org/opencdmp/query/TenantQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/TenantQuery.java @@ -151,7 +151,7 @@ public class TenantQuery extends QueryBase { predicates.add(inClause); } - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(queryContext.CriteriaBuilder.or(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(TenantEntity._code), this.like), this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(TenantEntity._name), this.like) )); diff --git a/backend/core/src/main/java/org/opencdmp/query/UserQuery.java b/backend/core/src/main/java/org/opencdmp/query/UserQuery.java index 70ce987a9..a6d5fe73d 100644 --- a/backend/core/src/main/java/org/opencdmp/query/UserQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/UserQuery.java @@ -196,7 +196,7 @@ public class UserQuery extends QueryBase { @Override protected Predicate applyFilters(QueryContext queryContext) { List predicates = new ArrayList<>(); - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(UserEntity._name), this.like)); } if (this.ids != null) { diff --git a/backend/core/src/main/java/org/opencdmp/query/UserSettingsQuery.java b/backend/core/src/main/java/org/opencdmp/query/UserSettingsQuery.java index 4f7875228..48fb51427 100644 --- a/backend/core/src/main/java/org/opencdmp/query/UserSettingsQuery.java +++ b/backend/core/src/main/java/org/opencdmp/query/UserSettingsQuery.java @@ -183,7 +183,7 @@ public class UserSettingsQuery extends QueryBase { @Override protected Predicate applyFilters(QueryContext queryContext) { List predicates = new ArrayList<>(); - if (this.like != null && !this.like.isEmpty()) { + if (this.like != null && !this.like.isBlank()) { predicates.add(queryContext.CriteriaBuilder.or(this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(UserSettingsEntity._key), this.like), this.queryUtilsService.ilike(queryContext.CriteriaBuilder, queryContext.Root.get(UserSettingsEntity._value), this.like) ));