用户服务 4 个 crate 合并为单一 user-service,按 DDD 限界上下文聚合

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
fish
2026-04-26 16:36:04 +08:00
parent 4e004f5a85
commit b5cb9daad7
28 changed files with 489 additions and 1038 deletions

View File

@@ -0,0 +1,18 @@
// 注册/业务类接口的统一请求/响应包装格式
// 与 backend/CLAUDE.md 中的 API 公共约定保持一致
use serde::{Deserialize, Serialize};
#[derive(Deserialize)]
pub struct ApiRequest<T> {
pub device: i32,
pub language: i32,
pub data: T,
}
#[derive(Serialize)]
pub struct ApiResponse<T> {
pub success: bool,
pub message: String,
pub data: Option<T>,
}