| | |
| | | if (old != null) {// 更新
|
| | | Query query = new Query();
|
| | | query.addCriteria(Criteria.where("id").is(v2.getId()));
|
| | | Field[] fields = v2.getClass().getFields();
|
| | | Field[] fields = DaTaoKeDetailV2.class.getDeclaredFields();
|
| | |
|
| | | Update update = new Update();
|
| | | for (Field f : fields) {
|
| | |
| | | *
|
| | | * @return
|
| | | */
|
| | | public List<DaTaoKeDetailV2> listPreShareHotGoods(int count, String sortName) {
|
| | | public List<DaTaoKeDetailV2> listPreShareHotGoods(int start, int count, String sortName) {
|
| | | Query query = new Query();
|
| | | query.addCriteria(Criteria.where("commission").gt(734));
|
| | | List<Order> orders = new ArrayList<>();
|
| | | orders.add(new Order(Direction.DESC, sortName));
|
| | | query.with(new Sort(orders));
|
| | | query.with(new Sort(orders)).skip(start);
|
| | | query.limit(count);
|
| | | return mongoTemplate.find(query, getEntityClass());
|
| | | }
|