|
|
@@ -62,7 +62,7 @@ public class SearchServiceImpl implements SearchService, InnerSearchService {
|
|
|
SPage<Long> sPage = new SPage<>();
|
|
|
BooleanQuery booleanQuery = new BooleanQuery();
|
|
|
|
|
|
- // 关键词无效,不添加搜索条件(搜索所有的数据)
|
|
|
+ // 关键词无效,不添加搜索条件(即搜索所有的数据)
|
|
|
if (!SearchUtils.isKeywordInvalid(keyword)) {
|
|
|
// 关键词带空格,进行与操作
|
|
|
String[] strs = keyword.split(" ");
|
|
|
@@ -124,9 +124,11 @@ public class SearchServiceImpl implements SearchService, InnerSearchService {
|
|
|
for (Entry<String, Object> entry : entrySet) {
|
|
|
String key = entry.getKey();
|
|
|
Object value = entry.getValue();
|
|
|
- logger.info(value);
|
|
|
- logger.info(value.getClass());
|
|
|
- // 对于明细、企业等所关联的表的数据,是以json格式存储的,搜索时可能会对明细等表中多个字段进行过滤,但是键都是明细等表在主表中所对应的字段名称,为了实现这样的过滤功能,需要将多个值放在List<Object>中,作为filters中key-value的value传递过来
|
|
|
+ /*
|
|
|
+ * 对于明细、企业等所关联的表的数据,是以json格式存储的,搜索时可能会对明细等表中多个字段进行过滤,
|
|
|
+ * 但是键都是明细等表在主表中所对应的字段名称,为了实现这样的过滤功能,需要将多个值放在List<Object>中,
|
|
|
+ * 作为filters中key-value的value传递过来
|
|
|
+ */
|
|
|
if (value instanceof ArrayList) {
|
|
|
@SuppressWarnings("unchecked")
|
|
|
List<Object> list = (List<Object>) value;
|