关卡列表
This commit is contained in:
parent
289fe1c009
commit
7c84d070d9
|
@ -27,7 +27,7 @@ public class LevelController {
|
|||
@Resource
|
||||
private LevelService levelService;
|
||||
|
||||
@ApiOperation(value = "关卡列表(只返回ID、名称和类型)")
|
||||
@ApiOperation(value = "关卡列表(只返回ID、排序、名称和类型)")
|
||||
@GetMapping("/list")
|
||||
public R<List<Level>> list() {
|
||||
return levelService.list();
|
||||
|
|
|
@ -39,7 +39,7 @@ public class LevelServiceImpl implements LevelService {
|
|||
@Override
|
||||
public R<List<Level>> list() {
|
||||
Query query = new Query();
|
||||
query.fields().include("id").include("name").include("type");
|
||||
query.fields().include("id").include("name").include("type").include("order");
|
||||
List<Level> levels = mongoTemplate.find(query, Level.class);
|
||||
return R.ok(levels);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue