mirror of
				https://github.com/continew-org/continew-admin.git
				synced 2025-10-31 10:57:13 +08:00 
			
		
		
		
	refactor: 修改头像接口调整为 Patch 请求方式
This commit is contained in:
		| @@ -72,7 +72,7 @@ public class UserProfileController { | |||||||
|     private final AuthRequestFactory authRequestFactory; |     private final AuthRequestFactory authRequestFactory; | ||||||
|  |  | ||||||
|     @Operation(summary = "修改头像", description = "用户修改个人头像") |     @Operation(summary = "修改头像", description = "用户修改个人头像") | ||||||
|     @PostMapping("/avatar") |     @PatchMapping("/avatar") | ||||||
|     public AvatarResp updateAvatar(@NotNull(message = "头像不能为空") MultipartFile avatarFile) throws IOException { |     public AvatarResp updateAvatar(@NotNull(message = "头像不能为空") MultipartFile avatarFile) throws IOException { | ||||||
|         ValidationUtils.throwIf(avatarFile::isEmpty, "头像不能为空"); |         ValidationUtils.throwIf(avatarFile::isEmpty, "头像不能为空"); | ||||||
|         String newAvatar = userService.updateAvatar(avatarFile, UserContextHolder.getUserId()); |         String newAvatar = userService.updateAvatar(avatarFile, UserContextHolder.getUserId()); | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 jasmine
					jasmine