From 8dc837332fed3b2996af311e46d2a841cadeddf1 Mon Sep 17 00:00:00 2001 From: yang Date: Tue, 14 May 2024 14:42:46 +0900 Subject: [PATCH 1/4] =?UTF-8?q?RAC-367=20refactor=20:=20=EB=B6=88=ED=95=84?= =?UTF-8?q?=EC=9A=94=ED=95=9C=20=EC=9D=98=EC=A1=B4=EC=84=B1=20=EC=A0=9C?= =?UTF-8?q?=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build.gradle | 1 - 1 file changed, 1 deletion(-) diff --git a/build.gradle b/build.gradle index a37e0eda..309e884a 100644 --- a/build.gradle +++ b/build.gradle @@ -27,7 +27,6 @@ repositories { dependencies { implementation 'org.springframework.boot:spring-boot-starter-thymeleaf' - implementation 'org.springframework.boot:spring-boot-starter-amqp' implementation 'org.springframework.boot:spring-boot-starter-data-jpa' implementation 'org.springframework.boot:spring-boot-starter-data-redis' implementation 'org.springframework.boot:spring-boot-starter-security' From d3c18fe6e8cf48533c890a2ea671a4031194cf28 Mon Sep 17 00:00:00 2001 From: yang Date: Tue, 14 May 2024 17:18:11 +0900 Subject: [PATCH 2/4] =?UTF-8?q?RAC-367=20feat=20:=20=EB=A7=A4=EC=B9=AD=20?= =?UTF-8?q?=EA=B4=80=EB=A0=A8=20=EC=95=8C=EB=A6=BC=ED=86=A1=20=EC=83=9D?= =?UTF-8?q?=EC=84=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dto/req/JuniorMatchingFailRequest.java | 6 ++ .../dto/req/JuniorMatchingSuccessRequest.java | 6 ++ .../dto/req/JuniorMatchingWaitingRequest.java | 7 ++ .../content/JuniorMatchingFailMessage.java | 11 +++ .../content/JuniorMatchingSuccessMessage.java | 11 +++ .../content/JuniorMatchingWaitingMessage.java | 8 ++ .../mapper/BizppurioMapper.java | 94 +++++++++++++++---- .../usecase/BizppurioJuniorMessage.java | 19 +++- .../usecase/BizppurioSend.java | 6 +- 9 files changed, 146 insertions(+), 22 deletions(-) create mode 100644 src/main/java/com/postgraduate/global/bizppurio/application/dto/req/JuniorMatchingFailRequest.java create mode 100644 src/main/java/com/postgraduate/global/bizppurio/application/dto/req/JuniorMatchingSuccessRequest.java create mode 100644 src/main/java/com/postgraduate/global/bizppurio/application/dto/req/JuniorMatchingWaitingRequest.java create mode 100644 src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorMatchingFailMessage.java create mode 100644 src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorMatchingSuccessMessage.java create mode 100644 src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorMatchingWaitingMessage.java rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/mapper/BizppurioMapper.java (69%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/usecase/BizppurioJuniorMessage.java (54%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/usecase/BizppurioSend.java (89%) diff --git a/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/JuniorMatchingFailRequest.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/JuniorMatchingFailRequest.java new file mode 100644 index 00000000..eb9c38be --- /dev/null +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/JuniorMatchingFailRequest.java @@ -0,0 +1,6 @@ +package com.postgraduate.global.bizppurio.application.dto.req; + +public record JuniorMatchingFailRequest( + String phoneNumber, String name, String originPostgraduate, String originMajor, String alterPostgraduate, String alterMajor +) { +} diff --git a/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/JuniorMatchingSuccessRequest.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/JuniorMatchingSuccessRequest.java new file mode 100644 index 00000000..8721fe1d --- /dev/null +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/JuniorMatchingSuccessRequest.java @@ -0,0 +1,6 @@ +package com.postgraduate.global.bizppurio.application.dto.req; + +public record JuniorMatchingSuccessRequest( + String phoneNumber, String name, String postgraduate, String major +) { +} diff --git a/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/JuniorMatchingWaitingRequest.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/JuniorMatchingWaitingRequest.java new file mode 100644 index 00000000..08e4d93a --- /dev/null +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/JuniorMatchingWaitingRequest.java @@ -0,0 +1,7 @@ +package com.postgraduate.global.bizppurio.application.dto.req; + +public record JuniorMatchingWaitingRequest( + String name, + String phoneNumber +) { +} diff --git a/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorMatchingFailMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorMatchingFailMessage.java new file mode 100644 index 00000000..15a79d2f --- /dev/null +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorMatchingFailMessage.java @@ -0,0 +1,11 @@ +package com.postgraduate.global.bizppurio.application.dto.req.content; + +import com.postgraduate.global.bizppurio.application.dto.req.content.button.WebLinkButton; + +public record JuniorMatchingFailMessage ( + String message, + String senderkey, + String templatecode, + WebLinkButton[] button +) implements Message +{} diff --git a/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorMatchingSuccessMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorMatchingSuccessMessage.java new file mode 100644 index 00000000..a4557bdd --- /dev/null +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorMatchingSuccessMessage.java @@ -0,0 +1,11 @@ +package com.postgraduate.global.bizppurio.application.dto.req.content; + +import com.postgraduate.global.bizppurio.application.dto.req.content.button.WebLinkButton; + +public record JuniorMatchingSuccessMessage( + String message, + String senderkey, + String templatecode, + WebLinkButton[] button +) implements Message { +} diff --git a/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorMatchingWaitingMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorMatchingWaitingMessage.java new file mode 100644 index 00000000..63d1451d --- /dev/null +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorMatchingWaitingMessage.java @@ -0,0 +1,8 @@ +package com.postgraduate.global.bizppurio.application.dto.req.content; + +public record JuniorMatchingWaitingMessage( + String message, + String senderkey, + String templatecode +) implements Message { +} diff --git a/src/main/java/com/postgraduate/global/bizppurio/mapper/BizppurioMapper.java b/src/main/java/com/postgraduate/global/bizppurio/application/mapper/BizppurioMapper.java similarity index 69% rename from src/main/java/com/postgraduate/global/bizppurio/mapper/BizppurioMapper.java rename to src/main/java/com/postgraduate/global/bizppurio/application/mapper/BizppurioMapper.java index e55e2897..f8182d9b 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/mapper/BizppurioMapper.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/mapper/BizppurioMapper.java @@ -1,10 +1,13 @@ -package com.postgraduate.global.bizppurio.mapper; +package com.postgraduate.global.bizppurio.application.mapper; +import com.postgraduate.global.bizppurio.application.dto.req.JuniorMatchingFailRequest; +import com.postgraduate.global.bizppurio.application.dto.req.JuniorMatchingSuccessRequest; +import com.postgraduate.global.bizppurio.application.dto.req.JuniorMatchingWaitingRequest; import com.postgraduate.domain.user.domain.entity.User; -import com.postgraduate.global.bizppurio.dto.req.CommonRequest; -import com.postgraduate.global.bizppurio.dto.req.ContentRequest; -import com.postgraduate.global.bizppurio.dto.req.content.*; -import com.postgraduate.global.bizppurio.dto.req.content.button.WebLinkButton; +import com.postgraduate.global.bizppurio.application.dto.req.CommonRequest; +import com.postgraduate.global.bizppurio.application.dto.req.ContentRequest; +import com.postgraduate.global.bizppurio.application.dto.req.content.*; +import com.postgraduate.global.bizppurio.application.dto.req.content.button.WebLinkButton; import org.springframework.beans.factory.annotation.Value; import org.springframework.stereotype.Component; @@ -38,6 +41,12 @@ public class BizppurioMapper { private String juniorMentoringApply; @Value("${bizppurio.template.senior_signUp}") private String seniorSignUp; + @Value("${bizppurio.template.junior_matching_fail}") + private String juniorMatchingFail; + @Value("${bizppurio.template.junior_matching_success}") + private String juniorMatchingSucess; + @Value("${bizppurio.template.junior_matching_waiting}") + private String juniorMatchingWaiting; @Value("${bizppurio.url.certification}") private String certificationPage; @Value("${bizppurio.url.profile}") @@ -66,7 +75,7 @@ public CommonRequest mapToSeniorSignUpMessage(User user) { WebLinkButton profile = new WebLinkButton("프로필 작성하기", "WL", profilePage, profilePage); WebLinkButton[] buttons = {certification, profile}; Message messageBody = new SeniorSingUpMessage(message, senderKey, seniorSignUp, buttons); - return createCommonRequest(messageBody, user); + return createCommonRequest(messageBody, user.getPhoneNumber()); } public CommonRequest mapToSeniorApplyMessage(User user) { @@ -79,7 +88,7 @@ public CommonRequest mapToSeniorApplyMessage(User user) { WebLinkButton mentoringCheck = new WebLinkButton("멘토링 신청 확인하기", type, seniorMentoringPage, seniorMentoringPage); WebLinkButton[] buttons = {mentoringCheck}; Message messageBody = new SeniorApplyMessage(message, senderKey, seniorMentoringApply, buttons); - return createCommonRequest(messageBody, user); + return createCommonRequest(messageBody, user.getPhoneNumber()); } public CommonRequest mapToSeniorAcceptMessage(User user, String link, String time) { @@ -92,7 +101,7 @@ public CommonRequest mapToSeniorAcceptMessage(User user, String link, String tim "멘토링 진행 일시에 선배님께서 줌 또는 구글미트를 활용하여 비대면 대화 링크를 열어주시면 됩니다!" ); Message messageBody = new SeniorAcceptMessage(message, senderKey, seniorMentoringAccept); - return createCommonRequest(messageBody, user); + return createCommonRequest(messageBody, user.getPhoneNumber()); } public CommonRequest mapToCertificationApprove(User user) { @@ -104,7 +113,7 @@ public CommonRequest mapToCertificationApprove(User user) { WebLinkButton profile = new WebLinkButton("프로필 완성하기", type, profilePage, profilePage); WebLinkButton[] buttons = {profile}; CertificationApproveMessage messageBody = new CertificationApproveMessage(message, senderKey, certificationApprove, buttons); - return createCommonRequest(messageBody, user); + return createCommonRequest(messageBody, user.getPhoneNumber()); } public CommonRequest mapToCertificationDenied(User user) { @@ -118,7 +127,7 @@ public CommonRequest mapToCertificationDenied(User user) { WebLinkButton certification = new WebLinkButton("대학원 재인증하기", type, certificationPage, certificationPage); WebLinkButton[] buttons = {certification}; CertificationDeniedMessage messageBody = new CertificationDeniedMessage(message, senderKey, certificationDenied, buttons); - return createCommonRequest(messageBody, user); + return createCommonRequest(messageBody, user.getPhoneNumber()); } public CommonRequest mapToSeniorFinish(User user) { @@ -132,7 +141,7 @@ public CommonRequest mapToSeniorFinish(User user) { "멘토링 확정은 멘토링이 정상적으로 진행되었는지 확인하기 위함이며, 멘토링 완료 확정이 진행되지 않을시 정산이 지연될 수 있는점 양해 부탁드려요!\uD83D\uDE03" ); SeniorFinishMessage messageBody = new SeniorFinishMessage(message, senderKey, seniorMentoringFinish); - return createCommonRequest(messageBody, user); + return createCommonRequest(messageBody, user.getPhoneNumber()); } public CommonRequest mapToJuniorApplyMessage(User user) { @@ -144,7 +153,7 @@ public CommonRequest mapToJuniorApplyMessage(User user) { "선배님이 다음날 오후 11시 59분까지 멘토링을 수락해주시지 않으면 멘토링이 자동 취소 및 환불되니 유의해주세요! \uD83D\uDE42" ); JuniorApplyMessage messageBody = new JuniorApplyMessage(message, senderKey, juniorMentoringApply); - return createCommonRequest(messageBody, user); + return createCommonRequest(messageBody, user.getPhoneNumber()); } public CommonRequest mapToJuniorAcceptMessage(User user, String link, String time) { @@ -159,7 +168,7 @@ public CommonRequest mapToJuniorAcceptMessage(User user, String link, String tim "멘토링 시간은 꼭 지켜주세요! \uD83D\uDD05" ); JuniorAcceptMessage messageBody = new JuniorAcceptMessage(message, senderKey, juniorMentoringAccept); - return createCommonRequest(messageBody, user); + return createCommonRequest(messageBody, user.getPhoneNumber()); } public CommonRequest mapToJuniorRefuseMessage(User user) { @@ -173,7 +182,7 @@ public CommonRequest mapToJuniorRefuseMessage(User user) { WebLinkButton otherSenior = new WebLinkButton("다른 선배 보러가기", type, mainPage, mainPage); WebLinkButton[] buttons = {otherSenior}; JuniorRefuseMessage messageBody = new JuniorRefuseMessage(message, senderKey, juniorMentoringRefuse, buttons); - return createCommonRequest(messageBody, user); + return createCommonRequest(messageBody, user.getPhoneNumber()); } public CommonRequest mapToJuniorFinish(User user) { @@ -191,12 +200,63 @@ public CommonRequest mapToJuniorFinish(User user) { WebLinkButton[] buttons = {mentoringFinish}; JuniorFinishMessage messageBody = new JuniorFinishMessage(message, senderKey, juniorMentoringFinish, buttons); - return createCommonRequest(messageBody, user); + return createCommonRequest(messageBody, user.getPhoneNumber()); } - private CommonRequest createCommonRequest(Message messageBody, User user) { + public CommonRequest mapToJuniorMatchingFail(JuniorMatchingFailRequest request) { + String message = ( + "안녕하세요, " + request.name() + "님.\n" + + "\n" + + "오래 기다려주셔서 감사드립니다!\n" + + "\n" + + request.name() + "님께서 신청해주신, " + request.originPostgraduate() + "대학원 " + request.originMajor() + "학과 선배 대신\n" + + "\n" + + request.alterPostgraduate() + "대학원 " + request.alterMajor() + "학과의 선배를 매칭 드리고 싶어요!\n" + + "\n" + + "신청해주신 선배는 찾지 못했지만, 유사학과의 다른 선배와 멘토링을 해보는 건 어때요 ?" + ); + WebLinkButton goMainPage = new WebLinkButton("대학원 김선배 바로가기", type, mainPage, mainPage); + WebLinkButton[] buttons = {goMainPage}; + + JuniorMatchingFailMessage messageBody = new JuniorMatchingFailMessage(message, senderKey, juniorMatchingFail, buttons); + return createCommonRequest(messageBody, request.phoneNumber()); + } + + public CommonRequest mapToJuniorMatchingSuccess(JuniorMatchingSuccessRequest request) { + String message = ( + "안녕하세요, " + request.name() + "님.\n" + + "\n" + + "오래 기다려주셔서 감사드립니다!\n" + + "\n" + + request.name() + "님께서 신청해주신, " + request.postgraduate() + "대학원 " + request.major() + "학과 선배와 매칭되었어요 \uD83D\uDE42\n" + + "\n" + + "아래 링크를 눌러 멘토링을 진행해보세요 !" + ); + WebLinkButton goMainPage = new WebLinkButton("대학원 김선배 바로가기", type, mainPage, mainPage); + WebLinkButton[] buttons = {goMainPage}; + + JuniorMatchingSuccessMessage messageBody = new JuniorMatchingSuccessMessage(message, senderKey, juniorMatchingSucess, buttons); + return createCommonRequest(messageBody, request.phoneNumber()); + } + + public CommonRequest mapToJuniorMatchingWaiting(JuniorMatchingWaitingRequest request) { + String message = ( + "안녕하세요, " + request.name() + "님.\n" + + "\n" + + "김선배와 함께 해주셔서 감사드립니다.\n" + + "\n" + + request.name() + "님이 신청한 선배를 저희 김선배에서 찾고 있어요 !\n" + + "\n" + + "신청해주신 선배를 찾는데에는 3~7일 정도 소요되어요 \uD83D\uDE0A" + ); + + JuniorMatchingWaitingMessage messageBody = new JuniorMatchingWaitingMessage(message, senderKey, juniorMatchingWaiting); + return createCommonRequest(messageBody, request.phoneNumber()); + } + + private CommonRequest createCommonRequest(Message messageBody, String phoneNumber) { String refKey = UUID.randomUUID().toString().replace("-", ""); ContentRequest contentRequest = new ContentRequest(messageBody); - return new CommonRequest(id, "at", number , user.getPhoneNumber(), contentRequest, refKey); + return new CommonRequest(id, "at", number , phoneNumber, contentRequest, refKey); } } diff --git a/src/main/java/com/postgraduate/global/bizppurio/usecase/BizppurioJuniorMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/usecase/BizppurioJuniorMessage.java similarity index 54% rename from src/main/java/com/postgraduate/global/bizppurio/usecase/BizppurioJuniorMessage.java rename to src/main/java/com/postgraduate/global/bizppurio/application/usecase/BizppurioJuniorMessage.java index 24bb5287..658e40f2 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/usecase/BizppurioJuniorMessage.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/usecase/BizppurioJuniorMessage.java @@ -1,8 +1,11 @@ -package com.postgraduate.global.bizppurio.usecase; +package com.postgraduate.global.bizppurio.application.usecase; import com.postgraduate.domain.senior.domain.entity.Senior; import com.postgraduate.domain.user.domain.entity.User; -import com.postgraduate.global.bizppurio.mapper.BizppurioMapper; +import com.postgraduate.global.bizppurio.application.dto.req.JuniorMatchingFailRequest; +import com.postgraduate.global.bizppurio.application.dto.req.JuniorMatchingSuccessRequest; +import com.postgraduate.global.bizppurio.application.dto.req.JuniorMatchingWaitingRequest; +import com.postgraduate.global.bizppurio.application.mapper.BizppurioMapper; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springframework.stereotype.Component; @@ -32,4 +35,16 @@ public void mentoringRefuse(User user) { public void mentoringFinish(User user) { bizppurioSend.sendMessageWithExceptionHandling(() -> mapper.mapToJuniorFinish(user)); } + + public void matchingWaiting(JuniorMatchingWaitingRequest request) { + bizppurioSend.sendMessageWithExceptionHandling(() -> mapper.mapToJuniorMatchingWaiting(request)); + } + + public void matchingFail(JuniorMatchingFailRequest request) { + bizppurioSend.sendMessageWithExceptionHandling(() -> mapper.mapToJuniorMatchingFail(request)); + } + + public void matchingSuccess(JuniorMatchingSuccessRequest request) { + bizppurioSend.sendMessageWithExceptionHandling(() -> mapper.mapToJuniorMatchingSuccess(request)); + } } diff --git a/src/main/java/com/postgraduate/global/bizppurio/usecase/BizppurioSend.java b/src/main/java/com/postgraduate/global/bizppurio/application/usecase/BizppurioSend.java similarity index 89% rename from src/main/java/com/postgraduate/global/bizppurio/usecase/BizppurioSend.java rename to src/main/java/com/postgraduate/global/bizppurio/application/usecase/BizppurioSend.java index 3c981791..e2f0fab0 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/usecase/BizppurioSend.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/usecase/BizppurioSend.java @@ -1,8 +1,8 @@ -package com.postgraduate.global.bizppurio.usecase; +package com.postgraduate.global.bizppurio.application.usecase; import com.fasterxml.jackson.databind.ObjectMapper; -import com.postgraduate.global.bizppurio.dto.req.CommonRequest; -import com.postgraduate.global.bizppurio.dto.res.MessageResponse; +import com.postgraduate.global.bizppurio.application.dto.req.CommonRequest; +import com.postgraduate.global.bizppurio.application.dto.res.MessageResponse; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Value; From 145d953f54e00ed1415810d977c8c2d58a3d046f Mon Sep 17 00:00:00 2001 From: yang Date: Tue, 14 May 2024 17:18:44 +0900 Subject: [PATCH 3/4] =?UTF-8?q?RAC-367=20feat=20:=20=EC=95=8C=EB=A6=BC?= =?UTF-8?q?=ED=86=A1=20=EC=88=98=EB=8F=99=20=EC=A0=84=EC=86=A1=20API?= =?UTF-8?q?=EC=83=9D=EC=84=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../presantation/BizppurioController.java | 39 +++++++++++++++++++ .../config/security/SecurityConfig.java | 3 +- 2 files changed, 41 insertions(+), 1 deletion(-) create mode 100644 src/main/java/com/postgraduate/global/bizppurio/presantation/BizppurioController.java diff --git a/src/main/java/com/postgraduate/global/bizppurio/presantation/BizppurioController.java b/src/main/java/com/postgraduate/global/bizppurio/presantation/BizppurioController.java new file mode 100644 index 00000000..493bd2be --- /dev/null +++ b/src/main/java/com/postgraduate/global/bizppurio/presantation/BizppurioController.java @@ -0,0 +1,39 @@ +package com.postgraduate.global.bizppurio.presantation; + +import com.postgraduate.global.bizppurio.application.dto.req.JuniorMatchingFailRequest; +import com.postgraduate.global.bizppurio.application.dto.req.JuniorMatchingSuccessRequest; +import com.postgraduate.global.bizppurio.application.dto.req.JuniorMatchingWaitingRequest; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioJuniorMessage; +import com.postgraduate.global.dto.ResponseDto; +import io.swagger.v3.oas.annotations.tags.Tag; +import lombok.RequiredArgsConstructor; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; + +@RestController +@RequiredArgsConstructor +@RequestMapping("/bizppurio") +@Tag(name = "BIZPPURIO Controller", description = "알림톡 수동 전송용 API (관리자 권한 필요)") +public class BizppurioController { + private final BizppurioJuniorMessage bizppurioJuniorMessage; + + @PostMapping("/matching/waiting") + public ResponseDto matchingWaiting(@RequestBody JuniorMatchingWaitingRequest request) { + bizppurioJuniorMessage.matchingWaiting(request); + return ResponseDto.create("200", request.phoneNumber() + " 번호로 " + request.name() + " 님께 알림톡 전송 완료"); + } + + @PostMapping("/matching/fail") + public ResponseDto matchingFail(@RequestBody JuniorMatchingFailRequest request) { + bizppurioJuniorMessage.matchingFail(request); + return ResponseDto.create("200", request.phoneNumber() + " 번호로 " + request.name() + " 님께 알림톡 전송 완료"); + } + + @PostMapping("/matching/success") + public ResponseDto matchingSuccess(@RequestBody JuniorMatchingSuccessRequest request) { + bizppurioJuniorMessage.matchingSuccess(request); + return ResponseDto.create("200", request.phoneNumber() + " 번호로 " + request.name() + " 님께 알림톡 전송 완료"); + } +} diff --git a/src/main/java/com/postgraduate/global/config/security/SecurityConfig.java b/src/main/java/com/postgraduate/global/config/security/SecurityConfig.java index 54e52475..b0ea38a9 100644 --- a/src/main/java/com/postgraduate/global/config/security/SecurityConfig.java +++ b/src/main/java/com/postgraduate/global/config/security/SecurityConfig.java @@ -58,7 +58,8 @@ protected SecurityFilterChain config(HttpSecurity http) throws Exception { .requestMatchers("/admin/**").hasAuthority(Role.ADMIN.name()) .requestMatchers("/adminServer/loginForm").permitAll() .requestMatchers("/adminServer/login").permitAll() - .requestMatchers("adminServer/**").hasAuthority(Role.ADMIN.name()) + .requestMatchers("/adminServer/**").hasAuthority(Role.ADMIN.name()) + .requestMatchers("/bizppurio/**").hasAuthority(Role.ADMIN.name()) .requestMatchers(HttpMethod.PATCH, "/senior/**").hasAuthority(Role.SENIOR.name()) .requestMatchers(HttpMethod.POST, "/senior/**").hasAuthority(Role.SENIOR.name()) .requestMatchers("/senior/me/**").hasAuthority(Role.SENIOR.name()) From c5ce3c5f81442de146526152309f9dc764f750b7 Mon Sep 17 00:00:00 2001 From: yang Date: Tue, 14 May 2024 17:19:30 +0900 Subject: [PATCH 4/4] =?UTF-8?q?RAC-367=20refactor=20:=20=ED=8C=A8=ED=82=A4?= =?UTF-8?q?=EC=A7=80=20=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/postgraduate/batch/cancel/CancelMentoringWriter.java | 2 +- .../adminssr/application/usecase/AdminSeniorUseCase.java | 2 +- .../domain/auth/application/usecase/oauth/SignUpUseCase.java | 2 +- .../application/usecase/MentoringApplyingUseCase.java | 4 ++-- .../application/usecase/MentoringManageUseCase.java | 4 ++-- .../bizppurio/{ => application}/dto/req/CommonRequest.java | 2 +- .../global/bizppurio/application/dto/req/ContentRequest.java | 5 +++++ .../dto/req/content/CertificationApproveMessage.java | 4 ++-- .../dto/req/content/CertificationDeniedMessage.java | 4 ++-- .../dto/req/content/JuniorAcceptMessage.java | 2 +- .../dto/req/content/JuniorApplyMessage.java | 2 +- .../dto/req/content/JuniorFinishMessage.java | 4 ++-- .../dto/req/content/JuniorRefuseMessage.java | 4 ++-- .../bizppurio/application/dto/req/content/Message.java | 4 ++++ .../dto/req/content/SeniorAcceptMessage.java | 2 +- .../dto/req/content/SeniorApplyMessage.java | 4 ++-- .../dto/req/content/SeniorFinishMessage.java | 2 +- .../dto/req/content/SeniorSingUpMessage.java | 4 ++-- .../dto/req/content/button/WebLinkButton.java | 2 +- .../{ => application}/dto/res/BizppurioTokenResponse.java | 2 +- .../bizppurio/{ => application}/dto/res/MessageResponse.java | 2 +- .../bizppurio/{ => application}/usecase/BizppurioAuth.java | 4 ++-- .../{ => application}/usecase/BizppurioSeniorMessage.java | 4 ++-- .../global/bizppurio/dto/req/ContentRequest.java | 5 ----- .../global/bizppurio/dto/req/content/Message.java | 4 ---- .../auth/application/usecase/oauth/SignUpUseTypeTest.java | 2 +- .../application/usecase/MentoringApplyingUseTypeTest.java | 4 ++-- .../application/usecase/MentoringManageUseTypeTest.java | 4 ++-- 28 files changed, 45 insertions(+), 45 deletions(-) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/req/CommonRequest.java (73%) create mode 100644 src/main/java/com/postgraduate/global/bizppurio/application/dto/req/ContentRequest.java rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/req/content/CertificationApproveMessage.java (52%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/req/content/CertificationDeniedMessage.java (52%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/req/content/JuniorAcceptMessage.java (66%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/req/content/JuniorApplyMessage.java (65%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/req/content/JuniorFinishMessage.java (51%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/req/content/JuniorRefuseMessage.java (51%) create mode 100644 src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/Message.java rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/req/content/SeniorAcceptMessage.java (66%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/req/content/SeniorApplyMessage.java (51%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/req/content/SeniorFinishMessage.java (66%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/req/content/SeniorSingUpMessage.java (51%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/req/content/button/WebLinkButton.java (61%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/res/BizppurioTokenResponse.java (58%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/dto/res/MessageResponse.java (61%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/usecase/BizppurioAuth.java (94%) rename src/main/java/com/postgraduate/global/bizppurio/{ => application}/usecase/BizppurioSeniorMessage.java (91%) delete mode 100644 src/main/java/com/postgraduate/global/bizppurio/dto/req/ContentRequest.java delete mode 100644 src/main/java/com/postgraduate/global/bizppurio/dto/req/content/Message.java diff --git a/src/main/java/com/postgraduate/batch/cancel/CancelMentoringWriter.java b/src/main/java/com/postgraduate/batch/cancel/CancelMentoringWriter.java index 1f3ac01b..4a81521a 100644 --- a/src/main/java/com/postgraduate/batch/cancel/CancelMentoringWriter.java +++ b/src/main/java/com/postgraduate/batch/cancel/CancelMentoringWriter.java @@ -3,7 +3,7 @@ import com.postgraduate.domain.payment.application.usecase.PaymentManageUseCase; import com.postgraduate.domain.user.domain.entity.User; import com.postgraduate.domain.user.domain.service.UserGetService; -import com.postgraduate.global.bizppurio.usecase.BizppurioJuniorMessage; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioJuniorMessage; import com.postgraduate.global.slack.SlackErrorMessage; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; diff --git a/src/main/java/com/postgraduate/domain/adminssr/application/usecase/AdminSeniorUseCase.java b/src/main/java/com/postgraduate/domain/adminssr/application/usecase/AdminSeniorUseCase.java index 3c97d577..7ccdb127 100644 --- a/src/main/java/com/postgraduate/domain/adminssr/application/usecase/AdminSeniorUseCase.java +++ b/src/main/java/com/postgraduate/domain/adminssr/application/usecase/AdminSeniorUseCase.java @@ -10,7 +10,7 @@ import com.postgraduate.domain.senior.exception.SeniorCertificationException; import com.postgraduate.domain.wish.domain.entity.Wish; import com.postgraduate.domain.wish.domain.service.WishGetService; -import com.postgraduate.global.bizppurio.usecase.BizppurioSeniorMessage; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioSeniorMessage; import lombok.RequiredArgsConstructor; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; diff --git a/src/main/java/com/postgraduate/domain/auth/application/usecase/oauth/SignUpUseCase.java b/src/main/java/com/postgraduate/domain/auth/application/usecase/oauth/SignUpUseCase.java index 548ec6c6..ac291da4 100644 --- a/src/main/java/com/postgraduate/domain/auth/application/usecase/oauth/SignUpUseCase.java +++ b/src/main/java/com/postgraduate/domain/auth/application/usecase/oauth/SignUpUseCase.java @@ -15,7 +15,7 @@ import com.postgraduate.domain.wish.application.mapper.WishMapper; import com.postgraduate.domain.wish.domain.entity.Wish; import com.postgraduate.domain.wish.domain.service.WishSaveService; -import com.postgraduate.global.bizppurio.usecase.BizppurioSeniorMessage; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioSeniorMessage; import com.postgraduate.global.slack.SlackSignUpMessage; import lombok.RequiredArgsConstructor; import org.springframework.beans.factory.annotation.Value; diff --git a/src/main/java/com/postgraduate/domain/mentoring/application/usecase/MentoringApplyingUseCase.java b/src/main/java/com/postgraduate/domain/mentoring/application/usecase/MentoringApplyingUseCase.java index 459100f3..5334dd70 100644 --- a/src/main/java/com/postgraduate/domain/mentoring/application/usecase/MentoringApplyingUseCase.java +++ b/src/main/java/com/postgraduate/domain/mentoring/application/usecase/MentoringApplyingUseCase.java @@ -13,8 +13,8 @@ import com.postgraduate.domain.payment.domain.service.PaymentGetService; import com.postgraduate.domain.senior.domain.entity.Senior; import com.postgraduate.domain.user.domain.entity.User; -import com.postgraduate.global.bizppurio.usecase.BizppurioJuniorMessage; -import com.postgraduate.global.bizppurio.usecase.BizppurioSeniorMessage; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioJuniorMessage; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioSeniorMessage; import lombok.RequiredArgsConstructor; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; diff --git a/src/main/java/com/postgraduate/domain/mentoring/application/usecase/MentoringManageUseCase.java b/src/main/java/com/postgraduate/domain/mentoring/application/usecase/MentoringManageUseCase.java index c5693a9c..c187e2b2 100644 --- a/src/main/java/com/postgraduate/domain/mentoring/application/usecase/MentoringManageUseCase.java +++ b/src/main/java/com/postgraduate/domain/mentoring/application/usecase/MentoringManageUseCase.java @@ -21,8 +21,8 @@ import com.postgraduate.domain.senior.domain.entity.Senior; import com.postgraduate.domain.senior.domain.service.SeniorGetService; import com.postgraduate.domain.user.domain.entity.User; -import com.postgraduate.global.bizppurio.usecase.BizppurioJuniorMessage; -import com.postgraduate.global.bizppurio.usecase.BizppurioSeniorMessage; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioJuniorMessage; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioSeniorMessage; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springframework.scheduling.annotation.Scheduled; diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/CommonRequest.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/CommonRequest.java similarity index 73% rename from src/main/java/com/postgraduate/global/bizppurio/dto/req/CommonRequest.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/req/CommonRequest.java index 72e2775f..bf77c3cd 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/CommonRequest.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/CommonRequest.java @@ -1,4 +1,4 @@ -package com.postgraduate.global.bizppurio.dto.req; +package com.postgraduate.global.bizppurio.application.dto.req; public record CommonRequest( String account, diff --git a/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/ContentRequest.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/ContentRequest.java new file mode 100644 index 00000000..efff5477 --- /dev/null +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/ContentRequest.java @@ -0,0 +1,5 @@ +package com.postgraduate.global.bizppurio.application.dto.req; + +import com.postgraduate.global.bizppurio.application.dto.req.content.Message; + +public record ContentRequest(Message at) {} diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/CertificationApproveMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/CertificationApproveMessage.java similarity index 52% rename from src/main/java/com/postgraduate/global/bizppurio/dto/req/content/CertificationApproveMessage.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/CertificationApproveMessage.java index 475ebd73..e0ebb6f5 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/CertificationApproveMessage.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/CertificationApproveMessage.java @@ -1,6 +1,6 @@ -package com.postgraduate.global.bizppurio.dto.req.content; +package com.postgraduate.global.bizppurio.application.dto.req.content; -import com.postgraduate.global.bizppurio.dto.req.content.button.WebLinkButton; +import com.postgraduate.global.bizppurio.application.dto.req.content.button.WebLinkButton; public record CertificationApproveMessage( String message, diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/CertificationDeniedMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/CertificationDeniedMessage.java similarity index 52% rename from src/main/java/com/postgraduate/global/bizppurio/dto/req/content/CertificationDeniedMessage.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/CertificationDeniedMessage.java index 9ed44777..51f9c569 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/CertificationDeniedMessage.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/CertificationDeniedMessage.java @@ -1,6 +1,6 @@ -package com.postgraduate.global.bizppurio.dto.req.content; +package com.postgraduate.global.bizppurio.application.dto.req.content; -import com.postgraduate.global.bizppurio.dto.req.content.button.WebLinkButton; +import com.postgraduate.global.bizppurio.application.dto.req.content.button.WebLinkButton; public record CertificationDeniedMessage( String message, diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/JuniorAcceptMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorAcceptMessage.java similarity index 66% rename from src/main/java/com/postgraduate/global/bizppurio/dto/req/content/JuniorAcceptMessage.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorAcceptMessage.java index 50f78b34..8d29dc64 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/JuniorAcceptMessage.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorAcceptMessage.java @@ -1,4 +1,4 @@ -package com.postgraduate.global.bizppurio.dto.req.content; +package com.postgraduate.global.bizppurio.application.dto.req.content; public record JuniorAcceptMessage( String message, diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/JuniorApplyMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorApplyMessage.java similarity index 65% rename from src/main/java/com/postgraduate/global/bizppurio/dto/req/content/JuniorApplyMessage.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorApplyMessage.java index 1ff06375..0cfbc462 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/JuniorApplyMessage.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorApplyMessage.java @@ -1,4 +1,4 @@ -package com.postgraduate.global.bizppurio.dto.req.content; +package com.postgraduate.global.bizppurio.application.dto.req.content; public record JuniorApplyMessage( String message, diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/JuniorFinishMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorFinishMessage.java similarity index 51% rename from src/main/java/com/postgraduate/global/bizppurio/dto/req/content/JuniorFinishMessage.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorFinishMessage.java index af44bce0..6e16ac5d 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/JuniorFinishMessage.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorFinishMessage.java @@ -1,6 +1,6 @@ -package com.postgraduate.global.bizppurio.dto.req.content; +package com.postgraduate.global.bizppurio.application.dto.req.content; -import com.postgraduate.global.bizppurio.dto.req.content.button.WebLinkButton; +import com.postgraduate.global.bizppurio.application.dto.req.content.button.WebLinkButton; public record JuniorFinishMessage( String message, diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/JuniorRefuseMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorRefuseMessage.java similarity index 51% rename from src/main/java/com/postgraduate/global/bizppurio/dto/req/content/JuniorRefuseMessage.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorRefuseMessage.java index cb6a9aa6..651af74a 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/JuniorRefuseMessage.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/JuniorRefuseMessage.java @@ -1,6 +1,6 @@ -package com.postgraduate.global.bizppurio.dto.req.content; +package com.postgraduate.global.bizppurio.application.dto.req.content; -import com.postgraduate.global.bizppurio.dto.req.content.button.WebLinkButton; +import com.postgraduate.global.bizppurio.application.dto.req.content.button.WebLinkButton; public record JuniorRefuseMessage( String message, diff --git a/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/Message.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/Message.java new file mode 100644 index 00000000..b9ce39cd --- /dev/null +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/Message.java @@ -0,0 +1,4 @@ +package com.postgraduate.global.bizppurio.application.dto.req.content; + +public interface Message { +} diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/SeniorAcceptMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/SeniorAcceptMessage.java similarity index 66% rename from src/main/java/com/postgraduate/global/bizppurio/dto/req/content/SeniorAcceptMessage.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/SeniorAcceptMessage.java index e109c6ac..9497de60 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/SeniorAcceptMessage.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/SeniorAcceptMessage.java @@ -1,4 +1,4 @@ -package com.postgraduate.global.bizppurio.dto.req.content; +package com.postgraduate.global.bizppurio.application.dto.req.content; public record SeniorAcceptMessage( String message, diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/SeniorApplyMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/SeniorApplyMessage.java similarity index 51% rename from src/main/java/com/postgraduate/global/bizppurio/dto/req/content/SeniorApplyMessage.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/SeniorApplyMessage.java index 0536bfa4..0d3d7698 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/SeniorApplyMessage.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/SeniorApplyMessage.java @@ -1,6 +1,6 @@ -package com.postgraduate.global.bizppurio.dto.req.content; +package com.postgraduate.global.bizppurio.application.dto.req.content; -import com.postgraduate.global.bizppurio.dto.req.content.button.WebLinkButton; +import com.postgraduate.global.bizppurio.application.dto.req.content.button.WebLinkButton; public record SeniorApplyMessage( String message, diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/SeniorFinishMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/SeniorFinishMessage.java similarity index 66% rename from src/main/java/com/postgraduate/global/bizppurio/dto/req/content/SeniorFinishMessage.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/SeniorFinishMessage.java index f2521eb3..ce81d0f2 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/SeniorFinishMessage.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/SeniorFinishMessage.java @@ -1,4 +1,4 @@ -package com.postgraduate.global.bizppurio.dto.req.content; +package com.postgraduate.global.bizppurio.application.dto.req.content; public record SeniorFinishMessage( String message, diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/SeniorSingUpMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/SeniorSingUpMessage.java similarity index 51% rename from src/main/java/com/postgraduate/global/bizppurio/dto/req/content/SeniorSingUpMessage.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/SeniorSingUpMessage.java index b23840e8..9287918b 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/SeniorSingUpMessage.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/SeniorSingUpMessage.java @@ -1,6 +1,6 @@ -package com.postgraduate.global.bizppurio.dto.req.content; +package com.postgraduate.global.bizppurio.application.dto.req.content; -import com.postgraduate.global.bizppurio.dto.req.content.button.WebLinkButton; +import com.postgraduate.global.bizppurio.application.dto.req.content.button.WebLinkButton; public record SeniorSingUpMessage( String message, diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/button/WebLinkButton.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/button/WebLinkButton.java similarity index 61% rename from src/main/java/com/postgraduate/global/bizppurio/dto/req/content/button/WebLinkButton.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/button/WebLinkButton.java index 614d0c76..d0634528 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/button/WebLinkButton.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/req/content/button/WebLinkButton.java @@ -1,4 +1,4 @@ -package com.postgraduate.global.bizppurio.dto.req.content.button; +package com.postgraduate.global.bizppurio.application.dto.req.content.button; public record WebLinkButton( String name, diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/res/BizppurioTokenResponse.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/res/BizppurioTokenResponse.java similarity index 58% rename from src/main/java/com/postgraduate/global/bizppurio/dto/res/BizppurioTokenResponse.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/res/BizppurioTokenResponse.java index b390575f..4aaeedc3 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/res/BizppurioTokenResponse.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/res/BizppurioTokenResponse.java @@ -1,3 +1,3 @@ -package com.postgraduate.global.bizppurio.dto.res; +package com.postgraduate.global.bizppurio.application.dto.res; public record BizppurioTokenResponse(String accesstoken, String type, String expired) {} diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/res/MessageResponse.java b/src/main/java/com/postgraduate/global/bizppurio/application/dto/res/MessageResponse.java similarity index 61% rename from src/main/java/com/postgraduate/global/bizppurio/dto/res/MessageResponse.java rename to src/main/java/com/postgraduate/global/bizppurio/application/dto/res/MessageResponse.java index 4ae6e6cc..3459a8e4 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/res/MessageResponse.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/dto/res/MessageResponse.java @@ -1,4 +1,4 @@ -package com.postgraduate.global.bizppurio.dto.res; +package com.postgraduate.global.bizppurio.application.dto.res; public record MessageResponse(int code, String description, String messagekey, String refkey) { } diff --git a/src/main/java/com/postgraduate/global/bizppurio/usecase/BizppurioAuth.java b/src/main/java/com/postgraduate/global/bizppurio/application/usecase/BizppurioAuth.java similarity index 94% rename from src/main/java/com/postgraduate/global/bizppurio/usecase/BizppurioAuth.java rename to src/main/java/com/postgraduate/global/bizppurio/application/usecase/BizppurioAuth.java index 34da9681..1b85579a 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/usecase/BizppurioAuth.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/usecase/BizppurioAuth.java @@ -1,6 +1,6 @@ -package com.postgraduate.global.bizppurio.usecase; +package com.postgraduate.global.bizppurio.application.usecase; -import com.postgraduate.global.bizppurio.dto.res.BizppurioTokenResponse; +import com.postgraduate.global.bizppurio.application.dto.res.BizppurioTokenResponse; import com.postgraduate.global.config.redis.RedisRepository; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; diff --git a/src/main/java/com/postgraduate/global/bizppurio/usecase/BizppurioSeniorMessage.java b/src/main/java/com/postgraduate/global/bizppurio/application/usecase/BizppurioSeniorMessage.java similarity index 91% rename from src/main/java/com/postgraduate/global/bizppurio/usecase/BizppurioSeniorMessage.java rename to src/main/java/com/postgraduate/global/bizppurio/application/usecase/BizppurioSeniorMessage.java index caa45b47..cfaab53d 100644 --- a/src/main/java/com/postgraduate/global/bizppurio/usecase/BizppurioSeniorMessage.java +++ b/src/main/java/com/postgraduate/global/bizppurio/application/usecase/BizppurioSeniorMessage.java @@ -1,8 +1,8 @@ -package com.postgraduate.global.bizppurio.usecase; +package com.postgraduate.global.bizppurio.application.usecase; import com.postgraduate.domain.senior.domain.entity.Senior; import com.postgraduate.domain.user.domain.entity.User; -import com.postgraduate.global.bizppurio.mapper.BizppurioMapper; +import com.postgraduate.global.bizppurio.application.mapper.BizppurioMapper; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springframework.stereotype.Component; diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/ContentRequest.java b/src/main/java/com/postgraduate/global/bizppurio/dto/req/ContentRequest.java deleted file mode 100644 index 1399c6d7..00000000 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/ContentRequest.java +++ /dev/null @@ -1,5 +0,0 @@ -package com.postgraduate.global.bizppurio.dto.req; - -import com.postgraduate.global.bizppurio.dto.req.content.Message; - -public record ContentRequest(Message at) {} diff --git a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/Message.java b/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/Message.java deleted file mode 100644 index 1087ab3e..00000000 --- a/src/main/java/com/postgraduate/global/bizppurio/dto/req/content/Message.java +++ /dev/null @@ -1,4 +0,0 @@ -package com.postgraduate.global.bizppurio.dto.req.content; - -public interface Message { -} diff --git a/src/test/java/com/postgraduate/domain/auth/application/usecase/oauth/SignUpUseTypeTest.java b/src/test/java/com/postgraduate/domain/auth/application/usecase/oauth/SignUpUseTypeTest.java index 5b038a9d..79efe126 100644 --- a/src/test/java/com/postgraduate/domain/auth/application/usecase/oauth/SignUpUseTypeTest.java +++ b/src/test/java/com/postgraduate/domain/auth/application/usecase/oauth/SignUpUseTypeTest.java @@ -19,7 +19,7 @@ import com.postgraduate.domain.wish.domain.entity.Wish; import com.postgraduate.domain.wish.domain.entity.constant.Status; import com.postgraduate.domain.wish.domain.service.WishSaveService; -import com.postgraduate.global.bizppurio.usecase.BizppurioSeniorMessage; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioSeniorMessage; import com.postgraduate.global.slack.SlackSignUpMessage; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.DisplayName; diff --git a/src/test/java/com/postgraduate/domain/mentoring/application/usecase/MentoringApplyingUseTypeTest.java b/src/test/java/com/postgraduate/domain/mentoring/application/usecase/MentoringApplyingUseTypeTest.java index 6b5bc4e6..624ceca0 100644 --- a/src/test/java/com/postgraduate/domain/mentoring/application/usecase/MentoringApplyingUseTypeTest.java +++ b/src/test/java/com/postgraduate/domain/mentoring/application/usecase/MentoringApplyingUseTypeTest.java @@ -17,8 +17,8 @@ import com.postgraduate.domain.senior.domain.entity.Profile; import com.postgraduate.domain.senior.domain.entity.Senior; import com.postgraduate.domain.user.domain.entity.User; -import com.postgraduate.global.bizppurio.usecase.BizppurioJuniorMessage; -import com.postgraduate.global.bizppurio.usecase.BizppurioSeniorMessage; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioJuniorMessage; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioSeniorMessage; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.DisplayName; import org.junit.jupiter.api.Test; diff --git a/src/test/java/com/postgraduate/domain/mentoring/application/usecase/MentoringManageUseTypeTest.java b/src/test/java/com/postgraduate/domain/mentoring/application/usecase/MentoringManageUseTypeTest.java index 681e06b6..d5770e87 100644 --- a/src/test/java/com/postgraduate/domain/mentoring/application/usecase/MentoringManageUseTypeTest.java +++ b/src/test/java/com/postgraduate/domain/mentoring/application/usecase/MentoringManageUseTypeTest.java @@ -25,8 +25,8 @@ import com.postgraduate.domain.senior.domain.entity.Senior; import com.postgraduate.domain.senior.domain.service.SeniorGetService; import com.postgraduate.domain.user.domain.entity.User; -import com.postgraduate.global.bizppurio.usecase.BizppurioJuniorMessage; -import com.postgraduate.global.bizppurio.usecase.BizppurioSeniorMessage; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioJuniorMessage; +import com.postgraduate.global.bizppurio.application.usecase.BizppurioSeniorMessage; import com.postgraduate.global.slack.SlackErrorMessage; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.DisplayName;