feat(wechat-game): add level list API endpoints

Add CRUD endpoints for game levels with level field in response:
- GET /v1/wechat-game/levels - list all levels ordered by sort_order
- GET /v1/wechat-game/levels/:id - get single level by ID

New files:
- Level entity mapping to levels table
- LevelRepository with ordered query support
- LevelResponseDto with level field (1-based index from sort_order)
This commit is contained in:
richarjiang
2026-03-15 15:52:51 +08:00
parent ed1b5455a2
commit 46368b8c89
7 changed files with 205 additions and 6 deletions

View File

@@ -0,0 +1,7 @@
import { Level } from '../entities/level.entity';
export interface ILevelRepository {
findAll(): Promise<Level[]>;
findById(id: string): Promise<Level | null>;
findAllOrdered(): Promise<Level[]>;
}