fix: 修复between校验错误
This commit is contained in:
@@ -326,7 +326,8 @@ public abstract class SimpleServiceSupport<ENTITY extends SimpleEntity> implemen
|
||||
queryable.getBetween().forEach((column, value) -> {
|
||||
var path = this.<Comparable<Object>>column(root, column);
|
||||
checkComparable(path, column);
|
||||
checkComparable(value, column);
|
||||
checkComparable(value.getStart(), column);
|
||||
checkComparable(value.getEnd(), column);
|
||||
predicates.add(builder.between(column(root, column), (Comparable<Object>) value.getStart(), (Comparable<Object>) value.getEnd()));
|
||||
});
|
||||
}
|
||||
@@ -334,7 +335,8 @@ public abstract class SimpleServiceSupport<ENTITY extends SimpleEntity> implemen
|
||||
queryable.getNotBetween().forEach((column, value) -> {
|
||||
var path = this.<Comparable<Object>>column(root, column);
|
||||
checkComparable(path, column);
|
||||
checkComparable(value, column);
|
||||
checkComparable(value.getStart(), column);
|
||||
checkComparable(value.getEnd(), column);
|
||||
predicates.add(builder.between(column(root, column), (Comparable<Object>) value.getStart(), (Comparable<Object>) value.getEnd()).not());
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user