|
@@ -83,7 +83,7 @@ public class EsDenseVectorService {
|
|
//设置查询索引
|
|
//设置查询索引
|
|
builder.index("patent_vector");
|
|
builder.index("patent_vector");
|
|
Query q = null;
|
|
Query q = null;
|
|
- String condition = this.appendCondition(dto.getProductId(), dto.getKey(),dto.getAppCountry(),dto.getName());
|
|
|
|
|
|
+ String condition = this.appendCondition(dto.getProductId(), dto.getKey(),dto.getAppCountry(),dto.getCompanyName());
|
|
if (StringUtils.isNotEmpty(condition)) {
|
|
if (StringUtils.isNotEmpty(condition)) {
|
|
//1. 解析检索条件
|
|
//1. 解析检索条件
|
|
treeNode tree = expressManager.getInstance().Parse(condition, false);
|
|
treeNode tree = expressManager.getInstance().Parse(condition, false);
|
|
@@ -220,7 +220,7 @@ public class EsDenseVectorService {
|
|
* @return
|
|
* @return
|
|
* @throws Exception
|
|
* @throws Exception
|
|
*/
|
|
*/
|
|
- public String appendCondition(Integer productId, String keyword,String appCountry,String name) {
|
|
|
|
|
|
+ public String appendCondition(Integer productId, String keyword,String appCountry,String companyName) {
|
|
SimpleDateFormat format = new SimpleDateFormat("yyyyMMdd");
|
|
SimpleDateFormat format = new SimpleDateFormat("yyyyMMdd");
|
|
SimpleDateFormat format1 = new SimpleDateFormat("yyyy");
|
|
SimpleDateFormat format1 = new SimpleDateFormat("yyyy");
|
|
|
|
|
|
@@ -248,11 +248,11 @@ public class EsDenseVectorService {
|
|
searchCondition = searchCondition + " AND " + "CO = " + "(" + appCountry + ")";
|
|
searchCondition = searchCondition + " AND " + "CO = " + "(" + appCountry + ")";
|
|
}
|
|
}
|
|
}
|
|
}
|
|
- if (StringUtils.isNotEmpty(name)) {
|
|
|
|
|
|
+ if (StringUtils.isNotEmpty(companyName)) {
|
|
if (StringUtils.isEmpty(searchCondition)) {
|
|
if (StringUtils.isEmpty(searchCondition)) {
|
|
- searchCondition = "PE = " + "(" + name + ")";
|
|
|
|
|
|
+ searchCondition = "PE = " + "(" + companyName + ")";
|
|
} else {
|
|
} else {
|
|
- searchCondition = searchCondition + " AND " + "PE = " + "(" + "\"" + name + "\"" + ")";
|
|
|
|
|
|
+ searchCondition = searchCondition + " AND " + "PE = " + "(" + "\"" + companyName + "\"" + ")";
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (StringUtils.isNotEmpty(searchCondition)) {
|
|
if (StringUtils.isNotEmpty(searchCondition)) {
|