Skip to content

Commit

Permalink
feat: 파일과 이미지 URL이 따로 넘어오도록 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
Mingyum-Kim committed Oct 14, 2024
1 parent 26331a4 commit 6765ded
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import org.springframework.web.multipart.MultipartFile;

import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import mouda.backend.common.config.argumentresolver.LoginDarakbangMember;
import mouda.backend.common.config.argumentresolver.LoginMember;
import mouda.backend.common.response.RestResponse;
Expand All @@ -22,6 +23,7 @@
import mouda.backend.member.domain.Member;
import mouda.backend.member.presentation.response.DarakbangMemberInfoResponse;

@Slf4j
@RestController
@RequestMapping("/v1/darakbang")
@RequiredArgsConstructor
Expand Down Expand Up @@ -68,11 +70,15 @@ public ResponseEntity<RestResponse<DarakbangMemberInfoResponse>> findMyInfo(
})
public ResponseEntity<Void> updateMyInfo(
@LoginDarakbangMember DarakbangMember darakbangMember,
@RequestPart(value = "profile_img", required = false) MultipartFile profile_img,
@RequestPart(value = "file", required = false) MultipartFile file,
@RequestPart(value = "profile", required = false) String profile,
@RequestPart("nickname") String nickname,
@RequestPart(value = "description", required = false) String description
) {
darakbangMemberService.updateMyInfo(darakbangMember, profile_img, nickname, description);

log.info("file : {}, profile : {}, nickname : {}, description : {}", file.toString(), profile, nickname,
description);
darakbangMemberService.updateMyInfo(darakbangMember, file, nickname, description);

return ResponseEntity.ok().build();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ ResponseEntity<RestResponse<DarakbangMemberInfoResponse>> findMyInfo(
ResponseEntity<Void> updateMyInfo(
@LoginDarakbangMember DarakbangMember member,
@RequestPart MultipartFile file,
@RequestPart String profile,
@RequestPart String nickname,
@RequestPart String description
);
Expand Down

0 comments on commit 6765ded

Please sign in to comment.