MongoRepository排序
解决方法:
其中findAllByDesignerId方法是已实现了MongoRepository的类一个自定义方法
import org.springframework.data.domain.Sort;
taskDoWithDesignerDao.findAllByDesignerId(new Sort(Sort.Direction.DESC, "_id"));
向大家推荐《Activiti工作流实战教程》:https://xiaozhuanlan.com/activiti