From 1ca0d2ccae04ca6fc720f9299d6838b0b724b235 Mon Sep 17 00:00:00 2001 From: Hong0329 Date: Sat, 24 Aug 2024 02:12:09 +0900 Subject: [PATCH] feat withdrawal reason --- .../member/dto/request/MemberWithdrawalPatchRequestDto.java | 4 +++- .../WableServer/api/member/service/MemberCommandService.java | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/WableServer/src/main/java/com/wable/www/WableServer/api/member/dto/request/MemberWithdrawalPatchRequestDto.java b/WableServer/src/main/java/com/wable/www/WableServer/api/member/dto/request/MemberWithdrawalPatchRequestDto.java index c0d1a07..eab8595 100644 --- a/WableServer/src/main/java/com/wable/www/WableServer/api/member/dto/request/MemberWithdrawalPatchRequestDto.java +++ b/WableServer/src/main/java/com/wable/www/WableServer/api/member/dto/request/MemberWithdrawalPatchRequestDto.java @@ -1,6 +1,8 @@ package com.wable.www.WableServer.api.member.dto.request; +import java.util.List; + public record MemberWithdrawalPatchRequestDto( - String deleted_reason + List deleted_reason ) { } diff --git a/WableServer/src/main/java/com/wable/www/WableServer/api/member/service/MemberCommandService.java b/WableServer/src/main/java/com/wable/www/WableServer/api/member/service/MemberCommandService.java index f21269e..42fdefd 100644 --- a/WableServer/src/main/java/com/wable/www/WableServer/api/member/service/MemberCommandService.java +++ b/WableServer/src/main/java/com/wable/www/WableServer/api/member/service/MemberCommandService.java @@ -53,7 +53,8 @@ public void withdrawalMember(Long memberId, MemberWithdrawalPatchRequestDto memb member.updateNickname("탈퇴한 회원"); member.updateProfileUrl(SYSTEM_IMAGE_S3); - member.updateDeletedReason(memberWithdrawalPatchRequestDto.deleted_reason()); + String combineReason = String.join(",", memberWithdrawalPatchRequestDto.deleted_reason()); + member.updateDeletedReason(combineReason); // notificationRepository.deleteBynotificationTargetMember(member);