记得上下班打卡 | git大法好,push需谨慎

Commit 5f7fc975 authored by 胡佳晨's avatar 胡佳晨

提交 app 搜索接口

parent 101da2c5
......@@ -467,16 +467,15 @@ public class GoblinFrontServiceImpl implements GoblinFrontService {
List<String> listStore = mongoUtils.getStoreInfoVoRegexName(name);
Pattern pattern = Pattern.compile("^.*" + name + ".*$", Pattern.CASE_INSENSITIVE);
Query query = new Query();
query.addCriteria(new Criteria().orOperator(
// Criteria.where("spuType").is(0),
query.addCriteria(Criteria.where("spuAppear").is("0").and("delFlg").is("0").and("shelvesStatus").is("3").and("marketId").is(null).andOperator(
new Criteria().orOperator(
Criteria.where("name").regex(pattern),
Criteria.where("storeId").in(listStore),
Criteria.where("extagVoList.tagName").is(name)
),
new Criteria().orOperator(Criteria.where("spuType").exists(false), (Criteria.where("spuType").is(0)))
));
// query.addCriteria(Criteria.where("name").regex(pattern).and("spuAppear").is("0").and("delFlg").is("0").and("shelvesStatus").is("3"));
query.addCriteria(Criteria.where("spuAppear").is("0").and("delFlg").is("0").and("shelvesStatus").is("3").and("marketId").is(null));
query.addCriteria(Criteria.where("spuType").is(0));
query.with(Sort.by(
query.with(PageRequest.of(0, 20)).with(Sort.by(
//Sort.Order.desc("count"),
Sort.Order.desc("shelvesAt")
));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment