mirror of
https://gitee.com/dromara/MilvusPlus.git
synced 2025-12-06 08:58:26 +08:00
commit
6cabf65f5c
@ -31,7 +31,7 @@
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>milvus-plus-core</artifactId>
|
||||
<version>2.1.5</version>
|
||||
<version>2.1.6</version>
|
||||
</dependency>
|
||||
```
|
||||
|
||||
@ -41,7 +41,7 @@ Spring应用支持:
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>milvus-plus-boot-starter</artifactId>
|
||||
<version>2.1.5</version>
|
||||
<version>2.1.6</version>
|
||||
</dependency>
|
||||
```
|
||||
|
||||
@ -51,7 +51,7 @@ Solon应用支持:
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>milvus-plus-solon-plugin</artifactId>
|
||||
<version>2.1.5</version>
|
||||
<version>2.1.6</version>
|
||||
</dependency>
|
||||
```
|
||||
|
||||
|
||||
@ -29,7 +29,7 @@ Custom extension support:
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>milvus-plus-core</artifactId>
|
||||
<version>2.1.5</version>
|
||||
<version>2.1.6</version>
|
||||
</dependency>
|
||||
```
|
||||
|
||||
@ -39,7 +39,7 @@ Spring application support:
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>milvus-plus-boot-starter</artifactId>
|
||||
<version>2.1.5</version>
|
||||
<version>2.1.6</version>
|
||||
</dependency>
|
||||
```
|
||||
|
||||
@ -49,7 +49,7 @@ Solon application support:
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>milvus-plus-solon-plugin</artifactId>
|
||||
<version>2.1.5</version>
|
||||
<version>2.1.6</version>
|
||||
</dependency>
|
||||
```
|
||||
|
||||
|
||||
@ -264,6 +264,24 @@ public abstract class ConditionBuilder<T> {
|
||||
filters.add(fn + " like '%" + value + "%'");
|
||||
return this;
|
||||
}
|
||||
protected ConditionBuilder<T> likeLeft(String fieldName, String value) {
|
||||
filters.add(wrapFieldName(fieldName) + " like '" + value + "%'");
|
||||
return this;
|
||||
}
|
||||
protected ConditionBuilder<T> likeRight(String fieldName, String value) {
|
||||
filters.add(wrapFieldName(fieldName) + " like '%'" + value + "'");
|
||||
return this;
|
||||
}
|
||||
protected ConditionBuilder<T> likeLeft(FieldFunction<T,?> fieldName, String value) {
|
||||
String fn = getFieldName(fieldName);
|
||||
filters.add(fn + " like '" + value + "%'");
|
||||
return this;
|
||||
}
|
||||
protected ConditionBuilder<T> likeRight(FieldFunction<T,?> fieldName, String value) {
|
||||
String fn = getFieldName(fieldName);
|
||||
filters.add(fn + " like '%" + value + "'");
|
||||
return this;
|
||||
}
|
||||
|
||||
// JSON array operations
|
||||
public ConditionBuilder<T> jsonContains(FieldFunction<T,?> fieldName, Object value) {
|
||||
@ -369,4 +387,5 @@ public abstract class ConditionBuilder<T> {
|
||||
filters.add(wrapFieldName(getFieldName(fieldName)) + " " + op + " " + convertValue(value));
|
||||
return this;
|
||||
}
|
||||
|
||||
}
|
||||
@ -180,6 +180,48 @@ public class LambdaDeleteWrapper<T> extends AbstractChainWrapper<T> implements
|
||||
super.like(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
////
|
||||
public LambdaDeleteWrapper<T> likeLeft(String fieldName, String value) {
|
||||
super.likeLeft(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaDeleteWrapper<T> likeLeft(boolean condition,String fieldName, String value) {
|
||||
if(condition){
|
||||
super.likeLeft(fieldName,value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
public LambdaDeleteWrapper<T> likeLeft(FieldFunction<T,?> fieldName, String value) {
|
||||
super.likeLeft(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaDeleteWrapper<T> likeLeft(boolean condition, FieldFunction<T, ?> fieldName, String value) {
|
||||
if (condition) {
|
||||
super.likeLeft(fieldName, value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
////
|
||||
public LambdaDeleteWrapper<T> likeRight(String fieldName, String value) {
|
||||
super.likeRight(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaDeleteWrapper<T> likeRight(boolean condition,String fieldName, String value) {
|
||||
if(condition){
|
||||
super.likeRight(fieldName,value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
public LambdaDeleteWrapper<T> likeRight(FieldFunction<T,?> fieldName, String value) {
|
||||
super.likeRight(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaDeleteWrapper<T> likeRight(boolean condition, FieldFunction<T, ?> fieldName, String value) {
|
||||
if (condition) {
|
||||
super.likeRight(fieldName, value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
public LambdaDeleteWrapper<T> jsonContains(String fieldName, Object value) {
|
||||
super.jsonContains(fieldName,value);
|
||||
|
||||
@ -307,6 +307,58 @@ public class LambdaQueryWrapper<T> extends AbstractChainWrapper<T> implements Wr
|
||||
}
|
||||
return this;
|
||||
}
|
||||
public LambdaQueryWrapper<T> like(FieldFunction<T,?> fieldName, String value) {
|
||||
super.like(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaQueryWrapper<T> like(boolean condition, FieldFunction<T, ?> fieldName, String value) {
|
||||
if (condition) {
|
||||
super.like(fieldName, value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
////
|
||||
public LambdaQueryWrapper<T> likeLeft(String fieldName, String value) {
|
||||
super.likeLeft(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaQueryWrapper<T> likeLeft(boolean condition,String fieldName, String value) {
|
||||
if(condition){
|
||||
super.likeLeft(fieldName,value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
public LambdaQueryWrapper<T> likeLeft(FieldFunction<T,?> fieldName, String value) {
|
||||
super.likeLeft(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaQueryWrapper<T> likeLeft(boolean condition, FieldFunction<T, ?> fieldName, String value) {
|
||||
if (condition) {
|
||||
super.likeLeft(fieldName, value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
////
|
||||
public LambdaQueryWrapper<T> likeRight(String fieldName, String value) {
|
||||
super.likeRight(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaQueryWrapper<T> likeRight(boolean condition,String fieldName, String value) {
|
||||
if(condition){
|
||||
super.likeRight(fieldName,value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
public LambdaQueryWrapper<T> likeRight(FieldFunction<T,?> fieldName, String value) {
|
||||
super.likeRight(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaQueryWrapper<T> likeRight(boolean condition, FieldFunction<T, ?> fieldName, String value) {
|
||||
if (condition) {
|
||||
super.likeRight(fieldName, value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
public LambdaQueryWrapper<T> jsonContains(String fieldName, Object value) {
|
||||
super.jsonContains(fieldName,value);
|
||||
@ -438,11 +490,6 @@ public class LambdaQueryWrapper<T> extends AbstractChainWrapper<T> implements Wr
|
||||
return this;
|
||||
}
|
||||
|
||||
// Like operator
|
||||
public LambdaQueryWrapper<T> like(FieldFunction<T,?> fieldName, String value) {
|
||||
super.like(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
|
||||
// JSON array operations
|
||||
public LambdaQueryWrapper<T> jsonContains(FieldFunction<T,?> fieldName, Object value) {
|
||||
@ -536,13 +583,6 @@ public class LambdaQueryWrapper<T> extends AbstractChainWrapper<T> implements Wr
|
||||
return this;
|
||||
}
|
||||
|
||||
public LambdaQueryWrapper<T> like(boolean condition, FieldFunction<T, ?> fieldName, String value) {
|
||||
if (condition) {
|
||||
super.like(fieldName, value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
public LambdaQueryWrapper<T> jsonContains(boolean condition, FieldFunction<T, ?> fieldName, Object value) {
|
||||
if (condition) {
|
||||
super.jsonContains(fieldName, value);
|
||||
|
||||
@ -187,6 +187,48 @@ public class LambdaUpdateWrapper<T> extends AbstractChainWrapper<T> implements W
|
||||
super.like(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
////
|
||||
public LambdaUpdateWrapper<T> likeLeft(String fieldName, String value) {
|
||||
super.likeLeft(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaUpdateWrapper<T> likeLeft(boolean condition,String fieldName, String value) {
|
||||
if(condition){
|
||||
super.likeLeft(fieldName,value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
public LambdaUpdateWrapper<T> likeLeft(FieldFunction<T,?> fieldName, String value) {
|
||||
super.likeLeft(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaUpdateWrapper<T> likeLeft(boolean condition, FieldFunction<T, ?> fieldName, String value) {
|
||||
if (condition) {
|
||||
super.likeLeft(fieldName, value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
////
|
||||
public LambdaUpdateWrapper<T> likeRight(String fieldName, String value) {
|
||||
super.likeRight(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaUpdateWrapper<T> likeRight(boolean condition,String fieldName, String value) {
|
||||
if(condition){
|
||||
super.likeRight(fieldName,value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
public LambdaUpdateWrapper<T> likeRight(FieldFunction<T,?> fieldName, String value) {
|
||||
super.likeRight(fieldName,value);
|
||||
return this;
|
||||
}
|
||||
public LambdaUpdateWrapper<T> likeRight(boolean condition, FieldFunction<T, ?> fieldName, String value) {
|
||||
if (condition) {
|
||||
super.likeRight(fieldName, value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
public LambdaUpdateWrapper<T> jsonContains(String fieldName, Object value) {
|
||||
super.jsonContains(fieldName,value);
|
||||
|
||||
@ -30,7 +30,7 @@
|
||||
</developer>
|
||||
</developers>
|
||||
<properties>
|
||||
<revision>2.1.5</revision>
|
||||
<revision>2.1.6</revision>
|
||||
<maven.compiler.source>${java.version}</maven.compiler.source>
|
||||
<maven.compiler.target>${java.version}</maven.compiler.target>
|
||||
<maven-compiler.version>3.11.0</maven-compiler.version>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user