|
@@ -80,7 +80,7 @@ public class YoumeiDataServiceImpl extends ServiceImpl<YoumeiDataMapper, YoumeiD
|
|
|
// 关键词
|
|
|
if (!TextUtils.isEmpty(dataRequestDTO.getKeywords())) {
|
|
|
b.must(Query.of(y -> y.multiMatch(MultiMatchQuery.of(z -> z.fields(Arrays.asList("title", "content")).query(dataRequestDTO.getKeywords())))));
|
|
|
- builder.minScore(10D);
|
|
|
+ builder.sort(SortOptions.of(so -> so.score(s -> s.order(SortOrder.Desc)))).minScore(10D);
|
|
|
}
|
|
|
|
|
|
// 类型
|
|
@@ -99,7 +99,7 @@ public class YoumeiDataServiceImpl extends ServiceImpl<YoumeiDataMapper, YoumeiD
|
|
|
}));
|
|
|
|
|
|
builder.query(query);
|
|
|
- builder.sort(SortOptions.of(so -> so.score(s -> s.order(SortOrder.Desc))), SortOptions.of(
|
|
|
+ builder.sort(SortOptions.of(
|
|
|
so -> so.field(fs -> fs.field("offset").order(SortOrder.Desc))
|
|
|
));
|
|
|
|