feat :AIOJ 后端模块并更新项目结构
- 引入了新模块:gateway、judge service、question service、user service 和 UPMS。 - 在 gateway 和 user service 模块中创建了 package-info.java 文件用于文档说明。 - 更新了 pom.xml 文件以反映新的模块结构和依赖关系。 - 在 UserController 中实现了基本的用户资料管理端点。 - 为每个新模块添加了扁平化 POM 文件以有效管理依赖。 - 增强了项目属性,以实现更好的版本管理和模块间一致性。
This commit is contained in:
@@ -14,6 +14,7 @@ import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import jakarta.validation.Valid;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
@RequiredArgsConstructor
|
||||
@RestController()
|
||||
@@ -79,13 +80,36 @@ public class UserController {
|
||||
/**
|
||||
* 解绑邮箱
|
||||
*
|
||||
* @param email 邮箱
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "解绑邮箱", description = "根据用户注册的邮箱解绑邮箱")
|
||||
@PostMapping("/email/unbind")
|
||||
public Result<Void> unbindEmail(@RequestBody String email) {
|
||||
public Result<Void> unbindEmail() {
|
||||
userService.unbindEmail(ContextHolderUtils.getCurrentUserId());
|
||||
return Results.success(null);
|
||||
}
|
||||
|
||||
|
||||
@Operation(summary = "个人资料管理", description = "获取完整个人资料")
|
||||
@GetMapping("/profile")
|
||||
public Result<Void> getUserProfile() {
|
||||
return Results.success();
|
||||
}
|
||||
|
||||
@Operation(summary = "个人资料管理", description = "更新个人资料")
|
||||
@PutMapping("/profile")
|
||||
public Result<Void> updateUserProfile() {
|
||||
return Results.success();
|
||||
}
|
||||
|
||||
@Operation(summary = "个人资料管理", description = "上传/更新头像")
|
||||
@PostMapping("/avatar")
|
||||
public Result<Void> uploadAvatar(@RequestParam("file") MultipartFile file) {
|
||||
return Results.success();
|
||||
}
|
||||
|
||||
@Operation(summary = "个人资料管理",description = "修改密码")
|
||||
public Result<Void> changePassword() {
|
||||
return Results.success();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
/**
|
||||
* AIOJ 用户服务模块
|
||||
* <p>
|
||||
* 提供用户相关的功能,包括:
|
||||
* <ul>
|
||||
* <li>用户注册与登录</li>
|
||||
* <li>用户信息管理</li>
|
||||
* <li>邮箱验证</li>
|
||||
* <li>用户权限</li>
|
||||
* </ul>
|
||||
* </p>
|
||||
*
|
||||
* @author meowrain
|
||||
* @since 1.0.0
|
||||
*/
|
||||
@NonNullApi
|
||||
@NonNullFields
|
||||
package cn.meowrain.aioj.backend.userservice;
|
||||
|
||||
import org.springframework.lang.NonNullApi;
|
||||
import org.springframework.lang.NonNullFields;
|
||||
Reference in New Issue
Block a user