refactor(i18n): 全面翻译Swagger注解和实体注释为中文

- 翻译41个控制器的所有@Tag和@Operation注解为中文
  - Admin系列控制器:9个
  - School系列控制器:13个
  - Teacher系列控制器:9个
  - Parent系列控制器:4个
  - AuthController和FileUploadController:2个

- 翻译41个实体类的类注释为中文
  - 管理员/教师/学生/家长/租户等核心实体
  - 课程/课时/任务/成长档案等业务实体
  - 各类关系映射实体

- 翻译21个DTO的@Schema注解为中文
  - Request DTOs: 19个(创建/更新请求)
  - Response DTOs: 4个(登录/用户信息/课程/租户响应)

- 新增CLAUDE.md项目文档

所有翻译确保符合上下文语义,保持代码功能不变。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
En 2026-03-06 12:23:10 +08:00
parent 14b38039b2
commit 32d2364c77
97 changed files with 735 additions and 591 deletions

144
CLAUDE.md Normal file
View File

@ -0,0 +1,144 @@
# CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
## Project Overview
This is a **Kindergarten Course Management System** (少儿智慧阅读平台) with a Spring Boot backend and Vue 3 frontend. The system manages courses, lessons, tasks, and student growth records for kindergartens.
## Architecture
### Backend (`reading-platform-java`)
- **Framework**: Spring Boot 3.2.3 + Java 17
- **Persistence**: MyBatis-Plus 3.5.5
- **Security**: Spring Security + JWT
- **API Docs**: Knife4j (Swagger OpenAPI 3)
- **Database**: MySQL 8.0
- **Migration**: Flyway
### Frontend (`reading-platform-frontend`)
- **Framework**: Vue 3 + TypeScript + Vite
- **UI**: Ant Design Vue
- **State**: Pinia
- **API**: Axios with auto-generated TypeScript clients via Orval
## Multi-Tenant Architecture
The system supports multiple kindergartens (tenants):
- `admin` role: Super admin (no tenant, manages system-wide courses)
- `school` role: School administrator (manages school's teachers, students, classes)
- `teacher` role: Teacher (manages lessons, tasks for their tenant)
- `parent` role: Parent (views child's progress and tasks)
Each entity (except `admin_users`) has a `tenant_id` field. System courses have `tenant_id = NULL`.
## Project Structure
```
kindergarten_java/
├── reading-platform-java/ # Spring Boot backend
│ ├── src/main/java/.../controller/
│ │ ├── admin/ # Super admin endpoints (/api/v1/admin/*)
│ │ ├── school/ # School admin endpoints (/api/v1/school/*)
│ │ ├── teacher/ # Teacher endpoints (/api/v1/teacher/*)
│ │ └── parent/ # Parent endpoints (/api/v1/parent/*)
│ ├── entity/ # Database entities (27 tables)
│ ├── mapper/ # MyBatis-Plus mappers
│ ├── service/ # Service layer interface + impl
│ ├── common/
│ │ ├── annotation/RequireRole # Role-based access control
│ │ ├── security/ # JWT authentication
│ │ ├── enums/ # UserRole, CourseStatus, etc.
│ │ ├── response/ # Result<T>, PageResult<T>
│ │ └── config/ # Security, MyBatis, OpenAPI configs
│ └── resources/
│ ├── db/migration/ # Flyway migration scripts
│ └── mapper/ # MyBatis XML files
├── reading-platform-frontend/ # Vue 3 frontend
│ ├── src/views/
│ │ ├── admin/ # Super admin pages
│ │ ├── school/ # School admin pages
│ │ ├── teacher/ # Teacher pages
│ │ └── parent/ # Parent pages
│ ├── api/generated/ # Auto-generated API clients
│ ├── api-spec.yml # OpenAPI specification
│ └── router/index.ts # Vue Router config
├── docker-compose.yml # Backend + Frontend services
└── docs/开发协作指南.md # Development guide (Chinese)
```
## Key Patterns
### 1. Role-Based Access Control
Use `@RequireRole` annotation on controllers/services:
```java
@RequireRole(UserRole.SCHOOL) // Only school admins can access
```
### 2. Tenant Isolation
Use `SecurityUtils.getCurrentTenantId()` in school/teacher/parent endpoints to filter data by current tenant.
### 3. Unified Response Format
```java
Result<T> success(T data) // { code: 200, message: "success", data: ... }
Result<T> error(code, msg) // { code: xxx, message: "...", data: null }
```
### 4. OpenAPI-Driven Development
- Backend: Annotate controllers with `@Operation`, `@Parameter`, `@Schema`
- Frontend: Run `npm run api:update` to regenerate TypeScript clients from `api-spec.yml`
## Development Commands
### Backend
```bash
# Run with Docker Compose (recommended)
docker compose up --build
# Run locally (requires MySQL running)
cd reading-platform-java
mvn spring-boot:run
# Build
mvn clean package -DskipTests
```
### Frontend
```bash
cd reading-platform-frontend
npm install
npm run dev
npm run build
# Update API clients from backend spec
npm run api:update
```
### Database Migration
- Add new migration scripts to `reading-platform-java/src/main/resources/db/migration/V{n}__description.sql`
- Flyway runs automatically on backend startup (dev mode only)
## Database Schema (27 Tables)
- **Tenant**: tenants, tenant_courses
- **Users**: admin_users, teachers, students, parents, parent_students
- **Class**: classes, class_teachers, student_class_history
- **Course**: courses, course_versions, course_resources, course_scripts, course_script_pages, course_activities
- **Lesson**: lessons, lesson_feedbacks, student_records
- **Task**: tasks, task_targets, task_completions, task_templates
- **Growth**: growth_records
- **Resource**: resource_libraries, resource_items
- **Schedule**: schedule_plans, schedule_templates
- **System**: system_settings, notifications, operation_logs, tags
## Test Accounts
| Role | Username | Password |
|------|----------|----------|
| Admin | admin | admin123 |
| School | school | 123456 |
| Teacher | teacher1 | 123456 |
| Parent | parent1 | 123456 |
## API Documentation
- Access: http://localhost:8080/doc.html (after backend starts)

View File

@ -11,7 +11,7 @@ import jakarta.validation.Valid;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "Auth", description = "Authentication APIs") @Tag(name = "认证", description = "认证相关接口")
@RestController @RestController
@RequestMapping("/api/v1/auth") @RequestMapping("/api/v1/auth")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -19,26 +19,26 @@ public class AuthController {
private final AuthService authService; private final AuthService authService;
@Operation(summary = "User login") @Operation(summary = "用户登录")
@PostMapping("/login") @PostMapping("/login")
public Result<LoginResponse> login(@Valid @RequestBody LoginRequest request) { public Result<LoginResponse> login(@Valid @RequestBody LoginRequest request) {
return Result.success(authService.login(request)); return Result.success(authService.login(request));
} }
@Operation(summary = "User logout") @Operation(summary = "用户登出")
@PostMapping("/logout") @PostMapping("/logout")
public Result<Void> logout() { public Result<Void> logout() {
// JWT is stateless - client simply discards the token // JWT is stateless - client simply discards the token
return Result.success(); return Result.success();
} }
@Operation(summary = "Get current user info") @Operation(summary = "获取当前用户信息")
@GetMapping("/me") @GetMapping("/me")
public Result<UserInfoResponse> getCurrentUser() { public Result<UserInfoResponse> getCurrentUser() {
return Result.success(authService.getCurrentUserInfo()); return Result.success(authService.getCurrentUserInfo());
} }
@Operation(summary = "Change password") @Operation(summary = "修改密码")
@PostMapping("/change-password") @PostMapping("/change-password")
public Result<Void> changePassword( public Result<Void> changePassword(
@RequestParam String oldPassword, @RequestParam String oldPassword,

View File

@ -11,7 +11,7 @@ import org.springframework.web.multipart.MultipartFile;
import java.util.HashMap; import java.util.HashMap;
import java.util.Map; import java.util.Map;
@Tag(name = "File Upload", description = "File Upload APIs") @Tag(name = "文件上传", description = "文件上传接口")
@RestController @RestController
@RequestMapping("/api/v1/files") @RequestMapping("/api/v1/files")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -19,7 +19,7 @@ public class FileUploadController {
private final FileUploadService fileUploadService; private final FileUploadService fileUploadService;
@Operation(summary = "Upload file") @Operation(summary = "上传文件")
@PostMapping("/upload") @PostMapping("/upload")
public Result<Map<String, String>> uploadFile(@RequestParam("file") MultipartFile file) { public Result<Map<String, String>> uploadFile(@RequestParam("file") MultipartFile file) {
String url = fileUploadService.uploadFile(file); String url = fileUploadService.uploadFile(file);
@ -29,7 +29,7 @@ public class FileUploadController {
return Result.success(result); return Result.success(result);
} }
@Operation(summary = "Delete file") @Operation(summary = "删除文件")
@DeleteMapping("/delete") @DeleteMapping("/delete")
public Result<Void> deleteFile(@RequestParam("filePath") String filePath) { public Result<Void> deleteFile(@RequestParam("filePath") String filePath) {
fileUploadService.deleteFile(filePath); fileUploadService.deleteFile(filePath);

View File

@ -15,7 +15,7 @@ import jakarta.validation.Valid;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "Admin - Course", description = "System Course Management APIs for Admin") @Tag(name = "管理员 - 课程", description = "系统课程管理接口(管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/admin/courses") @RequestMapping("/api/v1/admin/courses")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -24,26 +24,26 @@ public class AdminCourseController {
private final CourseService courseService; private final CourseService courseService;
@Operation(summary = "Create system course") @Operation(summary = "创建系统课程")
@PostMapping @PostMapping
public Result<Course> createCourse(@Valid @RequestBody CourseCreateRequest request) { public Result<Course> createCourse(@Valid @RequestBody CourseCreateRequest request) {
// System courses have null tenantId; service sets isSystem=1 when tenantId is null // System courses have null tenantId; service sets isSystem=1 when tenantId is null
return Result.success(courseService.createCourse(null, request)); return Result.success(courseService.createCourse(null, request));
} }
@Operation(summary = "Update course") @Operation(summary = "更新课程")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<Course> updateCourse(@PathVariable Long id, @RequestBody CourseUpdateRequest request) { public Result<Course> updateCourse(@PathVariable Long id, @RequestBody CourseUpdateRequest request) {
return Result.success(courseService.updateCourse(id, request)); return Result.success(courseService.updateCourse(id, request));
} }
@Operation(summary = "Get course by ID") @Operation(summary = "根据ID获取课程")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Course> getCourse(@PathVariable Long id) { public Result<Course> getCourse(@PathVariable Long id) {
return Result.success(courseService.getCourseById(id)); return Result.success(courseService.getCourseById(id));
} }
@Operation(summary = "Get system course page (all statuses)") @Operation(summary = "获取系统课程分页(所有状态)")
@GetMapping @GetMapping
public Result<PageResult<Course>> getCoursePage( public Result<PageResult<Course>> getCoursePage(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -55,7 +55,7 @@ public class AdminCourseController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Get courses pending review") @Operation(summary = "获取待审核课程")
@GetMapping("/review") @GetMapping("/review")
public Result<PageResult<Course>> getReviewCoursePage( public Result<PageResult<Course>> getReviewCoursePage(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -64,28 +64,28 @@ public class AdminCourseController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Delete course") @Operation(summary = "删除课程")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteCourse(@PathVariable Long id) { public Result<Void> deleteCourse(@PathVariable Long id) {
courseService.deleteCourse(id); courseService.deleteCourse(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Submit course for review") @Operation(summary = "提交课程审核")
@PostMapping("/{id}/submit") @PostMapping("/{id}/submit")
public Result<Void> submitCourse(@PathVariable Long id) { public Result<Void> submitCourse(@PathVariable Long id) {
courseService.submitCourse(id); courseService.submitCourse(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Withdraw course from review") @Operation(summary = "撤销课程审核")
@PostMapping("/{id}/withdraw") @PostMapping("/{id}/withdraw")
public Result<Void> withdrawCourse(@PathVariable Long id) { public Result<Void> withdrawCourse(@PathVariable Long id) {
courseService.withdrawCourse(id); courseService.withdrawCourse(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Approve course") @Operation(summary = "审批课程")
@PostMapping("/{id}/approve") @PostMapping("/{id}/approve")
public Result<Void> approveCourse( public Result<Void> approveCourse(
@PathVariable Long id, @PathVariable Long id,
@ -94,7 +94,7 @@ public class AdminCourseController {
return Result.success(); return Result.success();
} }
@Operation(summary = "Reject course") @Operation(summary = "驳回课程")
@PostMapping("/{id}/reject") @PostMapping("/{id}/reject")
public Result<Void> rejectCourse( public Result<Void> rejectCourse(
@PathVariable Long id, @PathVariable Long id,
@ -103,35 +103,35 @@ public class AdminCourseController {
return Result.success(); return Result.success();
} }
@Operation(summary = "Publish course") @Operation(summary = "发布课程")
@PostMapping("/{id}/publish") @PostMapping("/{id}/publish")
public Result<Void> publishCourse(@PathVariable Long id) { public Result<Void> publishCourse(@PathVariable Long id) {
courseService.publishCourse(id); courseService.publishCourse(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Direct publish course (skip review)") @Operation(summary = "直接发布课程(跳过审核)")
@PostMapping("/{id}/direct-publish") @PostMapping("/{id}/direct-publish")
public Result<Void> directPublishCourse(@PathVariable Long id) { public Result<Void> directPublishCourse(@PathVariable Long id) {
courseService.publishCourse(id); courseService.publishCourse(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Unpublish (archive) course") @Operation(summary = "取消发布(归档)课程")
@PostMapping("/{id}/unpublish") @PostMapping("/{id}/unpublish")
public Result<Void> unpublishCourse(@PathVariable Long id) { public Result<Void> unpublishCourse(@PathVariable Long id) {
courseService.archiveCourse(id); courseService.archiveCourse(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Republish course") @Operation(summary = "重新发布课程")
@PostMapping("/{id}/republish") @PostMapping("/{id}/republish")
public Result<Void> republishCourse(@PathVariable Long id) { public Result<Void> republishCourse(@PathVariable Long id) {
courseService.publishCourse(id); courseService.publishCourse(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Archive course") @Operation(summary = "归档课程")
@PostMapping("/{id}/archive") @PostMapping("/{id}/archive")
public Result<Void> archiveCourse(@PathVariable Long id) { public Result<Void> archiveCourse(@PathVariable Long id) {
courseService.archiveCourse(id); courseService.archiveCourse(id);

View File

@ -12,7 +12,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.List; import java.util.List;
@Tag(name = "Admin - Course Lessons", description = "Course Lesson Management for Admin") @Tag(name = "管理员 - 课程课时", description = "课程课时管理接口(管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/admin/courses/{courseId}/lessons") @RequestMapping("/api/v1/admin/courses/{courseId}/lessons")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -21,32 +21,32 @@ public class AdminCourseLessonController {
private final CourseLessonService courseLessonService; private final CourseLessonService courseLessonService;
@Operation(summary = "Get lessons for a course") @Operation(summary = "获取课程的课时列表")
@GetMapping @GetMapping
public Result<List<CourseLesson>> getLessons(@PathVariable Long courseId) { public Result<List<CourseLesson>> getLessons(@PathVariable Long courseId) {
return Result.success(courseLessonService.getLessonsByCourse(courseId)); return Result.success(courseLessonService.getLessonsByCourse(courseId));
} }
@Operation(summary = "Get lesson by ID") @Operation(summary = "根据ID获取课时")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<CourseLesson> getLesson(@PathVariable Long courseId, @PathVariable Long id) { public Result<CourseLesson> getLesson(@PathVariable Long courseId, @PathVariable Long id) {
return Result.success(courseLessonService.getLessonById(id)); return Result.success(courseLessonService.getLessonById(id));
} }
@Operation(summary = "Create course lesson") @Operation(summary = "创建课程课时")
@PostMapping @PostMapping
public Result<CourseLesson> createLesson(@PathVariable Long courseId, @RequestBody CourseLesson lesson) { public Result<CourseLesson> createLesson(@PathVariable Long courseId, @RequestBody CourseLesson lesson) {
lesson.setCourseId(courseId); lesson.setCourseId(courseId);
return Result.success(courseLessonService.createLesson(lesson)); return Result.success(courseLessonService.createLesson(lesson));
} }
@Operation(summary = "Update course lesson") @Operation(summary = "更新课程课时")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<CourseLesson> updateLesson(@PathVariable Long courseId, @PathVariable Long id, @RequestBody CourseLesson lesson) { public Result<CourseLesson> updateLesson(@PathVariable Long courseId, @PathVariable Long id, @RequestBody CourseLesson lesson) {
return Result.success(courseLessonService.updateLesson(id, lesson)); return Result.success(courseLessonService.updateLesson(id, lesson));
} }
@Operation(summary = "Delete course lesson") @Operation(summary = "删除课程课时")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteLesson(@PathVariable Long courseId, @PathVariable Long id) { public Result<Void> deleteLesson(@PathVariable Long courseId, @PathVariable Long id) {
courseLessonService.deleteLesson(id); courseLessonService.deleteLesson(id);

View File

@ -12,7 +12,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "Admin - Course Packages", description = "Course Package Management for Admin") @Tag(name = "管理员 - 课程包", description = "课程包管理接口(管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/admin/packages") @RequestMapping("/api/v1/admin/packages")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -21,7 +21,7 @@ public class AdminCoursePackageController {
private final CoursePackageService coursePackageService; private final CoursePackageService coursePackageService;
@Operation(summary = "Get course packages") @Operation(summary = "获取课程包列表")
@GetMapping @GetMapping
public Result<PageResult<CoursePackage>> getPackages( public Result<PageResult<CoursePackage>> getPackages(
@RequestParam(value = "page", defaultValue = "1") int page, @RequestParam(value = "page", defaultValue = "1") int page,
@ -32,39 +32,39 @@ public class AdminCoursePackageController {
return Result.success(PageResult.of(result)); return Result.success(PageResult.of(result));
} }
@Operation(summary = "Get course package by ID") @Operation(summary = "根据ID获取课程包")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<CoursePackage> getPackage(@PathVariable Long id) { public Result<CoursePackage> getPackage(@PathVariable Long id) {
return Result.success(coursePackageService.getPackageById(id)); return Result.success(coursePackageService.getPackageById(id));
} }
@Operation(summary = "Create course package") @Operation(summary = "创建课程包")
@PostMapping @PostMapping
public Result<CoursePackage> createPackage(@RequestBody CoursePackage pkg) { public Result<CoursePackage> createPackage(@RequestBody CoursePackage pkg) {
return Result.success(coursePackageService.createPackage(pkg)); return Result.success(coursePackageService.createPackage(pkg));
} }
@Operation(summary = "Update course package") @Operation(summary = "更新课程包")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<CoursePackage> updatePackage(@PathVariable Long id, @RequestBody CoursePackage pkg) { public Result<CoursePackage> updatePackage(@PathVariable Long id, @RequestBody CoursePackage pkg) {
return Result.success(coursePackageService.updatePackage(id, pkg)); return Result.success(coursePackageService.updatePackage(id, pkg));
} }
@Operation(summary = "Delete course package") @Operation(summary = "删除课程包")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deletePackage(@PathVariable Long id) { public Result<Void> deletePackage(@PathVariable Long id) {
coursePackageService.deletePackage(id); coursePackageService.deletePackage(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Submit package for review") @Operation(summary = "提交课程包审核")
@PostMapping("/{id}/submit") @PostMapping("/{id}/submit")
public Result<Void> submitPackage(@PathVariable Long id) { public Result<Void> submitPackage(@PathVariable Long id) {
coursePackageService.submitPackage(id); coursePackageService.submitPackage(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Review package (approve or reject)") @Operation(summary = "审核课程包(通过或拒绝)")
@PostMapping("/{id}/review") @PostMapping("/{id}/review")
public Result<Void> reviewPackage( public Result<Void> reviewPackage(
@PathVariable Long id, @PathVariable Long id,
@ -75,14 +75,14 @@ public class AdminCoursePackageController {
return Result.success(); return Result.success();
} }
@Operation(summary = "Publish package") @Operation(summary = "发布课程包")
@PostMapping("/{id}/publish") @PostMapping("/{id}/publish")
public Result<Void> publishPackage(@PathVariable Long id) { public Result<Void> publishPackage(@PathVariable Long id) {
coursePackageService.publishPackage(id); coursePackageService.publishPackage(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Take package offline") @Operation(summary = "下架课程包")
@PostMapping("/{id}/offline") @PostMapping("/{id}/offline")
public Result<Void> offlinePackage(@PathVariable Long id) { public Result<Void> offlinePackage(@PathVariable Long id) {
coursePackageService.offlinePackage(id); coursePackageService.offlinePackage(id);

View File

@ -12,7 +12,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "Admin - Operation Logs", description = "Operation Log Management for Admin") @Tag(name = "管理员 - 操作日志", description = "操作日志管理接口(管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/admin/operation-logs") @RequestMapping("/api/v1/admin/operation-logs")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -21,7 +21,7 @@ public class AdminOperationLogController {
private final OperationLogService operationLogService; private final OperationLogService operationLogService;
@Operation(summary = "Get operation logs") @Operation(summary = "获取操作日志")
@GetMapping @GetMapping
public Result<PageResult<OperationLog>> getLogs( public Result<PageResult<OperationLog>> getLogs(
@RequestParam(defaultValue = "1") int pageNum, @RequestParam(defaultValue = "1") int pageNum,

View File

@ -15,7 +15,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.List; import java.util.List;
@Tag(name = "Admin - Resources", description = "Resource Library Management for Admin") @Tag(name = "管理员 - 资源", description = "资源库管理接口(管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/admin/resources") @RequestMapping("/api/v1/admin/resources")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -24,32 +24,32 @@ public class AdminResourceController {
private final ResourceService resourceService; private final ResourceService resourceService;
@Operation(summary = "Get all resource libraries") @Operation(summary = "获取所有资源库")
@GetMapping("/libraries") @GetMapping("/libraries")
public Result<List<ResourceLibrary>> getLibraries(@RequestParam(required = false) Long tenantId) { public Result<List<ResourceLibrary>> getLibraries(@RequestParam(required = false) Long tenantId) {
return Result.success(resourceService.getLibraries(tenantId)); return Result.success(resourceService.getLibraries(tenantId));
} }
@Operation(summary = "Create resource library") @Operation(summary = "创建资源库")
@PostMapping("/libraries") @PostMapping("/libraries")
public Result<ResourceLibrary> createLibrary(@RequestBody ResourceLibrary library) { public Result<ResourceLibrary> createLibrary(@RequestBody ResourceLibrary library) {
return Result.success(resourceService.createLibrary(library)); return Result.success(resourceService.createLibrary(library));
} }
@Operation(summary = "Update resource library") @Operation(summary = "更新资源库")
@PutMapping("/libraries/{id}") @PutMapping("/libraries/{id}")
public Result<ResourceLibrary> updateLibrary(@PathVariable Long id, @RequestBody ResourceLibrary library) { public Result<ResourceLibrary> updateLibrary(@PathVariable Long id, @RequestBody ResourceLibrary library) {
return Result.success(resourceService.updateLibrary(id, library)); return Result.success(resourceService.updateLibrary(id, library));
} }
@Operation(summary = "Delete resource library") @Operation(summary = "删除资源库")
@DeleteMapping("/libraries/{id}") @DeleteMapping("/libraries/{id}")
public Result<Void> deleteLibrary(@PathVariable Long id) { public Result<Void> deleteLibrary(@PathVariable Long id) {
resourceService.deleteLibrary(id); resourceService.deleteLibrary(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Get resource items") @Operation(summary = "获取资源项")
@GetMapping("/items") @GetMapping("/items")
public Result<PageResult<ResourceItem>> getItems( public Result<PageResult<ResourceItem>> getItems(
@RequestParam(defaultValue = "1") int pageNum, @RequestParam(defaultValue = "1") int pageNum,
@ -60,19 +60,19 @@ public class AdminResourceController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Create resource item") @Operation(summary = "创建资源项")
@PostMapping("/items") @PostMapping("/items")
public Result<ResourceItem> createItem(@RequestBody ResourceItem item) { public Result<ResourceItem> createItem(@RequestBody ResourceItem item) {
return Result.success(resourceService.createItem(item)); return Result.success(resourceService.createItem(item));
} }
@Operation(summary = "Update resource item") @Operation(summary = "更新资源项")
@PutMapping("/items/{id}") @PutMapping("/items/{id}")
public Result<ResourceItem> updateItem(@PathVariable Long id, @RequestBody ResourceItem item) { public Result<ResourceItem> updateItem(@PathVariable Long id, @RequestBody ResourceItem item) {
return Result.success(resourceService.updateItem(id, item)); return Result.success(resourceService.updateItem(id, item));
} }
@Operation(summary = "Delete resource item") @Operation(summary = "删除资源项")
@DeleteMapping("/items/{id}") @DeleteMapping("/items/{id}")
public Result<Void> deleteItem(@PathVariable Long id) { public Result<Void> deleteItem(@PathVariable Long id) {
resourceService.deleteItem(id); resourceService.deleteItem(id);

View File

@ -11,7 +11,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.Map; import java.util.Map;
@Tag(name = "Admin - Settings", description = "Admin System Settings Management") @Tag(name = "管理员 - 设置", description = "管理员系统设置管理")
@RestController @RestController
@RequestMapping("/api/v1/admin/settings") @RequestMapping("/api/v1/admin/settings")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -23,13 +23,13 @@ public class AdminSettingsController {
private final SystemSettingService systemSettingService; private final SystemSettingService systemSettingService;
@Operation(summary = "Get admin system settings") @Operation(summary = "获取管理员系统设置")
@GetMapping @GetMapping
public Result<Map<String, String>> getSettings() { public Result<Map<String, String>> getSettings() {
return Result.success(systemSettingService.getSettings(ADMIN_TENANT_ID)); return Result.success(systemSettingService.getSettings(ADMIN_TENANT_ID));
} }
@Operation(summary = "Update admin system settings") @Operation(summary = "更新管理员系统设置")
@PutMapping @PutMapping
public Result<Void> updateSettings(@RequestBody Map<String, Object> settings) { public Result<Void> updateSettings(@RequestBody Map<String, Object> settings) {
Map<String, String> stringSettings = new java.util.HashMap<>(); Map<String, String> stringSettings = new java.util.HashMap<>();

View File

@ -12,7 +12,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
@Tag(name = "Admin - Stats", description = "Admin Statistics Dashboard") @Tag(name = "管理员 - 统计", description = "管理员统计仪表盘")
@RestController @RestController
@RequestMapping("/api/v1/admin/stats") @RequestMapping("/api/v1/admin/stats")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -21,33 +21,33 @@ public class AdminStatsController {
private final AdminStatsService adminStatsService; private final AdminStatsService adminStatsService;
@Operation(summary = "Get overall statistics") @Operation(summary = "获取整体统计数据")
@GetMapping @GetMapping
public Result<Map<String, Object>> getStats() { public Result<Map<String, Object>> getStats() {
return Result.success(adminStatsService.getStats()); return Result.success(adminStatsService.getStats());
} }
@Operation(summary = "Get trend data (last 6 months)") @Operation(summary = "获取趋势数据近6个月")
@GetMapping("/trend") @GetMapping("/trend")
public Result<List<Map<String, Object>>> getTrendData() { public Result<List<Map<String, Object>>> getTrendData() {
return Result.success(adminStatsService.getTrendData()); return Result.success(adminStatsService.getTrendData());
} }
@Operation(summary = "Get active tenants") @Operation(summary = "获取活跃租户")
@GetMapping("/tenants/active") @GetMapping("/tenants/active")
public Result<List<Map<String, Object>>> getActiveTenants( public Result<List<Map<String, Object>>> getActiveTenants(
@RequestParam(defaultValue = "10") int limit) { @RequestParam(defaultValue = "10") int limit) {
return Result.success(adminStatsService.getActiveTenants(limit)); return Result.success(adminStatsService.getActiveTenants(limit));
} }
@Operation(summary = "Get popular courses") @Operation(summary = "获取热门课程")
@GetMapping("/courses/popular") @GetMapping("/courses/popular")
public Result<List<Map<String, Object>>> getPopularCourses( public Result<List<Map<String, Object>>> getPopularCourses(
@RequestParam(defaultValue = "10") int limit) { @RequestParam(defaultValue = "10") int limit) {
return Result.success(adminStatsService.getPopularCourses(limit)); return Result.success(adminStatsService.getPopularCourses(limit));
} }
@Operation(summary = "Get recent activities") @Operation(summary = "获取最近活动")
@GetMapping("/activities") @GetMapping("/activities")
public Result<List<Map<String, Object>>> getActivities( public Result<List<Map<String, Object>>> getActivities(
@RequestParam(defaultValue = "10") int limit) { @RequestParam(defaultValue = "10") int limit) {

View File

@ -20,7 +20,7 @@ import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
@Tag(name = "Admin - Tenant", description = "Tenant Management APIs for Admin") @Tag(name = "管理员 - 租户", description = "租户管理接口(管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/admin/tenants") @RequestMapping("/api/v1/admin/tenants")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -29,25 +29,25 @@ public class AdminTenantController {
private final TenantService tenantService; private final TenantService tenantService;
@Operation(summary = "Create tenant") @Operation(summary = "创建租户")
@PostMapping @PostMapping
public Result<Tenant> createTenant(@Valid @RequestBody TenantCreateRequest request) { public Result<Tenant> createTenant(@Valid @RequestBody TenantCreateRequest request) {
return Result.success(tenantService.createTenant(request)); return Result.success(tenantService.createTenant(request));
} }
@Operation(summary = "Update tenant") @Operation(summary = "更新租户")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<Tenant> updateTenant(@PathVariable Long id, @RequestBody TenantUpdateRequest request) { public Result<Tenant> updateTenant(@PathVariable Long id, @RequestBody TenantUpdateRequest request) {
return Result.success(tenantService.updateTenant(id, request)); return Result.success(tenantService.updateTenant(id, request));
} }
@Operation(summary = "Get tenant by ID") @Operation(summary = "根据ID获取租户")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Tenant> getTenant(@PathVariable Long id) { public Result<Tenant> getTenant(@PathVariable Long id) {
return Result.success(tenantService.getTenantById(id)); return Result.success(tenantService.getTenantById(id));
} }
@Operation(summary = "Get tenant page") @Operation(summary = "获取租户分页")
@GetMapping @GetMapping
public Result<PageResult<Tenant>> getTenantPage( public Result<PageResult<Tenant>> getTenantPage(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -59,20 +59,20 @@ public class AdminTenantController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Delete tenant") @Operation(summary = "删除租户")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteTenant(@PathVariable Long id) { public Result<Void> deleteTenant(@PathVariable Long id) {
tenantService.deleteTenant(id); tenantService.deleteTenant(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Get all active tenants") @Operation(summary = "获取所有活跃租户")
@GetMapping("/active") @GetMapping("/active")
public Result<List<TenantResponse>> getAllActiveTenants() { public Result<List<TenantResponse>> getAllActiveTenants() {
return Result.success(tenantService.getAllActiveTenants()); return Result.success(tenantService.getAllActiveTenants());
} }
@Operation(summary = "Update tenant status") @Operation(summary = "更新租户状态")
@PutMapping("/{id}/status") @PutMapping("/{id}/status")
public Result<Map<String, Object>> updateTenantStatus(@PathVariable Long id, @RequestBody Map<String, String> body) { public Result<Map<String, Object>> updateTenantStatus(@PathVariable Long id, @RequestBody Map<String, String> body) {
String status = body.get("status"); String status = body.get("status");
@ -88,7 +88,7 @@ public class AdminTenantController {
return Result.success(result); return Result.success(result);
} }
@Operation(summary = "Reset tenant school account password") @Operation(summary = "重置租户学校账号密码")
@PostMapping("/{id}/reset-password") @PostMapping("/{id}/reset-password")
public Result<Map<String, String>> resetTenantPassword(@PathVariable Long id) { public Result<Map<String, String>> resetTenantPassword(@PathVariable Long id) {
String tempPassword = tenantService.resetSchoolAccountPassword(id); String tempPassword = tenantService.resetSchoolAccountPassword(id);
@ -97,7 +97,7 @@ public class AdminTenantController {
return Result.success(result); return Result.success(result);
} }
@Operation(summary = "Update tenant quota") @Operation(summary = "更新租户配额")
@PutMapping("/{id}/quota") @PutMapping("/{id}/quota")
public Result<Tenant> updateTenantQuota(@PathVariable Long id, @RequestBody Map<String, Object> body) { public Result<Tenant> updateTenantQuota(@PathVariable Long id, @RequestBody Map<String, Object> body) {
TenantUpdateRequest req = new TenantUpdateRequest(); TenantUpdateRequest req = new TenantUpdateRequest();

View File

@ -12,7 +12,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.List; import java.util.List;
@Tag(name = "Admin - Themes", description = "Theme Management for Admin") @Tag(name = "管理员 - 主题", description = "主题管理接口(管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/admin/themes") @RequestMapping("/api/v1/admin/themes")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -21,31 +21,31 @@ public class AdminThemeController {
private final ThemeService themeService; private final ThemeService themeService;
@Operation(summary = "Get all themes") @Operation(summary = "获取所有主题")
@GetMapping @GetMapping
public Result<List<Theme>> getThemes(@RequestParam(required = false) Boolean enabledOnly) { public Result<List<Theme>> getThemes(@RequestParam(required = false) Boolean enabledOnly) {
return Result.success(themeService.getAllThemes(enabledOnly)); return Result.success(themeService.getAllThemes(enabledOnly));
} }
@Operation(summary = "Get theme by ID") @Operation(summary = "根据ID获取主题")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Theme> getTheme(@PathVariable Long id) { public Result<Theme> getTheme(@PathVariable Long id) {
return Result.success(themeService.getThemeById(id)); return Result.success(themeService.getThemeById(id));
} }
@Operation(summary = "Create theme") @Operation(summary = "创建主题")
@PostMapping @PostMapping
public Result<Theme> createTheme(@RequestBody Theme theme) { public Result<Theme> createTheme(@RequestBody Theme theme) {
return Result.success(themeService.createTheme(theme)); return Result.success(themeService.createTheme(theme));
} }
@Operation(summary = "Update theme") @Operation(summary = "更新主题")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<Theme> updateTheme(@PathVariable Long id, @RequestBody Theme theme) { public Result<Theme> updateTheme(@PathVariable Long id, @RequestBody Theme theme) {
return Result.success(themeService.updateTheme(id, theme)); return Result.success(themeService.updateTheme(id, theme));
} }
@Operation(summary = "Delete theme") @Operation(summary = "删除主题")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteTheme(@PathVariable Long id) { public Result<Void> deleteTheme(@PathVariable Long id) {
themeService.deleteTheme(id); themeService.deleteTheme(id);

View File

@ -11,7 +11,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.List; import java.util.List;
@Tag(name = "Parent - Child", description = "Child Information APIs for Parent") @Tag(name = "家长 - 孩子", description = "孩子信息接口(家长专用)")
@RestController @RestController
@RequestMapping("/api/v1/parent/children") @RequestMapping("/api/v1/parent/children")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -19,14 +19,14 @@ public class ParentChildController {
private final StudentService studentService; private final StudentService studentService;
@Operation(summary = "Get my children") @Operation(summary = "获取我的孩子")
@GetMapping @GetMapping
public Result<List<Student>> getMyChildren() { public Result<List<Student>> getMyChildren() {
Long parentId = SecurityUtils.getCurrentUserId(); Long parentId = SecurityUtils.getCurrentUserId();
return Result.success(studentService.getStudentsByParentId(parentId)); return Result.success(studentService.getStudentsByParentId(parentId));
} }
@Operation(summary = "Get child by ID") @Operation(summary = "根据ID获取孩子")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Student> getChild(@PathVariable Long id) { public Result<Student> getChild(@PathVariable Long id) {
return Result.success(studentService.getStudentById(id)); return Result.success(studentService.getStudentById(id));

View File

@ -24,7 +24,7 @@ public class ParentGrowthController {
private final GrowthRecordService growthRecordService; private final GrowthRecordService growthRecordService;
@Operation(summary = "Create growth record") @Operation(summary = "创建成长档案")
@PostMapping @PostMapping
public Result<GrowthRecord> createGrowthRecord(@Valid @RequestBody GrowthRecordCreateRequest request) { public Result<GrowthRecord> createGrowthRecord(@Valid @RequestBody GrowthRecordCreateRequest request) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
@ -32,19 +32,19 @@ public class ParentGrowthController {
return Result.success(growthRecordService.createGrowthRecord(tenantId, userId, "parent", request)); return Result.success(growthRecordService.createGrowthRecord(tenantId, userId, "parent", request));
} }
@Operation(summary = "Update growth record") @Operation(summary = "更新成长档案")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<GrowthRecord> updateGrowthRecord(@PathVariable Long id, @RequestBody GrowthRecordUpdateRequest request) { public Result<GrowthRecord> updateGrowthRecord(@PathVariable Long id, @RequestBody GrowthRecordUpdateRequest request) {
return Result.success(growthRecordService.updateGrowthRecord(id, request)); return Result.success(growthRecordService.updateGrowthRecord(id, request));
} }
@Operation(summary = "Get growth record by ID") @Operation(summary = "根据ID获取成长档案")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<GrowthRecord> getGrowthRecord(@PathVariable Long id) { public Result<GrowthRecord> getGrowthRecord(@PathVariable Long id) {
return Result.success(growthRecordService.getGrowthRecordById(id)); return Result.success(growthRecordService.getGrowthRecordById(id));
} }
@Operation(summary = "Get growth records by student ID") @Operation(summary = "根据学生ID获取成长档案")
@GetMapping("/student/{studentId}") @GetMapping("/student/{studentId}")
public Result<PageResult<GrowthRecord>> getGrowthRecordsByStudent( public Result<PageResult<GrowthRecord>> getGrowthRecordsByStudent(
@PathVariable Long studentId, @PathVariable Long studentId,
@ -55,7 +55,7 @@ public class ParentGrowthController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Get recent growth records") @Operation(summary = "获取最近成长档案")
@GetMapping("/student/{studentId}/recent") @GetMapping("/student/{studentId}/recent")
public Result<List<GrowthRecord>> getRecentGrowthRecords( public Result<List<GrowthRecord>> getRecentGrowthRecords(
@PathVariable Long studentId, @PathVariable Long studentId,
@ -63,7 +63,7 @@ public class ParentGrowthController {
return Result.success(growthRecordService.getRecentGrowthRecords(studentId, limit)); return Result.success(growthRecordService.getRecentGrowthRecords(studentId, limit));
} }
@Operation(summary = "Delete growth record") @Operation(summary = "删除成长档案")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteGrowthRecord(@PathVariable Long id) { public Result<Void> deleteGrowthRecord(@PathVariable Long id) {
growthRecordService.deleteGrowthRecord(id); growthRecordService.deleteGrowthRecord(id);

View File

@ -11,7 +11,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "Parent - Notification", description = "Notification APIs for Parent") @Tag(name = "家长 - 通知", description = "通知接口(家长专用)")
@RestController @RestController
@RequestMapping("/api/v1/parent/notifications") @RequestMapping("/api/v1/parent/notifications")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -19,13 +19,13 @@ public class ParentNotificationController {
private final NotificationService notificationService; private final NotificationService notificationService;
@Operation(summary = "Get notification by ID") @Operation(summary = "根据ID获取通知")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Notification> getNotification(@PathVariable Long id) { public Result<Notification> getNotification(@PathVariable Long id) {
return Result.success(notificationService.getNotificationById(id)); return Result.success(notificationService.getNotificationById(id));
} }
@Operation(summary = "Get my notifications") @Operation(summary = "获取我的通知")
@GetMapping @GetMapping
public Result<PageResult<Notification>> getMyNotifications( public Result<PageResult<Notification>> getMyNotifications(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -36,14 +36,14 @@ public class ParentNotificationController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Mark notification as read") @Operation(summary = "标记通知为已读")
@PostMapping("/{id}/read") @PostMapping("/{id}/read")
public Result<Void> markAsRead(@PathVariable Long id) { public Result<Void> markAsRead(@PathVariable Long id) {
notificationService.markAsRead(id); notificationService.markAsRead(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Mark all notifications as read") @Operation(summary = "标记所有通知为已读")
@PostMapping("/read-all") @PostMapping("/read-all")
public Result<Void> markAllAsRead() { public Result<Void> markAllAsRead() {
Long userId = SecurityUtils.getCurrentUserId(); Long userId = SecurityUtils.getCurrentUserId();
@ -51,7 +51,7 @@ public class ParentNotificationController {
return Result.success(); return Result.success();
} }
@Operation(summary = "Get unread count") @Operation(summary = "获取未读通知数量")
@GetMapping("/unread-count") @GetMapping("/unread-count")
public Result<Long> getUnreadCount() { public Result<Long> getUnreadCount() {
Long userId = SecurityUtils.getCurrentUserId(); Long userId = SecurityUtils.getCurrentUserId();

View File

@ -11,7 +11,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "Parent - Task", description = "Task APIs for Parent") @Tag(name = "家长 - 任务", description = "任务接口(家长专用)")
@RestController @RestController
@RequestMapping("/api/v1/parent/tasks") @RequestMapping("/api/v1/parent/tasks")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -19,13 +19,13 @@ public class ParentTaskController {
private final TaskService taskService; private final TaskService taskService;
@Operation(summary = "Get task by ID") @Operation(summary = "根据ID获取任务")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Task> getTask(@PathVariable Long id) { public Result<Task> getTask(@PathVariable Long id) {
return Result.success(taskService.getTaskById(id)); return Result.success(taskService.getTaskById(id));
} }
@Operation(summary = "Get tasks by student ID") @Operation(summary = "根据学生ID获取任务")
@GetMapping("/student/{studentId}") @GetMapping("/student/{studentId}")
public Result<PageResult<Task>> getTasksByStudent( public Result<PageResult<Task>> getTasksByStudent(
@PathVariable Long studentId, @PathVariable Long studentId,
@ -36,7 +36,7 @@ public class ParentTaskController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Complete task") @Operation(summary = "完成任务")
@PostMapping("/{taskId}/complete") @PostMapping("/{taskId}/complete")
public Result<Void> completeTask( public Result<Void> completeTask(
@PathVariable Long taskId, @PathVariable Long taskId,

View File

@ -16,7 +16,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.List; import java.util.List;
@Tag(name = "School - Class", description = "Class Management APIs for School") @Tag(name = "学校 - 班级", description = "班级管理接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/classes") @RequestMapping("/api/v1/school/classes")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -24,14 +24,14 @@ public class SchoolClassController {
private final ClassService classService; private final ClassService classService;
@Operation(summary = "Create class") @Operation(summary = "创建班级")
@PostMapping @PostMapping
public Result<Clazz> createClass(@Valid @RequestBody ClassCreateRequest request) { public Result<Clazz> createClass(@Valid @RequestBody ClassCreateRequest request) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
return Result.success(classService.createClass(tenantId, request)); return Result.success(classService.createClass(tenantId, request));
} }
@Operation(summary = "Update class") @Operation(summary = "更新班级")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<Clazz> updateClass(@PathVariable Long id, @RequestBody ClassUpdateRequest request) { public Result<Clazz> updateClass(@PathVariable Long id, @RequestBody ClassUpdateRequest request) {
return Result.success(classService.updateClass(id, request)); return Result.success(classService.updateClass(id, request));
@ -56,21 +56,21 @@ public class SchoolClassController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Delete class") @Operation(summary = "删除班级")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteClass(@PathVariable Long id) { public Result<Void> deleteClass(@PathVariable Long id) {
classService.deleteClass(id); classService.deleteClass(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Assign teachers to class") @Operation(summary = "分配教师到班级")
@PostMapping("/{id}/teachers") @PostMapping("/{id}/teachers")
public Result<Void> assignTeachers(@PathVariable Long id, @RequestBody List<Long> teacherIds) { public Result<Void> assignTeachers(@PathVariable Long id, @RequestBody List<Long> teacherIds) {
classService.assignTeachers(id, teacherIds); classService.assignTeachers(id, teacherIds);
return Result.success(); return Result.success();
} }
@Operation(summary = "Assign students to class") @Operation(summary = "分配学生到班级")
@PostMapping("/{id}/students") @PostMapping("/{id}/students")
public Result<Void> assignStudents(@PathVariable Long id, @RequestBody List<Long> studentIds) { public Result<Void> assignStudents(@PathVariable Long id, @RequestBody List<Long> studentIds) {
classService.assignStudents(id, studentIds); classService.assignStudents(id, studentIds);

View File

@ -13,7 +13,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "School - School Courses", description = "School Custom Course Management") @Tag(name = "学校 - 校本课程", description = "校本课程管理接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/school-courses") @RequestMapping("/api/v1/school/school-courses")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -22,7 +22,7 @@ public class SchoolCourseController {
private final SchoolCourseService schoolCourseService; private final SchoolCourseService schoolCourseService;
@Operation(summary = "Get school courses") @Operation(summary = "获取校本课程")
@GetMapping @GetMapping
public Result<PageResult<SchoolCourse>> getCourses( public Result<PageResult<SchoolCourse>> getCourses(
@RequestParam(defaultValue = "1") int pageNum, @RequestParam(defaultValue = "1") int pageNum,
@ -33,13 +33,13 @@ public class SchoolCourseController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Get school course by ID") @Operation(summary = "根据ID获取校本课程")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<SchoolCourse> getCourse(@PathVariable Long id) { public Result<SchoolCourse> getCourse(@PathVariable Long id) {
return Result.success(schoolCourseService.getCourseById(id)); return Result.success(schoolCourseService.getCourseById(id));
} }
@Operation(summary = "Create school course") @Operation(summary = "创建校本课程")
@PostMapping @PostMapping
public Result<SchoolCourse> createCourse(@RequestBody SchoolCourse course) { public Result<SchoolCourse> createCourse(@RequestBody SchoolCourse course) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
@ -47,13 +47,13 @@ public class SchoolCourseController {
return Result.success(schoolCourseService.createCourse(tenantId, userId, course)); return Result.success(schoolCourseService.createCourse(tenantId, userId, course));
} }
@Operation(summary = "Update school course") @Operation(summary = "更新校本课程")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<SchoolCourse> updateCourse(@PathVariable Long id, @RequestBody SchoolCourse course) { public Result<SchoolCourse> updateCourse(@PathVariable Long id, @RequestBody SchoolCourse course) {
return Result.success(schoolCourseService.updateCourse(id, course)); return Result.success(schoolCourseService.updateCourse(id, course));
} }
@Operation(summary = "Delete school course") @Operation(summary = "删除校本课程")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteCourse(@PathVariable Long id) { public Result<Void> deleteCourse(@PathVariable Long id) {
schoolCourseService.deleteCourse(id); schoolCourseService.deleteCourse(id);

View File

@ -12,7 +12,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "School - Course Packages", description = "Course Packages for School") @Tag(name = "学校 - 课程包", description = "课程包接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/course-packages") @RequestMapping("/api/v1/school/course-packages")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -21,7 +21,7 @@ public class SchoolCoursePackageController {
private final CoursePackageService coursePackageService; private final CoursePackageService coursePackageService;
@Operation(summary = "Get available course packages") @Operation(summary = "获取可用课程包列表")
@GetMapping @GetMapping
public Result<PageResult<CoursePackage>> getPackages( public Result<PageResult<CoursePackage>> getPackages(
@RequestParam(defaultValue = "1") int pageNum, @RequestParam(defaultValue = "1") int pageNum,
@ -31,7 +31,7 @@ public class SchoolCoursePackageController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Get course package by ID") @Operation(summary = "根据ID获取课程包")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<CoursePackage> getPackage(@PathVariable Long id) { public Result<CoursePackage> getPackage(@PathVariable Long id) {
return Result.success(coursePackageService.getPackageById(id)); return Result.success(coursePackageService.getPackageById(id));

View File

@ -15,7 +15,7 @@ import org.springframework.web.bind.annotation.*;
import java.io.IOException; import java.io.IOException;
import java.time.LocalDate; import java.time.LocalDate;
@Tag(name = "School - Export", description = "School Data Export") @Tag(name = "学校 - 导出", description = "学校数据导出接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/export") @RequestMapping("/api/v1/school/export")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -24,7 +24,7 @@ public class SchoolExportController {
private final ExportService exportService; private final ExportService exportService;
@Operation(summary = "Export teachers to Excel") @Operation(summary = "导出教师信息到Excel")
@GetMapping("/teachers") @GetMapping("/teachers")
public ResponseEntity<byte[]> exportTeachers() throws IOException { public ResponseEntity<byte[]> exportTeachers() throws IOException {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
@ -32,7 +32,7 @@ public class SchoolExportController {
return buildResponse(data, "teachers_" + LocalDate.now() + ".xlsx"); return buildResponse(data, "teachers_" + LocalDate.now() + ".xlsx");
} }
@Operation(summary = "Export students to Excel") @Operation(summary = "导出学生信息到Excel")
@GetMapping("/students") @GetMapping("/students")
public ResponseEntity<byte[]> exportStudents() throws IOException { public ResponseEntity<byte[]> exportStudents() throws IOException {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
@ -40,7 +40,7 @@ public class SchoolExportController {
return buildResponse(data, "students_" + LocalDate.now() + ".xlsx"); return buildResponse(data, "students_" + LocalDate.now() + ".xlsx");
} }
@Operation(summary = "Export lessons to Excel") @Operation(summary = "导出课时信息到Excel")
@GetMapping("/lessons") @GetMapping("/lessons")
public ResponseEntity<byte[]> exportLessons() throws IOException { public ResponseEntity<byte[]> exportLessons() throws IOException {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
@ -48,7 +48,7 @@ public class SchoolExportController {
return buildResponse(data, "lessons_" + LocalDate.now() + ".xlsx"); return buildResponse(data, "lessons_" + LocalDate.now() + ".xlsx");
} }
@Operation(summary = "Export growth records to Excel") @Operation(summary = "导出成长档案到Excel")
@GetMapping("/growth-records") @GetMapping("/growth-records")
public ResponseEntity<byte[]> exportGrowthRecords() throws IOException { public ResponseEntity<byte[]> exportGrowthRecords() throws IOException {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();

View File

@ -14,7 +14,7 @@ import jakarta.validation.Valid;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "School - Growth Record", description = "Growth Record Management APIs for School") @Tag(name = "学校 - 成长档案", description = "成长档案管理接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/growth-records") @RequestMapping("/api/v1/school/growth-records")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -22,7 +22,7 @@ public class SchoolGrowthController {
private final GrowthRecordService growthRecordService; private final GrowthRecordService growthRecordService;
@Operation(summary = "Create growth record") @Operation(summary = "创建成长档案")
@PostMapping @PostMapping
public Result<GrowthRecord> createGrowthRecord(@Valid @RequestBody GrowthRecordCreateRequest request) { public Result<GrowthRecord> createGrowthRecord(@Valid @RequestBody GrowthRecordCreateRequest request) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
@ -31,19 +31,19 @@ public class SchoolGrowthController {
return Result.success(growthRecordService.createGrowthRecord(tenantId, userId, role, request)); return Result.success(growthRecordService.createGrowthRecord(tenantId, userId, role, request));
} }
@Operation(summary = "Update growth record") @Operation(summary = "更新成长档案")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<GrowthRecord> updateGrowthRecord(@PathVariable Long id, @RequestBody GrowthRecordUpdateRequest request) { public Result<GrowthRecord> updateGrowthRecord(@PathVariable Long id, @RequestBody GrowthRecordUpdateRequest request) {
return Result.success(growthRecordService.updateGrowthRecord(id, request)); return Result.success(growthRecordService.updateGrowthRecord(id, request));
} }
@Operation(summary = "Get growth record by ID") @Operation(summary = "根据ID获取成长档案")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<GrowthRecord> getGrowthRecord(@PathVariable Long id) { public Result<GrowthRecord> getGrowthRecord(@PathVariable Long id) {
return Result.success(growthRecordService.getGrowthRecordById(id)); return Result.success(growthRecordService.getGrowthRecordById(id));
} }
@Operation(summary = "Get growth record page") @Operation(summary = "获取成长档案分页")
@GetMapping @GetMapping
public Result<PageResult<GrowthRecord>> getGrowthRecordPage( public Result<PageResult<GrowthRecord>> getGrowthRecordPage(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -55,7 +55,7 @@ public class SchoolGrowthController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Delete growth record") @Operation(summary = "删除成长档案")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteGrowthRecord(@PathVariable Long id) { public Result<Void> deleteGrowthRecord(@PathVariable Long id) {
growthRecordService.deleteGrowthRecord(id); growthRecordService.deleteGrowthRecord(id);

View File

@ -13,7 +13,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "School - Operation Logs", description = "Operation Log for School") @Tag(name = "学校 - 操作日志", description = "操作日志接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/operation-logs") @RequestMapping("/api/v1/school/operation-logs")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -22,7 +22,7 @@ public class SchoolOperationLogController {
private final OperationLogService operationLogService; private final OperationLogService operationLogService;
@Operation(summary = "Get school operation logs") @Operation(summary = "获取学校操作日志")
@GetMapping @GetMapping
public Result<PageResult<OperationLog>> getLogs( public Result<PageResult<OperationLog>> getLogs(
@RequestParam(defaultValue = "1") int pageNum, @RequestParam(defaultValue = "1") int pageNum,

View File

@ -14,7 +14,7 @@ import jakarta.validation.Valid;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "School - Parent", description = "Parent Management APIs for School") @Tag(name = "学校 - 家长", description = "家长管理接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/parents") @RequestMapping("/api/v1/school/parents")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -22,14 +22,14 @@ public class SchoolParentController {
private final ParentService parentService; private final ParentService parentService;
@Operation(summary = "Create parent") @Operation(summary = "创建家长")
@PostMapping @PostMapping
public Result<Parent> createParent(@Valid @RequestBody ParentCreateRequest request) { public Result<Parent> createParent(@Valid @RequestBody ParentCreateRequest request) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
return Result.success(parentService.createParent(tenantId, request)); return Result.success(parentService.createParent(tenantId, request));
} }
@Operation(summary = "Update parent") @Operation(summary = "更新家长")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<Parent> updateParent(@PathVariable Long id, @RequestBody ParentUpdateRequest request) { public Result<Parent> updateParent(@PathVariable Long id, @RequestBody ParentUpdateRequest request) {
return Result.success(parentService.updateParent(id, request)); return Result.success(parentService.updateParent(id, request));
@ -41,7 +41,7 @@ public class SchoolParentController {
return Result.success(parentService.getParentById(id)); return Result.success(parentService.getParentById(id));
} }
@Operation(summary = "Get parent page") @Operation(summary = "获取家长分页")
@GetMapping @GetMapping
public Result<PageResult<Parent>> getParentPage( public Result<PageResult<Parent>> getParentPage(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -53,21 +53,21 @@ public class SchoolParentController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Delete parent") @Operation(summary = "删除家长")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteParent(@PathVariable Long id) { public Result<Void> deleteParent(@PathVariable Long id) {
parentService.deleteParent(id); parentService.deleteParent(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Reset parent password") @Operation(summary = "重置家长密码")
@PostMapping("/{id}/reset-password") @PostMapping("/{id}/reset-password")
public Result<Void> resetPassword(@PathVariable Long id, @RequestParam String newPassword) { public Result<Void> resetPassword(@PathVariable Long id, @RequestParam String newPassword) {
parentService.resetPassword(id, newPassword); parentService.resetPassword(id, newPassword);
return Result.success(); return Result.success();
} }
@Operation(summary = "Bind student to parent") @Operation(summary = "绑定学生到家长")
@PostMapping("/{parentId}/students/{studentId}") @PostMapping("/{parentId}/students/{studentId}")
public Result<Void> bindStudent( public Result<Void> bindStudent(
@PathVariable Long parentId, @PathVariable Long parentId,
@ -78,7 +78,7 @@ public class SchoolParentController {
return Result.success(); return Result.success();
} }
@Operation(summary = "Unbind student from parent") @Operation(summary = "解绑家长与学生关系")
@DeleteMapping("/{parentId}/students/{studentId}") @DeleteMapping("/{parentId}/students/{studentId}")
public Result<Void> unbindStudent(@PathVariable Long parentId, @PathVariable Long studentId) { public Result<Void> unbindStudent(@PathVariable Long parentId, @PathVariable Long studentId) {
parentService.unbindStudent(parentId, studentId); parentService.unbindStudent(parentId, studentId);

View File

@ -14,7 +14,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "School - Schedule", description = "School Schedule Management") @Tag(name = "学校 - 课表", description = "课表管理接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/schedules") @RequestMapping("/api/v1/school/schedules")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -23,7 +23,7 @@ public class SchoolScheduleController {
private final ScheduleService scheduleService; private final ScheduleService scheduleService;
@Operation(summary = "Get schedule plans") @Operation(summary = "获取课表计划")
@GetMapping @GetMapping
public Result<PageResult<SchedulePlan>> getSchedulePlans( public Result<PageResult<SchedulePlan>> getSchedulePlans(
@RequestParam(defaultValue = "1") int pageNum, @RequestParam(defaultValue = "1") int pageNum,
@ -34,33 +34,33 @@ public class SchoolScheduleController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Get schedule plan by ID") @Operation(summary = "根据ID获取课表计划")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<SchedulePlan> getSchedulePlan(@PathVariable Long id) { public Result<SchedulePlan> getSchedulePlan(@PathVariable Long id) {
return Result.success(scheduleService.getSchedulePlanById(id)); return Result.success(scheduleService.getSchedulePlanById(id));
} }
@Operation(summary = "Create schedule plan") @Operation(summary = "创建课表计划")
@PostMapping @PostMapping
public Result<SchedulePlan> createSchedulePlan(@RequestBody SchedulePlan plan) { public Result<SchedulePlan> createSchedulePlan(@RequestBody SchedulePlan plan) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
return Result.success(scheduleService.createSchedulePlan(tenantId, plan)); return Result.success(scheduleService.createSchedulePlan(tenantId, plan));
} }
@Operation(summary = "Update schedule plan") @Operation(summary = "更新课表计划")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<SchedulePlan> updateSchedulePlan(@PathVariable Long id, @RequestBody SchedulePlan plan) { public Result<SchedulePlan> updateSchedulePlan(@PathVariable Long id, @RequestBody SchedulePlan plan) {
return Result.success(scheduleService.updateSchedulePlan(id, plan)); return Result.success(scheduleService.updateSchedulePlan(id, plan));
} }
@Operation(summary = "Delete schedule plan") @Operation(summary = "删除课表计划")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteSchedulePlan(@PathVariable Long id) { public Result<Void> deleteSchedulePlan(@PathVariable Long id) {
scheduleService.deleteSchedulePlan(id); scheduleService.deleteSchedulePlan(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Get schedule templates") @Operation(summary = "获取课表模板")
@GetMapping("/templates") @GetMapping("/templates")
public Result<PageResult<ScheduleTemplate>> getScheduleTemplates( public Result<PageResult<ScheduleTemplate>> getScheduleTemplates(
@RequestParam(defaultValue = "1") int pageNum, @RequestParam(defaultValue = "1") int pageNum,
@ -70,14 +70,14 @@ public class SchoolScheduleController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Create schedule template") @Operation(summary = "创建课表模板")
@PostMapping("/templates") @PostMapping("/templates")
public Result<ScheduleTemplate> createScheduleTemplate(@RequestBody ScheduleTemplate template) { public Result<ScheduleTemplate> createScheduleTemplate(@RequestBody ScheduleTemplate template) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
return Result.success(scheduleService.createScheduleTemplate(tenantId, template)); return Result.success(scheduleService.createScheduleTemplate(tenantId, template));
} }
@Operation(summary = "Delete schedule template") @Operation(summary = "删除课表模板")
@DeleteMapping("/templates/{id}") @DeleteMapping("/templates/{id}")
public Result<Void> deleteScheduleTemplate(@PathVariable Long id) { public Result<Void> deleteScheduleTemplate(@PathVariable Long id) {
scheduleService.deleteScheduleTemplate(id); scheduleService.deleteScheduleTemplate(id);

View File

@ -12,7 +12,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.Map; import java.util.Map;
@Tag(name = "School - Settings", description = "School Settings Management") @Tag(name = "学校 - 设置", description = "学校设置管理接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/settings") @RequestMapping("/api/v1/school/settings")
@RequiredArgsConstructor @RequiredArgsConstructor

View File

@ -12,7 +12,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.Map; import java.util.Map;
@Tag(name = "School - Stats", description = "School Statistics Dashboard") @Tag(name = "学校 - 统计", description = "学校统计仪表盘接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/stats") @RequestMapping("/api/v1/school/stats")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -21,7 +21,7 @@ public class SchoolStatsController {
private final SchoolStatsService schoolStatsService; private final SchoolStatsService schoolStatsService;
@Operation(summary = "Get school statistics") @Operation(summary = "获取学校统计数据")
@GetMapping @GetMapping
public Result<Map<String, Object>> getStats() { public Result<Map<String, Object>> getStats() {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();

View File

@ -14,7 +14,7 @@ import jakarta.validation.Valid;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "School - Student", description = "Student Management APIs for School") @Tag(name = "学校 - 学生", description = "学生管理接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/students") @RequestMapping("/api/v1/school/students")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -22,26 +22,26 @@ public class SchoolStudentController {
private final StudentService studentService; private final StudentService studentService;
@Operation(summary = "Create student") @Operation(summary = "创建学生")
@PostMapping @PostMapping
public Result<Student> createStudent(@Valid @RequestBody StudentCreateRequest request) { public Result<Student> createStudent(@Valid @RequestBody StudentCreateRequest request) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
return Result.success(studentService.createStudent(tenantId, request)); return Result.success(studentService.createStudent(tenantId, request));
} }
@Operation(summary = "Update student") @Operation(summary = "更新学生")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<Student> updateStudent(@PathVariable Long id, @RequestBody StudentUpdateRequest request) { public Result<Student> updateStudent(@PathVariable Long id, @RequestBody StudentUpdateRequest request) {
return Result.success(studentService.updateStudent(id, request)); return Result.success(studentService.updateStudent(id, request));
} }
@Operation(summary = "Get student by ID") @Operation(summary = "根据ID获取学生")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Student> getStudent(@PathVariable Long id) { public Result<Student> getStudent(@PathVariable Long id) {
return Result.success(studentService.getStudentById(id)); return Result.success(studentService.getStudentById(id));
} }
@Operation(summary = "Get student page") @Operation(summary = "获取学生分页")
@GetMapping @GetMapping
public Result<PageResult<Student>> getStudentPage( public Result<PageResult<Student>> getStudentPage(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -54,7 +54,7 @@ public class SchoolStudentController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Delete student") @Operation(summary = "删除学生")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteStudent(@PathVariable Long id) { public Result<Void> deleteStudent(@PathVariable Long id) {
studentService.deleteStudent(id); studentService.deleteStudent(id);

View File

@ -14,7 +14,7 @@ import jakarta.validation.Valid;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "School - Task", description = "Task Management APIs for School") @Tag(name = "学校 - 任务", description = "任务管理接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/tasks") @RequestMapping("/api/v1/school/tasks")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -22,7 +22,7 @@ public class SchoolTaskController {
private final TaskService taskService; private final TaskService taskService;
@Operation(summary = "Create task") @Operation(summary = "创建任务")
@PostMapping @PostMapping
public Result<Task> createTask(@Valid @RequestBody TaskCreateRequest request) { public Result<Task> createTask(@Valid @RequestBody TaskCreateRequest request) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
@ -31,19 +31,19 @@ public class SchoolTaskController {
return Result.success(taskService.createTask(tenantId, userId, role, request)); return Result.success(taskService.createTask(tenantId, userId, role, request));
} }
@Operation(summary = "Update task") @Operation(summary = "更新任务")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<Task> updateTask(@PathVariable Long id, @RequestBody TaskUpdateRequest request) { public Result<Task> updateTask(@PathVariable Long id, @RequestBody TaskUpdateRequest request) {
return Result.success(taskService.updateTask(id, request)); return Result.success(taskService.updateTask(id, request));
} }
@Operation(summary = "Get task by ID") @Operation(summary = "根据ID获取任务")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Task> getTask(@PathVariable Long id) { public Result<Task> getTask(@PathVariable Long id) {
return Result.success(taskService.getTaskById(id)); return Result.success(taskService.getTaskById(id));
} }
@Operation(summary = "Get task page") @Operation(summary = "获取任务分页")
@GetMapping @GetMapping
public Result<PageResult<Task>> getTaskPage( public Result<PageResult<Task>> getTaskPage(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -56,7 +56,7 @@ public class SchoolTaskController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Delete task") @Operation(summary = "删除任务")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteTask(@PathVariable Long id) { public Result<Void> deleteTask(@PathVariable Long id) {
taskService.deleteTask(id); taskService.deleteTask(id);

View File

@ -14,7 +14,7 @@ import jakarta.validation.Valid;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "School - Teacher", description = "Teacher Management APIs for School") @Tag(name = "学校 - 教师", description = "教师管理接口(学校管理员专用)")
@RestController @RestController
@RequestMapping("/api/v1/school/teachers") @RequestMapping("/api/v1/school/teachers")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -22,26 +22,26 @@ public class SchoolTeacherController {
private final TeacherService teacherService; private final TeacherService teacherService;
@Operation(summary = "Create teacher") @Operation(summary = "创建教师")
@PostMapping @PostMapping
public Result<Teacher> createTeacher(@Valid @RequestBody TeacherCreateRequest request) { public Result<Teacher> createTeacher(@Valid @RequestBody TeacherCreateRequest request) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
return Result.success(teacherService.createTeacher(tenantId, request)); return Result.success(teacherService.createTeacher(tenantId, request));
} }
@Operation(summary = "Update teacher") @Operation(summary = "更新教师")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<Teacher> updateTeacher(@PathVariable Long id, @RequestBody TeacherUpdateRequest request) { public Result<Teacher> updateTeacher(@PathVariable Long id, @RequestBody TeacherUpdateRequest request) {
return Result.success(teacherService.updateTeacher(id, request)); return Result.success(teacherService.updateTeacher(id, request));
} }
@Operation(summary = "Get teacher by ID") @Operation(summary = "根据ID获取教师")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Teacher> getTeacher(@PathVariable Long id) { public Result<Teacher> getTeacher(@PathVariable Long id) {
return Result.success(teacherService.getTeacherById(id)); return Result.success(teacherService.getTeacherById(id));
} }
@Operation(summary = "Get teacher page") @Operation(summary = "获取教师分页")
@GetMapping @GetMapping
public Result<PageResult<Teacher>> getTeacherPage( public Result<PageResult<Teacher>> getTeacherPage(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -53,14 +53,14 @@ public class SchoolTeacherController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Delete teacher") @Operation(summary = "删除教师")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteTeacher(@PathVariable Long id) { public Result<Void> deleteTeacher(@PathVariable Long id) {
teacherService.deleteTeacher(id); teacherService.deleteTeacher(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Reset teacher password") @Operation(summary = "重置教师密码")
@PostMapping("/{id}/reset-password") @PostMapping("/{id}/reset-password")
public Result<Void> resetPassword(@PathVariable Long id, @RequestParam String newPassword) { public Result<Void> resetPassword(@PathVariable Long id, @RequestParam String newPassword) {
teacherService.resetPassword(id, newPassword); teacherService.resetPassword(id, newPassword);

View File

@ -13,7 +13,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.List; import java.util.List;
@Tag(name = "Teacher - Course", description = "Course APIs for Teacher") @Tag(name = "教师 - 课程", description = "课程接口(教师专用)")
@RestController @RestController
@RequestMapping("/api/v1/teacher/courses") @RequestMapping("/api/v1/teacher/courses")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -21,13 +21,13 @@ public class TeacherCourseController {
private final CourseService courseService; private final CourseService courseService;
@Operation(summary = "Get course by ID") @Operation(summary = "根据ID获取课程")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Course> getCourse(@PathVariable Long id) { public Result<Course> getCourse(@PathVariable Long id) {
return Result.success(courseService.getCourseById(id)); return Result.success(courseService.getCourseById(id));
} }
@Operation(summary = "Get course page") @Operation(summary = "获取课程分页")
@GetMapping @GetMapping
public Result<PageResult<Course>> getCoursePage( public Result<PageResult<Course>> getCoursePage(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -39,7 +39,7 @@ public class TeacherCourseController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Get all courses") @Operation(summary = "获取所有课程")
@GetMapping("/all") @GetMapping("/all")
public Result<List<Course>> getAllCourses() { public Result<List<Course>> getAllCourses() {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();

View File

@ -12,7 +12,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.List; import java.util.List;
@Tag(name = "Teacher - Course Lessons", description = "Course Lessons for Teacher") @Tag(name = "教师 - 课程课时", description = "课程课时接口(教师专用)")
@RestController @RestController
@RequestMapping("/api/v1/teacher/courses/{courseId}/lessons") @RequestMapping("/api/v1/teacher/courses/{courseId}/lessons")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -21,13 +21,13 @@ public class TeacherCourseLessonController {
private final CourseLessonService courseLessonService; private final CourseLessonService courseLessonService;
@Operation(summary = "Get lessons for a course") @Operation(summary = "获取课程的课时列表")
@GetMapping @GetMapping
public Result<List<CourseLesson>> getLessons(@PathVariable Long courseId) { public Result<List<CourseLesson>> getLessons(@PathVariable Long courseId) {
return Result.success(courseLessonService.getLessonsByCourse(courseId)); return Result.success(courseLessonService.getLessonsByCourse(courseId));
} }
@Operation(summary = "Get lesson by ID") @Operation(summary = "根据ID获取课时")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<CourseLesson> getLesson(@PathVariable Long courseId, @PathVariable Long id) { public Result<CourseLesson> getLesson(@PathVariable Long courseId, @PathVariable Long id) {
return Result.success(courseLessonService.getLessonById(id)); return Result.success(courseLessonService.getLessonById(id));

View File

@ -13,7 +13,7 @@ import org.springframework.web.bind.annotation.*;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
@Tag(name = "Teacher - Dashboard", description = "Teacher Dashboard") @Tag(name = "教师 - 仪表盘", description = "教师仪表盘")
@RestController @RestController
@RequestMapping("/api/v1/teacher/dashboard") @RequestMapping("/api/v1/teacher/dashboard")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -22,7 +22,7 @@ public class TeacherDashboardController {
private final TeacherDashboardService teacherDashboardService; private final TeacherDashboardService teacherDashboardService;
@Operation(summary = "Get teacher dashboard overview") @Operation(summary = "获取教师仪表盘概览")
@GetMapping @GetMapping
public Result<Map<String, Object>> getDashboard() { public Result<Map<String, Object>> getDashboard() {
Long teacherId = SecurityUtils.getCurrentUserId(); Long teacherId = SecurityUtils.getCurrentUserId();
@ -30,7 +30,7 @@ public class TeacherDashboardController {
return Result.success(teacherDashboardService.getDashboard(teacherId, tenantId)); return Result.success(teacherDashboardService.getDashboard(teacherId, tenantId));
} }
@Operation(summary = "Get today's lessons") @Operation(summary = "获取今天课时")
@GetMapping("/today") @GetMapping("/today")
public Result<List<Map<String, Object>>> getTodayLessons() { public Result<List<Map<String, Object>>> getTodayLessons() {
Long teacherId = SecurityUtils.getCurrentUserId(); Long teacherId = SecurityUtils.getCurrentUserId();
@ -38,7 +38,7 @@ public class TeacherDashboardController {
return Result.success(teacherDashboardService.getTodayLessons(teacherId, tenantId)); return Result.success(teacherDashboardService.getTodayLessons(teacherId, tenantId));
} }
@Operation(summary = "Get weekly lessons") @Operation(summary = "获取本周课时")
@GetMapping("/weekly") @GetMapping("/weekly")
public Result<List<Map<String, Object>>> getWeeklyLessons() { public Result<List<Map<String, Object>>> getWeeklyLessons() {
Long teacherId = SecurityUtils.getCurrentUserId(); Long teacherId = SecurityUtils.getCurrentUserId();

View File

@ -14,7 +14,7 @@ import jakarta.validation.Valid;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "Teacher - Growth Record", description = "Growth Record APIs for Teacher") @Tag(name = "教师 - 成长档案", description = "成长档案接口(教师专用)")
@RestController @RestController
@RequestMapping("/api/v1/teacher/growth-records") @RequestMapping("/api/v1/teacher/growth-records")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -22,7 +22,7 @@ public class TeacherGrowthController {
private final GrowthRecordService growthRecordService; private final GrowthRecordService growthRecordService;
@Operation(summary = "Create growth record") @Operation(summary = "创建成长档案")
@PostMapping @PostMapping
public Result<GrowthRecord> createGrowthRecord(@Valid @RequestBody GrowthRecordCreateRequest request) { public Result<GrowthRecord> createGrowthRecord(@Valid @RequestBody GrowthRecordCreateRequest request) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
@ -30,19 +30,19 @@ public class TeacherGrowthController {
return Result.success(growthRecordService.createGrowthRecord(tenantId, userId, "teacher", request)); return Result.success(growthRecordService.createGrowthRecord(tenantId, userId, "teacher", request));
} }
@Operation(summary = "Update growth record") @Operation(summary = "更新成长档案")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<GrowthRecord> updateGrowthRecord(@PathVariable Long id, @RequestBody GrowthRecordUpdateRequest request) { public Result<GrowthRecord> updateGrowthRecord(@PathVariable Long id, @RequestBody GrowthRecordUpdateRequest request) {
return Result.success(growthRecordService.updateGrowthRecord(id, request)); return Result.success(growthRecordService.updateGrowthRecord(id, request));
} }
@Operation(summary = "Get growth record by ID") @Operation(summary = "根据ID获取成长档案")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<GrowthRecord> getGrowthRecord(@PathVariable Long id) { public Result<GrowthRecord> getGrowthRecord(@PathVariable Long id) {
return Result.success(growthRecordService.getGrowthRecordById(id)); return Result.success(growthRecordService.getGrowthRecordById(id));
} }
@Operation(summary = "Get growth record page") @Operation(summary = "获取成长档案分页")
@GetMapping @GetMapping
public Result<PageResult<GrowthRecord>> getGrowthRecordPage( public Result<PageResult<GrowthRecord>> getGrowthRecordPage(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -54,7 +54,7 @@ public class TeacherGrowthController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Delete growth record") @Operation(summary = "删除成长档案")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteGrowthRecord(@PathVariable Long id) { public Result<Void> deleteGrowthRecord(@PathVariable Long id) {
growthRecordService.deleteGrowthRecord(id); growthRecordService.deleteGrowthRecord(id);

View File

@ -18,7 +18,7 @@ import org.springframework.web.bind.annotation.*;
import java.time.LocalDate; import java.time.LocalDate;
import java.util.List; import java.util.List;
@Tag(name = "Teacher - Lesson", description = "Lesson APIs for Teacher") @Tag(name = "教师 - 课时", description = "课时接口(教师专用)")
@RestController @RestController
@RequestMapping("/api/v1/teacher/lessons") @RequestMapping("/api/v1/teacher/lessons")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -26,26 +26,26 @@ public class TeacherLessonController {
private final LessonService lessonService; private final LessonService lessonService;
@Operation(summary = "Create lesson") @Operation(summary = "创建课时")
@PostMapping @PostMapping
public Result<Lesson> createLesson(@Valid @RequestBody LessonCreateRequest request) { public Result<Lesson> createLesson(@Valid @RequestBody LessonCreateRequest request) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
return Result.success(lessonService.createLesson(tenantId, request)); return Result.success(lessonService.createLesson(tenantId, request));
} }
@Operation(summary = "Update lesson") @Operation(summary = "更新课时")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<Lesson> updateLesson(@PathVariable Long id, @RequestBody LessonUpdateRequest request) { public Result<Lesson> updateLesson(@PathVariable Long id, @RequestBody LessonUpdateRequest request) {
return Result.success(lessonService.updateLesson(id, request)); return Result.success(lessonService.updateLesson(id, request));
} }
@Operation(summary = "Get lesson by ID") @Operation(summary = "根据ID获取课时")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Lesson> getLesson(@PathVariable Long id) { public Result<Lesson> getLesson(@PathVariable Long id) {
return Result.success(lessonService.getLessonById(id)); return Result.success(lessonService.getLessonById(id));
} }
@Operation(summary = "Get my lessons") @Operation(summary = "获取我的课时")
@GetMapping @GetMapping
public Result<PageResult<Lesson>> getMyLessons( public Result<PageResult<Lesson>> getMyLessons(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -58,7 +58,7 @@ public class TeacherLessonController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Start lesson") @Operation(summary = "开始课时")
@PostMapping("/{id}/start") @PostMapping("/{id}/start")
public Result<Void> startLesson(@PathVariable Long id) { public Result<Void> startLesson(@PathVariable Long id) {
lessonService.startLesson(id); lessonService.startLesson(id);
@ -72,14 +72,14 @@ public class TeacherLessonController {
return Result.success(); return Result.success();
} }
@Operation(summary = "Cancel lesson") @Operation(summary = "取消课时")
@PostMapping("/{id}/cancel") @PostMapping("/{id}/cancel")
public Result<Void> cancelLesson(@PathVariable Long id) { public Result<Void> cancelLesson(@PathVariable Long id) {
lessonService.cancelLesson(id); lessonService.cancelLesson(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Get today's lessons") @Operation(summary = "获取今天课时")
@GetMapping("/today") @GetMapping("/today")
public Result<List<Lesson>> getTodayLessons() { public Result<List<Lesson>> getTodayLessons() {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();

View File

@ -11,7 +11,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "Teacher - Notification", description = "Notification APIs for Teacher") @Tag(name = "教师 - 通知", description = "通知接口(教师专用)")
@RestController @RestController
@RequestMapping("/api/v1/teacher/notifications") @RequestMapping("/api/v1/teacher/notifications")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -19,13 +19,13 @@ public class TeacherNotificationController {
private final NotificationService notificationService; private final NotificationService notificationService;
@Operation(summary = "Get notification by ID") @Operation(summary = "根据ID获取通知")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Notification> getNotification(@PathVariable Long id) { public Result<Notification> getNotification(@PathVariable Long id) {
return Result.success(notificationService.getNotificationById(id)); return Result.success(notificationService.getNotificationById(id));
} }
@Operation(summary = "Get my notifications") @Operation(summary = "获取我的通知")
@GetMapping @GetMapping
public Result<PageResult<Notification>> getMyNotifications( public Result<PageResult<Notification>> getMyNotifications(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -36,14 +36,14 @@ public class TeacherNotificationController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Mark notification as read") @Operation(summary = "标记通知为已读")
@PostMapping("/{id}/read") @PostMapping("/{id}/read")
public Result<Void> markAsRead(@PathVariable Long id) { public Result<Void> markAsRead(@PathVariable Long id) {
notificationService.markAsRead(id); notificationService.markAsRead(id);
return Result.success(); return Result.success();
} }
@Operation(summary = "Mark all notifications as read") @Operation(summary = "标记所有通知为已读")
@PostMapping("/read-all") @PostMapping("/read-all")
public Result<Void> markAllAsRead() { public Result<Void> markAllAsRead() {
Long userId = SecurityUtils.getCurrentUserId(); Long userId = SecurityUtils.getCurrentUserId();
@ -51,7 +51,7 @@ public class TeacherNotificationController {
return Result.success(); return Result.success();
} }
@Operation(summary = "Get unread count") @Operation(summary = "获取未读通知数量")
@GetMapping("/unread-count") @GetMapping("/unread-count")
public Result<Long> getUnreadCount() { public Result<Long> getUnreadCount() {
Long userId = SecurityUtils.getCurrentUserId(); Long userId = SecurityUtils.getCurrentUserId();

View File

@ -13,7 +13,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "Teacher - Schedule", description = "Teacher Schedule View") @Tag(name = "教师 - 课表", description = "教师课表视图")
@RestController @RestController
@RequestMapping("/api/v1/teacher/schedules") @RequestMapping("/api/v1/teacher/schedules")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -22,7 +22,7 @@ public class TeacherScheduleController {
private final ScheduleService scheduleService; private final ScheduleService scheduleService;
@Operation(summary = "Get teacher schedule plans") @Operation(summary = "获取教师课表计划")
@GetMapping @GetMapping
public Result<PageResult<SchedulePlan>> getSchedulePlans( public Result<PageResult<SchedulePlan>> getSchedulePlans(
@RequestParam(defaultValue = "1") int pageNum, @RequestParam(defaultValue = "1") int pageNum,
@ -32,7 +32,7 @@ public class TeacherScheduleController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Get schedule plan by ID") @Operation(summary = "根据ID获取课表计划")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<SchedulePlan> getSchedulePlan(@PathVariable Long id) { public Result<SchedulePlan> getSchedulePlan(@PathVariable Long id) {
return Result.success(scheduleService.getSchedulePlanById(id)); return Result.success(scheduleService.getSchedulePlanById(id));

View File

@ -13,7 +13,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "Teacher - School Courses", description = "School Courses for Teacher") @Tag(name = "教师 - 校本课程", description = "校本课程接口(教师专用)")
@RestController @RestController
@RequestMapping("/api/v1/teacher/school-courses") @RequestMapping("/api/v1/teacher/school-courses")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -22,7 +22,7 @@ public class TeacherSchoolCourseController {
private final SchoolCourseService schoolCourseService; private final SchoolCourseService schoolCourseService;
@Operation(summary = "Get school courses") @Operation(summary = "获取校本课程")
@GetMapping @GetMapping
public Result<PageResult<SchoolCourse>> getCourses( public Result<PageResult<SchoolCourse>> getCourses(
@RequestParam(defaultValue = "1") int pageNum, @RequestParam(defaultValue = "1") int pageNum,
@ -33,7 +33,7 @@ public class TeacherSchoolCourseController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Get school course by ID") @Operation(summary = "根据ID获取校本课程")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<SchoolCourse> getCourse(@PathVariable Long id) { public Result<SchoolCourse> getCourse(@PathVariable Long id) {
return Result.success(schoolCourseService.getCourseById(id)); return Result.success(schoolCourseService.getCourseById(id));

View File

@ -14,7 +14,7 @@ import jakarta.validation.Valid;
import lombok.RequiredArgsConstructor; import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
@Tag(name = "Teacher - Task", description = "Task APIs for Teacher") @Tag(name = "教师 - 任务", description = "任务接口(教师专用)")
@RestController @RestController
@RequestMapping("/api/v1/teacher/tasks") @RequestMapping("/api/v1/teacher/tasks")
@RequiredArgsConstructor @RequiredArgsConstructor
@ -22,7 +22,7 @@ public class TeacherTaskController {
private final TaskService taskService; private final TaskService taskService;
@Operation(summary = "Create task") @Operation(summary = "创建任务")
@PostMapping @PostMapping
public Result<Task> createTask(@Valid @RequestBody TaskCreateRequest request) { public Result<Task> createTask(@Valid @RequestBody TaskCreateRequest request) {
Long tenantId = SecurityUtils.getCurrentTenantId(); Long tenantId = SecurityUtils.getCurrentTenantId();
@ -30,19 +30,19 @@ public class TeacherTaskController {
return Result.success(taskService.createTask(tenantId, userId, "teacher", request)); return Result.success(taskService.createTask(tenantId, userId, "teacher", request));
} }
@Operation(summary = "Update task") @Operation(summary = "更新任务")
@PutMapping("/{id}") @PutMapping("/{id}")
public Result<Task> updateTask(@PathVariable Long id, @RequestBody TaskUpdateRequest request) { public Result<Task> updateTask(@PathVariable Long id, @RequestBody TaskUpdateRequest request) {
return Result.success(taskService.updateTask(id, request)); return Result.success(taskService.updateTask(id, request));
} }
@Operation(summary = "Get task by ID") @Operation(summary = "根据ID获取任务")
@GetMapping("/{id}") @GetMapping("/{id}")
public Result<Task> getTask(@PathVariable Long id) { public Result<Task> getTask(@PathVariable Long id) {
return Result.success(taskService.getTaskById(id)); return Result.success(taskService.getTaskById(id));
} }
@Operation(summary = "Get task page") @Operation(summary = "获取任务分页")
@GetMapping @GetMapping
public Result<PageResult<Task>> getTaskPage( public Result<PageResult<Task>> getTaskPage(
@RequestParam(value = "page", required = false) Integer pageNum, @RequestParam(value = "page", required = false) Integer pageNum,
@ -55,7 +55,7 @@ public class TeacherTaskController {
return Result.success(PageResult.of(page)); return Result.success(PageResult.of(page));
} }
@Operation(summary = "Delete task") @Operation(summary = "删除任务")
@DeleteMapping("/{id}") @DeleteMapping("/{id}")
public Result<Void> deleteTask(@PathVariable Long id) { public Result<Void> deleteTask(@PathVariable Long id) {
taskService.deleteTask(id); taskService.deleteTask(id);

View File

@ -5,20 +5,20 @@ import jakarta.validation.constraints.NotBlank;
import lombok.Data; import lombok.Data;
@Data @Data
@Schema(description = "Class Create Request") @Schema(description = "班级创建请求")
public class ClassCreateRequest { public class ClassCreateRequest {
@NotBlank(message = "Class name is required") @NotBlank(message = "班级名称不能为空")
@Schema(description = "Class name") @Schema(description = "班级名称")
private String name; private String name;
@Schema(description = "Grade") @Schema(description = "年级")
private String grade; private String grade;
@Schema(description = "Description") @Schema(description = "描述")
private String description; private String description;
@Schema(description = "Capacity") @Schema(description = "容量")
private Integer capacity; private Integer capacity;
} }

View File

@ -4,22 +4,22 @@ import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data; import lombok.Data;
@Data @Data
@Schema(description = "Class Update Request") @Schema(description = "班级更新请求")
public class ClassUpdateRequest { public class ClassUpdateRequest {
@Schema(description = "Class name") @Schema(description = "班级名称")
private String name; private String name;
@Schema(description = "Grade") @Schema(description = "年级")
private String grade; private String grade;
@Schema(description = "Description") @Schema(description = "描述")
private String description; private String description;
@Schema(description = "Capacity") @Schema(description = "容量")
private Integer capacity; private Integer capacity;
@Schema(description = "Status") @Schema(description = "状态")
private String status; private String status;
} }

View File

@ -7,135 +7,135 @@ import lombok.Data;
import java.util.List; import java.util.List;
@Data @Data
@Schema(description = "Course Create Request") @Schema(description = "课程创建请求")
public class CourseCreateRequest { public class CourseCreateRequest {
@NotBlank(message = "Course name is required") @NotBlank(message = "课程名称不能为空")
@Schema(description = "Course name") @Schema(description = "课程名称")
private String name; private String name;
@Schema(description = "Course code") @Schema(description = "课程编码")
private String code; private String code;
@Schema(description = "Description") @Schema(description = "描述")
private String description; private String description;
@Schema(description = "Cover URL") @Schema(description = "封面URL")
private String coverUrl; private String coverUrl;
@Schema(description = "Cover image path") @Schema(description = "封面图片路径")
private String coverImagePath; private String coverImagePath;
@Schema(description = "Category") @Schema(description = "分类")
private String category; private String category;
@Schema(description = "Age range") @Schema(description = "年龄段")
private String ageRange; private String ageRange;
@Schema(description = "Difficulty level") @Schema(description = "难度等级")
private String difficultyLevel; private String difficultyLevel;
@Schema(description = "Duration in minutes") @Schema(description = "时长(分钟)")
private Integer durationMinutes; private Integer durationMinutes;
@Schema(description = "Objectives") @Schema(description = "教学目标")
private String objectives; private String objectives;
// ============================================ // ============================================
// Course Package Refactoring Fields // 课程包重构字段
// ============================================ // ============================================
@Schema(description = "Core content") @Schema(description = "核心内容")
private String coreContent; private String coreContent;
// Course introduction (8 fields) // 课程介绍8个字段
@Schema(description = "Course summary") @Schema(description = "课程摘要")
private String introSummary; private String introSummary;
@Schema(description = "Course highlights") @Schema(description = "课程亮点")
private String introHighlights; private String introHighlights;
@Schema(description = "Course goals") @Schema(description = "课程目标")
private String introGoals; private String introGoals;
@Schema(description = "Content schedule") @Schema(description = "内容安排")
private String introSchedule; private String introSchedule;
@Schema(description = "Key points and difficulties") @Schema(description = "重点难点")
private String introKeyPoints; private String introKeyPoints;
@Schema(description = "Teaching methods") @Schema(description = "教学方法")
private String introMethods; private String introMethods;
@Schema(description = "Evaluation methods") @Schema(description = "评估方法")
private String introEvaluation; private String introEvaluation;
@Schema(description = "Notes and precautions") @Schema(description = "注意事项")
private String introNotes; private String introNotes;
// Schedule reference data // 课表参考数据
@Schema(description = "Schedule reference data (JSON)") @Schema(description = "课表参考数据JSON")
private String scheduleRefData; private String scheduleRefData;
// Environment construction (Step 7) // 环境创设步骤7
@Schema(description = "Environment construction content") @Schema(description = "环境创设内容")
private String environmentConstruction; private String environmentConstruction;
// Theme and picture book // 主题与绘本
@Schema(description = "Theme ID") @Schema(description = "主题ID")
private Long themeId; private Long themeId;
@Schema(description = "Picture book name") @Schema(description = "绘本名称")
private String pictureBookName; private String pictureBookName;
// Digital resources // 数字资源
@Schema(description = "Ebook paths (JSON array)") @Schema(description = "电子书路径JSON数组")
private String ebookPaths; private String ebookPaths;
@Schema(description = "Audio paths (JSON array)") @Schema(description = "音频路径JSON数组")
private String audioPaths; private String audioPaths;
@Schema(description = "Video paths (JSON array)") @Schema(description = "视频路径JSON数组")
private String videoPaths; private String videoPaths;
@Schema(description = "Other resources (JSON array)") @Schema(description = "其他资源JSON数组")
private String otherResources; private String otherResources;
// Teaching materials // 教学材料
@Schema(description = "PPT file path") @Schema(description = "PPT文件路径")
private String pptPath; private String pptPath;
@Schema(description = "PPT file name") @Schema(description = "PPT文件名")
private String pptName; private String pptName;
@Schema(description = "Poster paths (JSON array)") @Schema(description = "海报路径JSON数组")
private String posterPaths; private String posterPaths;
@Schema(description = "Teaching tools (JSON array)") @Schema(description = "教具JSON数组")
private String tools; private String tools;
@Schema(description = "Student materials") @Schema(description = "学生材料")
private String studentMaterials; private String studentMaterials;
// Lesson plan, activities, assessment // 教案活动评估
@Schema(description = "Lesson plan data (JSON)") @Schema(description = "教案数据JSON")
private String lessonPlanData; private String lessonPlanData;
@Schema(description = "Activities data (JSON)") @Schema(description = "活动数据JSON")
private String activitiesData; private String activitiesData;
@Schema(description = "Assessment data (JSON)") @Schema(description = "评估数据JSON")
private String assessmentData; private String assessmentData;
// Tags // 标签
@Schema(description = "Grade tags (JSON array)") @Schema(description = "年级标签JSON数组")
private String gradeTags; private String gradeTags;
@Schema(description = "Domain tags (JSON array)") @Schema(description = "领域标签JSON数组")
private String domainTags; private String domainTags;
// Collective lesson // 集体课
@Schema(description = "Has collective lesson") @Schema(description = "是否有集体课")
private Boolean hasCollectiveLesson; private Boolean hasCollectiveLesson;
} }

View File

@ -4,137 +4,137 @@ import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data; import lombok.Data;
@Data @Data
@Schema(description = "Course Update Request") @Schema(description = "课程更新请求")
public class CourseUpdateRequest { public class CourseUpdateRequest {
@Schema(description = "Course name") @Schema(description = "课程名称")
private String name; private String name;
@Schema(description = "Course code") @Schema(description = "课程编码")
private String code; private String code;
@Schema(description = "Description") @Schema(description = "描述")
private String description; private String description;
@Schema(description = "Cover URL") @Schema(description = "封面URL")
private String coverUrl; private String coverUrl;
@Schema(description = "Cover image path") @Schema(description = "封面图片路径")
private String coverImagePath; private String coverImagePath;
@Schema(description = "Category") @Schema(description = "分类")
private String category; private String category;
@Schema(description = "Age range") @Schema(description = "年龄段")
private String ageRange; private String ageRange;
@Schema(description = "Difficulty level") @Schema(description = "难度等级")
private String difficultyLevel; private String difficultyLevel;
@Schema(description = "Duration in minutes") @Schema(description = "时长(分钟)")
private Integer durationMinutes; private Integer durationMinutes;
@Schema(description = "Objectives") @Schema(description = "教学目标")
private String objectives; private String objectives;
@Schema(description = "Status") @Schema(description = "状态")
private String status; private String status;
// ============================================ // ============================================
// Course Package Refactoring Fields // 课程包重构字段
// ============================================ // ============================================
@Schema(description = "Core content") @Schema(description = "核心内容")
private String coreContent; private String coreContent;
// Course introduction (8 fields) // 课程介绍8个字段
@Schema(description = "Course summary") @Schema(description = "课程摘要")
private String introSummary; private String introSummary;
@Schema(description = "Course highlights") @Schema(description = "课程亮点")
private String introHighlights; private String introHighlights;
@Schema(description = "Course goals") @Schema(description = "课程目标")
private String introGoals; private String introGoals;
@Schema(description = "Content schedule") @Schema(description = "内容安排")
private String introSchedule; private String introSchedule;
@Schema(description = "Key points and difficulties") @Schema(description = "重点难点")
private String introKeyPoints; private String introKeyPoints;
@Schema(description = "Teaching methods") @Schema(description = "教学方法")
private String introMethods; private String introMethods;
@Schema(description = "Evaluation methods") @Schema(description = "评估方法")
private String introEvaluation; private String introEvaluation;
@Schema(description = "Notes and precautions") @Schema(description = "注意事项")
private String introNotes; private String introNotes;
// Schedule reference data // 课表参考数据
@Schema(description = "Schedule reference data (JSON)") @Schema(description = "课表参考数据JSON")
private String scheduleRefData; private String scheduleRefData;
// Environment construction (Step 7) // 环境创设步骤7
@Schema(description = "Environment construction content") @Schema(description = "环境创设内容")
private String environmentConstruction; private String environmentConstruction;
// Theme and picture book // 主题与绘本
@Schema(description = "Theme ID") @Schema(description = "主题ID")
private Long themeId; private Long themeId;
@Schema(description = "Picture book name") @Schema(description = "绘本名称")
private String pictureBookName; private String pictureBookName;
// Digital resources // 数字资源
@Schema(description = "Ebook paths (JSON array)") @Schema(description = "电子书路径JSON数组")
private String ebookPaths; private String ebookPaths;
@Schema(description = "Audio paths (JSON array)") @Schema(description = "音频路径JSON数组")
private String audioPaths; private String audioPaths;
@Schema(description = "Video paths (JSON array)") @Schema(description = "视频路径JSON数组")
private String videoPaths; private String videoPaths;
@Schema(description = "Other resources (JSON array)") @Schema(description = "其他资源JSON数组")
private String otherResources; private String otherResources;
// Teaching materials // 教学材料
@Schema(description = "PPT file path") @Schema(description = "PPT文件路径")
private String pptPath; private String pptPath;
@Schema(description = "PPT file name") @Schema(description = "PPT文件名")
private String pptName; private String pptName;
@Schema(description = "Poster paths (JSON array)") @Schema(description = "海报路径JSON数组")
private String posterPaths; private String posterPaths;
@Schema(description = "Teaching tools (JSON array)") @Schema(description = "教具JSON数组")
private String tools; private String tools;
@Schema(description = "Student materials") @Schema(description = "学生材料")
private String studentMaterials; private String studentMaterials;
// Lesson plan, activities, assessment // 教案活动评估
@Schema(description = "Lesson plan data (JSON)") @Schema(description = "教案数据JSON")
private String lessonPlanData; private String lessonPlanData;
@Schema(description = "Activities data (JSON)") @Schema(description = "活动数据JSON")
private String activitiesData; private String activitiesData;
@Schema(description = "Assessment data (JSON)") @Schema(description = "评估数据JSON")
private String assessmentData; private String assessmentData;
// Tags // 标签
@Schema(description = "Grade tags (JSON array)") @Schema(description = "年级标签JSON数组")
private String gradeTags; private String gradeTags;
@Schema(description = "Domain tags (JSON array)") @Schema(description = "领域标签JSON数组")
private String domainTags; private String domainTags;
// Collective lesson // 集体课
@Schema(description = "Has collective lesson") @Schema(description = "是否有集体课")
private Boolean hasCollectiveLesson; private Boolean hasCollectiveLesson;
} }

View File

@ -9,7 +9,7 @@ import java.time.LocalDate;
import java.util.List; import java.util.List;
@Data @Data
@Schema(description = "Growth Record Create Request") @Schema(description = "成长档案创建请求")
public class GrowthRecordCreateRequest { public class GrowthRecordCreateRequest {
@NotNull(message = "Student ID is required") @NotNull(message = "Student ID is required")

View File

@ -7,25 +7,25 @@ import java.time.LocalDate;
import java.util.List; import java.util.List;
@Data @Data
@Schema(description = "Growth Record Update Request") @Schema(description = "成长档案更新请求")
public class GrowthRecordUpdateRequest { public class GrowthRecordUpdateRequest {
@Schema(description = "Type") @Schema(description = "类型")
private String type; private String type;
@Schema(description = "Title") @Schema(description = "标题")
private String title; private String title;
@Schema(description = "Content") @Schema(description = "内容")
private String content; private String content;
@Schema(description = "Images (JSON array)") @Schema(description = "图片JSON数组")
private String images; private String images;
@Schema(description = "Record date") @Schema(description = "记录日期")
private LocalDate recordDate; private LocalDate recordDate;
@Schema(description = "Tags") @Schema(description = "标签")
private List<String> tags; private List<String> tags;
} }

View File

@ -9,38 +9,38 @@ import java.time.LocalDate;
import java.time.LocalTime; import java.time.LocalTime;
@Data @Data
@Schema(description = "Lesson Create Request") @Schema(description = "课时创建请求")
public class LessonCreateRequest { public class LessonCreateRequest {
@NotNull(message = "Course ID is required") @NotNull(message = "课程ID不能为空")
@Schema(description = "Course ID") @Schema(description = "课程ID")
private Long courseId; private Long courseId;
@Schema(description = "Class ID") @Schema(description = "班级ID")
private Long classId; private Long classId;
@NotNull(message = "Teacher ID is required") @NotNull(message = "教师ID不能为空")
@Schema(description = "Teacher ID") @Schema(description = "教师ID")
private Long teacherId; private Long teacherId;
@NotBlank(message = "Title is required") @NotBlank(message = "标题不能为空")
@Schema(description = "Lesson title") @Schema(description = "课时标题")
private String title; private String title;
@NotNull(message = "Lesson date is required") @NotNull(message = "课时日期不能为空")
@Schema(description = "Lesson date") @Schema(description = "课时日期")
private LocalDate lessonDate; private LocalDate lessonDate;
@Schema(description = "Start time") @Schema(description = "开始时间")
private LocalTime startTime; private LocalTime startTime;
@Schema(description = "End time") @Schema(description = "结束时间")
private LocalTime endTime; private LocalTime endTime;
@Schema(description = "Location") @Schema(description = "地点")
private String location; private String location;
@Schema(description = "Notes") @Schema(description = "备注")
private String notes; private String notes;
} }

View File

@ -7,7 +7,7 @@ import java.time.LocalDate;
import java.time.LocalTime; import java.time.LocalTime;
@Data @Data
@Schema(description = "Lesson Update Request") @Schema(description = "课时更新请求")
public class LessonUpdateRequest { public class LessonUpdateRequest {
@Schema(description = "Lesson title") @Schema(description = "Lesson title")

View File

@ -6,19 +6,19 @@ import jakarta.validation.constraints.NotBlank;
import lombok.Data; import lombok.Data;
@Data @Data
@Schema(description = "Login Request") @Schema(description = "登录请求")
public class LoginRequest { public class LoginRequest {
@NotBlank(message = "Username is required") @NotBlank(message = "用户名不能为空")
@JsonAlias("account") @JsonAlias("account")
@Schema(description = "Username", example = "admin") @Schema(description = "用户名", example = "admin")
private String username; private String username;
@NotBlank(message = "Password is required") @NotBlank(message = "密码不能为空")
@Schema(description = "Password", example = "admin123") @Schema(description = "密码", example = "admin123")
private String password; private String password;
@Schema(description = "Login role", example = "admin") @Schema(description = "登录角色", example = "admin")
private String role; private String role;
} }

View File

@ -8,25 +8,25 @@ import lombok.Data;
@Schema(description = "Parent Create Request") @Schema(description = "Parent Create Request")
public class ParentCreateRequest { public class ParentCreateRequest {
@NotBlank(message = "Username is required") @NotBlank(message = "用户名不能为空")
@Schema(description = "Username") @Schema(description = "用户名")
private String username; private String username;
@NotBlank(message = "Password is required") @NotBlank(message = "密码不能为空")
@Schema(description = "Password") @Schema(description = "密码")
private String password; private String password;
@NotBlank(message = "Name is required") @NotBlank(message = "姓名不能为空")
@Schema(description = "Name") @Schema(description = "姓名")
private String name; private String name;
@Schema(description = "Phone") @Schema(description = "电话")
private String phone; private String phone;
@Schema(description = "Email") @Schema(description = "邮箱")
private String email; private String email;
@Schema(description = "Gender") @Schema(description = "性别")
private String gender; private String gender;
} }

View File

@ -4,25 +4,25 @@ import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data; import lombok.Data;
@Data @Data
@Schema(description = "Parent Update Request") @Schema(description = "家长更新请求")
public class ParentUpdateRequest { public class ParentUpdateRequest {
@Schema(description = "Name") @Schema(description = "姓名")
private String name; private String name;
@Schema(description = "Phone") @Schema(description = "电话")
private String phone; private String phone;
@Schema(description = "Email") @Schema(description = "邮箱")
private String email; private String email;
@Schema(description = "Avatar URL") @Schema(description = "头像URL")
private String avatarUrl; private String avatarUrl;
@Schema(description = "Gender") @Schema(description = "性别")
private String gender; private String gender;
@Schema(description = "Status") @Schema(description = "状态")
private String status; private String status;
} }

View File

@ -7,7 +7,7 @@ import lombok.Data;
import java.time.LocalDate; import java.time.LocalDate;
@Data @Data
@Schema(description = "Student Create Request") @Schema(description = "学生创建请求")
public class StudentCreateRequest { public class StudentCreateRequest {
@NotBlank(message = "Name is required") @NotBlank(message = "Name is required")

View File

@ -6,37 +6,37 @@ import lombok.Data;
import java.time.LocalDate; import java.time.LocalDate;
@Data @Data
@Schema(description = "Student Update Request") @Schema(description = "学生更新请求")
public class StudentUpdateRequest { public class StudentUpdateRequest {
@Schema(description = "Name") @Schema(description = "姓名")
private String name; private String name;
@Schema(description = "Gender") @Schema(description = "性别")
private String gender; private String gender;
@Schema(description = "Birth date") @Schema(description = "出生日期")
private LocalDate birthDate; private LocalDate birthDate;
@Schema(description = "Avatar URL") @Schema(description = "头像URL")
private String avatarUrl; private String avatarUrl;
@Schema(description = "Grade") @Schema(description = "年级")
private String grade; private String grade;
@Schema(description = "Student number") @Schema(description = "学号")
private String studentNo; private String studentNo;
@Schema(description = "Reading level") @Schema(description = "阅读水平")
private String readingLevel; private String readingLevel;
@Schema(description = "Interests") @Schema(description = "兴趣爱好")
private String interests; private String interests;
@Schema(description = "Notes") @Schema(description = "备注")
private String notes; private String notes;
@Schema(description = "Status") @Schema(description = "状态")
private String status; private String status;
} }

View File

@ -8,35 +8,35 @@ import java.time.LocalDate;
import java.util.List; import java.util.List;
@Data @Data
@Schema(description = "Task Create Request") @Schema(description = "任务创建请求")
public class TaskCreateRequest { public class TaskCreateRequest {
@NotBlank(message = "Task title is required") @NotBlank(message = "任务标题不能为空")
@Schema(description = "Task title") @Schema(description = "任务标题")
private String title; private String title;
@Schema(description = "Description") @Schema(description = "描述")
private String description; private String description;
@Schema(description = "Task type: reading, homework, activity") @Schema(description = "任务类型: 阅读、作业、活动")
private String type; private String type;
@Schema(description = "Course ID") @Schema(description = "课程ID")
private Long courseId; private Long courseId;
@Schema(description = "Start date") @Schema(description = "开始日期")
private LocalDate startDate; private LocalDate startDate;
@Schema(description = "Due date") @Schema(description = "截止日期")
private LocalDate dueDate; private LocalDate dueDate;
@Schema(description = "Attachments (JSON array)") @Schema(description = "附件JSON数组")
private String attachments; private String attachments;
@Schema(description = "Target type: class, student") @Schema(description = "目标类型: 班级、学生")
private String targetType; private String targetType;
@Schema(description = "Target IDs") @Schema(description = "目标ID列表")
private List<Long> targetIds; private List<Long> targetIds;
} }

View File

@ -6,28 +6,28 @@ import lombok.Data;
import java.time.LocalDate; import java.time.LocalDate;
@Data @Data
@Schema(description = "Task Update Request") @Schema(description = "任务更新请求")
public class TaskUpdateRequest { public class TaskUpdateRequest {
@Schema(description = "Task title") @Schema(description = "任务标题")
private String title; private String title;
@Schema(description = "Description") @Schema(description = "描述")
private String description; private String description;
@Schema(description = "Task type") @Schema(description = "任务类型")
private String type; private String type;
@Schema(description = "Start date") @Schema(description = "开始日期")
private LocalDate startDate; private LocalDate startDate;
@Schema(description = "Due date") @Schema(description = "截止日期")
private LocalDate dueDate; private LocalDate dueDate;
@Schema(description = "Status") @Schema(description = "状态")
private String status; private String status;
@Schema(description = "Attachments (JSON array)") @Schema(description = "附件JSON数组")
private String attachments; private String attachments;
} }

View File

@ -5,31 +5,31 @@ import jakarta.validation.constraints.NotBlank;
import lombok.Data; import lombok.Data;
@Data @Data
@Schema(description = "Teacher Create Request") @Schema(description = "教师创建请求")
public class TeacherCreateRequest { public class TeacherCreateRequest {
@NotBlank(message = "Username is required") @NotBlank(message = "用户名不能为空")
@Schema(description = "Username") @Schema(description = "用户名")
private String username; private String username;
@NotBlank(message = "Password is required") @NotBlank(message = "密码不能为空")
@Schema(description = "Password") @Schema(description = "密码")
private String password; private String password;
@NotBlank(message = "Name is required") @NotBlank(message = "姓名不能为空")
@Schema(description = "Name") @Schema(description = "姓名")
private String name; private String name;
@Schema(description = "Phone") @Schema(description = "电话")
private String phone; private String phone;
@Schema(description = "Email") @Schema(description = "邮箱")
private String email; private String email;
@Schema(description = "Gender") @Schema(description = "性别")
private String gender; private String gender;
@Schema(description = "Bio") @Schema(description = "个人简介")
private String bio; private String bio;
} }

View File

@ -4,28 +4,28 @@ import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data; import lombok.Data;
@Data @Data
@Schema(description = "Teacher Update Request") @Schema(description = "教师更新请求")
public class TeacherUpdateRequest { public class TeacherUpdateRequest {
@Schema(description = "Name") @Schema(description = "姓名")
private String name; private String name;
@Schema(description = "Phone") @Schema(description = "电话")
private String phone; private String phone;
@Schema(description = "Email") @Schema(description = "邮箱")
private String email; private String email;
@Schema(description = "Avatar URL") @Schema(description = "头像URL")
private String avatarUrl; private String avatarUrl;
@Schema(description = "Gender") @Schema(description = "性别")
private String gender; private String gender;
@Schema(description = "Bio") @Schema(description = "个人简介")
private String bio; private String bio;
@Schema(description = "Status") @Schema(description = "状态")
private String status; private String status;
} }

View File

@ -8,53 +8,53 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
@Data @Data
@Schema(description = "Tenant Create Request") @Schema(description = "租户创建请求")
public class TenantCreateRequest { public class TenantCreateRequest {
@NotBlank(message = "Tenant name is required") @NotBlank(message = "租户名称不能为空")
@Schema(description = "Tenant name") @Schema(description = "租户名称")
private String name; private String name;
@NotBlank(message = "Login account is required") @NotBlank(message = "登录账号不能为空")
@JsonAlias("loginAccount") @JsonAlias("loginAccount")
@Schema(description = "Tenant code / login account") @Schema(description = "租户编码 / 登录账号")
private String code; private String code;
@JsonAlias("contactPerson") @JsonAlias("contactPerson")
@Schema(description = "Contact person") @Schema(description = "联系人")
private String contactName; private String contactName;
@Schema(description = "Contact phone") @Schema(description = "联系电话")
private String contactPhone; private String contactPhone;
@Schema(description = "Contact email") @Schema(description = "联系邮箱")
private String contactEmail; private String contactEmail;
@Schema(description = "Address") @Schema(description = "地址")
private String address; private String address;
@Schema(description = "Logo URL") @Schema(description = "Logo URL")
private String logoUrl; private String logoUrl;
@JsonAlias("expireDate") @JsonAlias("expireDate")
@Schema(description = "Expiration date") @Schema(description = "过期日期")
private LocalDateTime expireAt; private LocalDateTime expireAt;
@JsonAlias("studentQuota") @JsonAlias("studentQuota")
@Schema(description = "Max students") @Schema(description = "最大学生数")
private Integer maxStudents; private Integer maxStudents;
@JsonAlias("teacherQuota") @JsonAlias("teacherQuota")
@Schema(description = "Max teachers") @Schema(description = "最大教师数")
private Integer maxTeachers; private Integer maxTeachers;
@Schema(description = "Initial password (default: 123456)") @Schema(description = "初始密码(默认: 123456")
private String password; private String password;
@Schema(description = "Package type (optional)") @Schema(description = "套餐类型(可选)")
private String packageType; private String packageType;
@Schema(description = "Start date (optional)") @Schema(description = "开始日期(可选)")
private String startDate; private String startDate;
} }

View File

@ -7,47 +7,47 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
@Data @Data
@Schema(description = "Tenant Update Request") @Schema(description = "租户更新请求")
public class TenantUpdateRequest { public class TenantUpdateRequest {
@Schema(description = "Tenant name") @Schema(description = "租户名称")
private String name; private String name;
@JsonAlias("contactPerson") @JsonAlias("contactPerson")
@Schema(description = "Contact person") @Schema(description = "联系人")
private String contactName; private String contactName;
@Schema(description = "Contact phone") @Schema(description = "联系电话")
private String contactPhone; private String contactPhone;
@Schema(description = "Contact email") @Schema(description = "联系邮箱")
private String contactEmail; private String contactEmail;
@Schema(description = "Address") @Schema(description = "地址")
private String address; private String address;
@Schema(description = "Logo URL") @Schema(description = "Logo URL")
private String logoUrl; private String logoUrl;
@Schema(description = "Status") @Schema(description = "状态")
private String status; private String status;
@JsonAlias("expireDate") @JsonAlias("expireDate")
@Schema(description = "Expiration date") @Schema(description = "过期日期")
private LocalDateTime expireAt; private LocalDateTime expireAt;
@JsonAlias("studentQuota") @JsonAlias("studentQuota")
@Schema(description = "Max students") @Schema(description = "最大学生数")
private Integer maxStudents; private Integer maxStudents;
@JsonAlias("teacherQuota") @JsonAlias("teacherQuota")
@Schema(description = "Max teachers") @Schema(description = "最大教师数")
private Integer maxTeachers; private Integer maxTeachers;
@Schema(description = "Package type (optional)") @Schema(description = "套餐类型(可选)")
private String packageType; private String packageType;
@Schema(description = "Start date (optional)") @Schema(description = "开始日期(可选)")
private String startDate; private String startDate;
} }

View File

@ -7,199 +7,199 @@ import java.math.BigDecimal;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Course Response DTO * 课程响应DTO
*/ */
@Data @Data
@Schema(description = "Course Response") @Schema(description = "课程响应")
public class CourseResponse { public class CourseResponse {
@Schema(description = "Course ID") @Schema(description = "课程ID")
private Long id; private Long id;
@Schema(description = "Tenant ID") @Schema(description = "租户ID")
private Long tenantId; private Long tenantId;
@Schema(description = "Course name") @Schema(description = "课程名称")
private String name; private String name;
@Schema(description = "Course code") @Schema(description = "课程编码")
private String code; private String code;
@Schema(description = "Description") @Schema(description = "描述")
private String description; private String description;
@Schema(description = "Cover URL") @Schema(description = "封面URL")
private String coverUrl; private String coverUrl;
@Schema(description = "Cover image path") @Schema(description = "封面图片路径")
private String coverImagePath; private String coverImagePath;
@Schema(description = "Category") @Schema(description = "分类")
private String category; private String category;
@Schema(description = "Age range") @Schema(description = "年龄段")
private String ageRange; private String ageRange;
@Schema(description = "Difficulty level") @Schema(description = "难度等级")
private String difficultyLevel; private String difficultyLevel;
@Schema(description = "Duration in minutes") @Schema(description = "时长(分钟)")
private Integer durationMinutes; private Integer durationMinutes;
@Schema(description = "Objectives") @Schema(description = "教学目标")
private String objectives; private String objectives;
@Schema(description = "Status") @Schema(description = "状态")
private String status; private String status;
@Schema(description = "Is system course") @Schema(description = "是否系统课程")
private Integer isSystem; private Integer isSystem;
// ============================================ // ============================================
// Course Package Fields // 课程包字段
// ============================================ // ============================================
@Schema(description = "Core content") @Schema(description = "核心内容")
private String coreContent; private String coreContent;
// Course introduction (8 fields) // 课程介绍8个字段
@Schema(description = "Course summary") @Schema(description = "课程摘要")
private String introSummary; private String introSummary;
@Schema(description = "Course highlights") @Schema(description = "课程亮点")
private String introHighlights; private String introHighlights;
@Schema(description = "Course goals") @Schema(description = "课程目标")
private String introGoals; private String introGoals;
@Schema(description = "Content schedule") @Schema(description = "内容安排")
private String introSchedule; private String introSchedule;
@Schema(description = "Key points and difficulties") @Schema(description = "重点难点")
private String introKeyPoints; private String introKeyPoints;
@Schema(description = "Teaching methods") @Schema(description = "教学方法")
private String introMethods; private String introMethods;
@Schema(description = "Evaluation methods") @Schema(description = "评估方法")
private String introEvaluation; private String introEvaluation;
@Schema(description = "Notes and precautions") @Schema(description = "注意事项")
private String introNotes; private String introNotes;
// Schedule reference data // 课表参考数据
@Schema(description = "Schedule reference data (JSON)") @Schema(description = "课表参考数据JSON")
private String scheduleRefData; private String scheduleRefData;
// Environment construction (Step 7) // 环境创设步骤7
@Schema(description = "Environment construction content") @Schema(description = "环境创设内容")
private String environmentConstruction; private String environmentConstruction;
// Theme and picture book // 主题与绘本
@Schema(description = "Theme ID") @Schema(description = "主题ID")
private Long themeId; private Long themeId;
@Schema(description = "Picture book name") @Schema(description = "绘本名称")
private String pictureBookName; private String pictureBookName;
// Digital resources // 数字资源
@Schema(description = "Ebook paths (JSON array)") @Schema(description = "电子书路径JSON数组")
private String ebookPaths; private String ebookPaths;
@Schema(description = "Audio paths (JSON array)") @Schema(description = "音频路径JSON数组")
private String audioPaths; private String audioPaths;
@Schema(description = "Video paths (JSON array)") @Schema(description = "视频路径JSON数组")
private String videoPaths; private String videoPaths;
@Schema(description = "Other resources (JSON array)") @Schema(description = "其他资源JSON数组")
private String otherResources; private String otherResources;
// Teaching materials // 教学材料
@Schema(description = "PPT file path") @Schema(description = "PPT文件路径")
private String pptPath; private String pptPath;
@Schema(description = "PPT file name") @Schema(description = "PPT文件名")
private String pptName; private String pptName;
@Schema(description = "Poster paths (JSON array)") @Schema(description = "海报路径JSON数组")
private String posterPaths; private String posterPaths;
@Schema(description = "Teaching tools (JSON array)") @Schema(description = "教具JSON数组")
private String tools; private String tools;
@Schema(description = "Student materials") @Schema(description = "学生材料")
private String studentMaterials; private String studentMaterials;
// Lesson plan, activities, assessment // 教案活动评估
@Schema(description = "Lesson plan data (JSON)") @Schema(description = "教案数据JSON")
private String lessonPlanData; private String lessonPlanData;
@Schema(description = "Activities data (JSON)") @Schema(description = "活动数据JSON")
private String activitiesData; private String activitiesData;
@Schema(description = "Assessment data (JSON)") @Schema(description = "评估数据JSON")
private String assessmentData; private String assessmentData;
// Tags // 标签
@Schema(description = "Grade tags (JSON array)") @Schema(description = "年级标签JSON数组")
private String gradeTags; private String gradeTags;
@Schema(description = "Domain tags (JSON array)") @Schema(description = "领域标签JSON数组")
private String domainTags; private String domainTags;
// Collective lesson // 集体课
@Schema(description = "Has collective lesson") @Schema(description = "是否有集体课")
private Integer hasCollectiveLesson; private Integer hasCollectiveLesson;
// Version and review // 版本与审核
@Schema(description = "Version") @Schema(description = "版本")
private String version; private String version;
@Schema(description = "Parent ID") @Schema(description = "ID")
private Long parentId; private Long parentId;
@Schema(description = "Is latest") @Schema(description = "是否最新")
private Integer isLatest; private Integer isLatest;
@Schema(description = "Submitted at") @Schema(description = "提交时间")
private LocalDateTime submittedAt; private LocalDateTime submittedAt;
@Schema(description = "Submitted by") @Schema(description = "提交人")
private Long submittedBy; private Long submittedBy;
@Schema(description = "Reviewed at") @Schema(description = "审核时间")
private LocalDateTime reviewedAt; private LocalDateTime reviewedAt;
@Schema(description = "Reviewed by") @Schema(description = "审核人")
private Long reviewedBy; private Long reviewedBy;
@Schema(description = "Review comment") @Schema(description = "审核意见")
private String reviewComment; private String reviewComment;
@Schema(description = "Review checklist") @Schema(description = "审核清单")
private String reviewChecklist; private String reviewChecklist;
@Schema(description = "Published at") @Schema(description = "发布时间")
private LocalDateTime publishedAt; private LocalDateTime publishedAt;
// Usage statistics // 使用统计
@Schema(description = "Usage count") @Schema(description = "使用次数")
private Integer usageCount; private Integer usageCount;
@Schema(description = "Teacher count") @Schema(description = "教师数")
private Integer teacherCount; private Integer teacherCount;
@Schema(description = "Average rating") @Schema(description = "平均评分")
private BigDecimal avgRating; private BigDecimal avgRating;
@Schema(description = "Created by") @Schema(description = "创建人")
private Long createdBy; private Long createdBy;
@Schema(description = "Created at") @Schema(description = "创建时间")
private LocalDateTime createdAt; private LocalDateTime createdAt;
@Schema(description = "Updated at") @Schema(description = "更新时间")
private LocalDateTime updatedAt; private LocalDateTime updatedAt;
} }

View File

@ -10,25 +10,25 @@ import lombok.NoArgsConstructor;
@Builder @Builder
@NoArgsConstructor @NoArgsConstructor
@AllArgsConstructor @AllArgsConstructor
@Schema(description = "Login Response") @Schema(description = "登录响应")
public class LoginResponse { public class LoginResponse {
@Schema(description = "JWT Token") @Schema(description = "JWT令牌")
private String token; private String token;
@Schema(description = "User ID") @Schema(description = "用户ID")
private Long userId; private Long userId;
@Schema(description = "Username") @Schema(description = "用户名")
private String username; private String username;
@Schema(description = "User name") @Schema(description = "用户姓名")
private String name; private String name;
@Schema(description = "User role") @Schema(description = "用户角色")
private String role; private String role;
@Schema(description = "Tenant ID") @Schema(description = "租户ID")
private Long tenantId; private Long tenantId;
} }

View File

@ -8,46 +8,46 @@ import java.time.LocalDateTime;
@Data @Data
@Builder @Builder
@Schema(description = "Tenant Response") @Schema(description = "租户响应")
public class TenantResponse { public class TenantResponse {
@Schema(description = "Tenant ID") @Schema(description = "租户ID")
private Long id; private Long id;
@Schema(description = "Tenant name") @Schema(description = "租户名称")
private String name; private String name;
@Schema(description = "Login account (tenant code)") @Schema(description = "登录账号(租户编码)")
private String loginAccount; private String loginAccount;
@Schema(description = "Contact person") @Schema(description = "联系人")
private String contactPerson; private String contactPerson;
@Schema(description = "Contact phone") @Schema(description = "联系电话")
private String contactPhone; private String contactPhone;
@Schema(description = "Contact email") @Schema(description = "联系邮箱")
private String contactEmail; private String contactEmail;
@Schema(description = "Address") @Schema(description = "地址")
private String address; private String address;
@Schema(description = "Logo URL") @Schema(description = "Logo URL")
private String logoUrl; private String logoUrl;
@Schema(description = "Status") @Schema(description = "状态")
private String status; private String status;
@Schema(description = "Expiration date") @Schema(description = "过期日期")
private LocalDateTime expireDate; private LocalDateTime expireDate;
@Schema(description = "Max students / student quota") @Schema(description = "最大学生数 / 学生配额")
private Integer studentQuota; private Integer studentQuota;
@Schema(description = "Max teachers / teacher quota") @Schema(description = "最大教师数 / 教师配额")
private Integer teacherQuota; private Integer teacherQuota;
@Schema(description = "Created at") @Schema(description = "创建时间")
private LocalDateTime createdAt; private LocalDateTime createdAt;
} }

View File

@ -10,31 +10,31 @@ import lombok.NoArgsConstructor;
@Builder @Builder
@NoArgsConstructor @NoArgsConstructor
@AllArgsConstructor @AllArgsConstructor
@Schema(description = "User Info Response") @Schema(description = "用户信息响应")
public class UserInfoResponse { public class UserInfoResponse {
@Schema(description = "User ID") @Schema(description = "用户ID")
private Long id; private Long id;
@Schema(description = "Username") @Schema(description = "用户名")
private String username; private String username;
@Schema(description = "User name") @Schema(description = "用户姓名")
private String name; private String name;
@Schema(description = "Email") @Schema(description = "邮箱")
private String email; private String email;
@Schema(description = "Phone") @Schema(description = "电话")
private String phone; private String phone;
@Schema(description = "Avatar URL") @Schema(description = "头像URL")
private String avatarUrl; private String avatarUrl;
@Schema(description = "User role") @Schema(description = "用户角色")
private String role; private String role;
@Schema(description = "Tenant ID") @Schema(description = "租户ID")
private Long tenantId; private Long tenantId;
} }

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Admin User Entity * 管理员用户实体
*/ */
@Data @Data
@TableName("admin_users") @TableName("admin_users")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Class Teacher Relation Entity * 班级-教师关联实体
*/ */
@Data @Data
@TableName("class_teachers") @TableName("class_teachers")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Class Entity * 班级实体
*/ */
@Data @Data
@TableName("classes") @TableName("classes")

View File

@ -7,8 +7,8 @@ import java.math.BigDecimal;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Course Entity * 课程实体
* Course package entity with comprehensive fields for course management * 课程包实体包含完整的课程管理字段
*/ */
@Data @Data
@TableName("courses") @TableName("courses")
@ -42,13 +42,13 @@ public class Course {
private Integer isSystem; private Integer isSystem;
// ============================================ // ============================================
// Course Package Refactoring Fields (2026-02-28) // 课程包重构字段 (2026-02-28)
// ============================================ // ============================================
// Core content // 核心内容
private String coreContent; private String coreContent;
// Course introduction (8 fields) // 课程介绍8个字段
private String introSummary; private String introSummary;
private String introHighlights; private String introHighlights;
private String introGoals; private String introGoals;
@ -58,45 +58,45 @@ public class Course {
private String introEvaluation; private String introEvaluation;
private String introNotes; private String introNotes;
// Schedule reference data (JSON) // 课表参考数据JSON
private String scheduleRefData; private String scheduleRefData;
// Environment construction (Step 7) // 环境创设步骤7
private String environmentConstruction; private String environmentConstruction;
// Theme and picture book relation // 主题与绘本关系
private Long themeId; private Long themeId;
private String pictureBookName; private String pictureBookName;
// Cover image // 封面图片
private String coverImagePath; private String coverImagePath;
// Digital resources (JSON arrays) // 数字资源JSON数组
private String ebookPaths; private String ebookPaths;
private String audioPaths; private String audioPaths;
private String videoPaths; private String videoPaths;
private String otherResources; private String otherResources;
// Teaching materials // 教学材料
private String pptPath; private String pptPath;
private String pptName; private String pptName;
private String posterPaths; private String posterPaths;
private String tools; private String tools;
private String studentMaterials; private String studentMaterials;
// Lesson plan, activities, assessment (JSON) // 教案活动评估JSON
private String lessonPlanData; private String lessonPlanData;
private String activitiesData; private String activitiesData;
private String assessmentData; private String assessmentData;
// Grade and domain tags (JSON arrays) // 年级与领域标签JSON数组
private String gradeTags; private String gradeTags;
private String domainTags; private String domainTags;
// Collective lesson flag // 集体课标志
private Integer hasCollectiveLesson; private Integer hasCollectiveLesson;
// Version and review fields // 版本与审核字段
private String version; private String version;
private Long parentId; private Long parentId;
private Integer isLatest; private Integer isLatest;
@ -108,7 +108,7 @@ public class Course {
private String reviewChecklist; private String reviewChecklist;
private LocalDateTime publishedAt; private LocalDateTime publishedAt;
// Usage statistics // 使用统计
private Integer usageCount; private Integer usageCount;
private Integer teacherCount; private Integer teacherCount;
private BigDecimal avgRating; private BigDecimal avgRating;

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Course Activity Entity * 课程活动实体
*/ */
@Data @Data
@TableName("course_activities") @TableName("course_activities")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Course Lesson Entity (chapters/sections within a course) * 课程课时实体课程内的章节/部分
*/ */
@Data @Data
@TableName("course_lessons") @TableName("course_lessons")

View File

@ -7,7 +7,7 @@ import java.math.BigDecimal;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Course Package Entity * 课程包实体
*/ */
@Data @Data
@TableName("course_packages") @TableName("course_packages")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Course Resource Entity * 课程资源实体
*/ */
@Data @Data
@TableName("course_resources") @TableName("course_resources")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Course Script Entity * 课程脚本实体
*/ */
@Data @Data
@TableName("course_scripts") @TableName("course_scripts")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Course Script Page Entity * 课程脚本页面实体
*/ */
@Data @Data
@TableName("course_script_pages") @TableName("course_script_pages")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Course Version Entity * 课程版本实体
*/ */
@Data @Data
@TableName("course_versions") @TableName("course_versions")

View File

@ -7,7 +7,7 @@ import java.time.LocalDate;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Growth Record Entity * 成长档案实体
*/ */
@Data @Data
@TableName("growth_records") @TableName("growth_records")

View File

@ -8,7 +8,7 @@ import java.time.LocalDateTime;
import java.time.LocalTime; import java.time.LocalTime;
/** /**
* Lesson Entity * 课时实体
*/ */
@Data @Data
@TableName("lessons") @TableName("lessons")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Lesson Feedback Entity * 课时反馈实体
*/ */
@Data @Data
@TableName("lesson_feedbacks") @TableName("lesson_feedbacks")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Notification Entity * 通知实体
*/ */
@Data @Data
@TableName("notifications") @TableName("notifications")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Operation Log Entity * 操作日志实体
*/ */
@Data @Data
@TableName("operation_logs") @TableName("operation_logs")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Parent Entity * 家长实体
*/ */
@Data @Data
@TableName("parents") @TableName("parents")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Parent Student Relation Entity * 家长-学生关联实体
*/ */
@Data @Data
@TableName("parent_students") @TableName("parent_students")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Resource Item Entity * 资源项实体
*/ */
@Data @Data
@TableName("resource_items") @TableName("resource_items")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Resource Library Entity * 资源库实体
*/ */
@Data @Data
@TableName("resource_libraries") @TableName("resource_libraries")

View File

@ -7,7 +7,7 @@ import java.time.LocalDate;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Schedule Plan Entity * 课表计划实体
*/ */
@Data @Data
@TableName("schedule_plans") @TableName("schedule_plans")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Schedule Template Entity * 课表模板实体
*/ */
@Data @Data
@TableName("schedule_templates") @TableName("schedule_templates")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* School Course Entity (tenant-customized courses) * 校本课程实体租户自定义课程
*/ */
@Data @Data
@TableName("school_courses") @TableName("school_courses")

View File

@ -7,7 +7,7 @@ import java.time.LocalDate;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Student Entity * 学生实体
*/ */
@Data @Data
@TableName("students") @TableName("students")

View File

@ -7,7 +7,7 @@ import java.time.LocalDate;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Student Class History Entity * 学生班级历史实体
*/ */
@Data @Data
@TableName("student_class_history") @TableName("student_class_history")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Student Record Entity * 学生记录实体
*/ */
@Data @Data
@TableName("student_records") @TableName("student_records")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* System Setting Entity * 系统设置实体
*/ */
@Data @Data
@TableName("system_settings") @TableName("system_settings")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Tag Entity * 标签实体
*/ */
@Data @Data
@TableName("tags") @TableName("tags")

View File

@ -7,7 +7,7 @@ import java.time.LocalDate;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Task Entity * 任务实体
*/ */
@Data @Data
@TableName("tasks") @TableName("tasks")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Task Completion Entity * 任务完成实体
*/ */
@Data @Data
@TableName("task_completions") @TableName("task_completions")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Task Target Entity * 任务目标实体
*/ */
@Data @Data
@TableName("task_targets") @TableName("task_targets")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Task Template Entity * 任务模板实体
*/ */
@Data @Data
@TableName("task_templates") @TableName("task_templates")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Teacher Entity * 教师实体
*/ */
@Data @Data
@TableName("teachers") @TableName("teachers")

View File

@ -9,7 +9,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Tenant Entity * 租户实体幼儿园/机构
*/ */
@Data @Data
@TableName("tenants") @TableName("tenants")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Tenant Course Entity * 租户-课程关联实体
*/ */
@Data @Data
@TableName("tenant_courses") @TableName("tenant_courses")

View File

@ -6,7 +6,7 @@ import lombok.Data;
import java.time.LocalDateTime; import java.time.LocalDateTime;
/** /**
* Theme Entity * 主题实体
*/ */
@Data @Data
@TableName("themes") @TableName("themes")