From d260f7a719d4b0ed4e037ed28d642a32f59b2ddd Mon Sep 17 00:00:00 2001 From: hd0rable Date: Thu, 1 Aug 2024 16:47:37 +0900 Subject: [PATCH 1/4] . --- .gradle/8.9/checksums/checksums.lock | Bin 17 -> 17 bytes .gradle/8.9/checksums/md5-checksums.bin | Bin 19947 -> 21697 bytes .gradle/8.9/checksums/sha1-checksums.bin | Bin 22763 -> 26759 bytes .../8.9/executionHistory/executionHistory.bin | Bin 258894 -> 341008 bytes .../executionHistory/executionHistory.lock | Bin 17 -> 17 bytes .gradle/8.9/fileHashes/fileHashes.bin | Bin 22847 -> 26697 bytes .gradle/8.9/fileHashes/fileHashes.lock | Bin 17 -> 17 bytes .../8.9/fileHashes/resourceHashesCache.bin | Bin 21115 -> 22373 bytes .../buildOutputCleanup.lock | Bin 17 -> 17 bytes .gradle/buildOutputCleanup/outputFiles.bin | Bin 19541 -> 19937 bytes .gradle/file-system.probe | Bin 8 -> 8 bytes .../util/JwtAuthenticationFilter.java | 4 ++-- .../example/likelion12/util/JwtProvider.java | 12 +++++------- src/main/resources/application.yml | 3 ++- 14 files changed, 9 insertions(+), 10 deletions(-) diff --git a/.gradle/8.9/checksums/checksums.lock b/.gradle/8.9/checksums/checksums.lock index ee766e9ce88336465f85400416d590980fde2f57..dcc833ae1b32322ce23eb7ca1301f59e805a8230 100644 GIT binary patch literal 17 UcmZR+)nv#0rbEV^0RmnE0507GX#fBK literal 17 TcmZR+)nv#0rbEV^0Rl<@E@%Vv diff --git a/.gradle/8.9/checksums/md5-checksums.bin b/.gradle/8.9/checksums/md5-checksums.bin index d0a52bbf8624a9241c658c32c43760d507e69278..0a9979c0d3205dc2f077bef7a9cc46e6bf07ddfd 100644 GIT binary patch delta 1544 zcmZXU4NOy46vqKuT=}f5(!Mu=me5-0=!%0-aWb5l_Pe#E)LGqv45s^_Vg^J|KBi`I zK+JXm8c<0|W;Z`F6&Bpsz_BpL80(@glO?R;vTPGr>>Pta9lNjhKC<9VUhliV^FRM{ z?|CPVqoaEP+-IhO|esPl?446UOuM5zm+E7n&TTXr8H zkjvUeU#sZvX}9mi+?2#}YW~GLs-DiBm|MnRh7$8r?@M+o|M1-<&;zlwST4&qesfm^ zL&TXiSX}F`N*N5BYQ%h-3#7ETK&9E*Y>!LMATXL$XWeM~*Rk*1e&W1}<#{VhYxfDS zCSq>84jYllvze6gubN77E6hSx{Ji?Rg)v>uTf}@L%Z)zw{-*AUG-AFP?8v03_i96@ zRO`ghILV3~`TxZG;yF>6o3%^4VL;>3D5nVb!5g$iURKvzwixkhK8B`7R=lV6beAhx zR)e`U7d}RfD&Ky1hkDLSDq1^OvFp6}s8f;0!(v+&jM5nqk*h9C=7g73k0o?((wyVM ztUi?!9h|d6l7WUsjUXQ_Y&e5=8_mk6(N8*hB+SGAEUine|6TdI`a!%zt|&pDH~d|c zQG|kMBsYLtBSU_HFc{I$kZTYy3l5kKbbWKKGg2h*a_3iDT8l2Y^KfcFj#Dc%XkJ$A z?NhHDd!efMR>b?mvZ@*>MT(K_MfxAjFcp;l>5bW5J(kpGPraQT_}}(&k(w9%Xv)xF zO8d$Thc6|H|LyDsx|*cyKuR=XX2D?yo#-qyq7IE31TpADXG!!395cum@FNDo>o9GQ zp&l-Qmr-EZu};0z-CrtAh=_GQQN3oo8F?{1oL6CsHN$W-)WdldJVZUrGBQ0}kb>5z zWL}tH~~xCGaMU&j;*lKUIg1c!~GQboV`V)iUzL@ZEGwtP#B_3_;t%nS1_7d*9X(dD0su{HA!Gmm diff --git a/.gradle/8.9/checksums/sha1-checksums.bin b/.gradle/8.9/checksums/sha1-checksums.bin index 09eec73251f52ae4631adc8640b64c6bc91d842a..1f92b21b7aa2621db343935effb8c809595f9fb2 100644 GIT binary patch delta 3229 zcmb7`c~leE9>)_lfe;gmKu91Y3JO?clT#2WiB<&(kRSnB!eR(Zt=plBR#~jiwc?Zh zL znP(dMwhnsrERMKn%QD&4=hC;=Xv7tn{f@l0?iNnHnm6wq;;|hR-+pP;v8TQppCPVN zz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f4n#u)1~%fC0%T&35^;OqpN^GzBpr?+U0u)zyxl9<52wNF%S zJ*@K&LbihyJEp0rJ;0)rz@zg56^5E3DEYnOIKcWM^eyO0N|#aTec_!goVg&&(a7>W z+kd+2WXOhG-TQSj`F4^&r4Ie!3^TjZ z+r+m{4#CdGxfGI-rCXPgmqq;DvZ1z`nM1uwERr2V5A9-+u3z$%ITn~o_)c@c z-J!g*%uF9L6OLp8zgIOXMkpsv{%-nRzYd-_ssYu;($gw^LRL6;r7hcHD%S#$oWmOr zEXZ8DvlJuWbLVdO!6diE69RN9UMW(X@tPqYM6cdim;GBF_hxl;5}Rf&Xi? zhEHDHdd5y`_*Y!Ij@EF`C8!fgYl!f739aE1xI}0TpTQ+UYxq6ZMraKm#C3$$kdz3m z;m`Og&>Du``rU<=WfxR=CUy3c<%o?WDE@b^K5wQ;+;YP7)y{7Nj(kU?o*UNNmy(=cYW;q73H#iy-#xwYa?*h1WIkkOrxO@4r%ZECvq1?tk1AK^Ynz25z|XvB5nO1 zlT8L!hNQo&v%RzYH^at%>>qe2?2blqaYrNwFPr&rboey0f_d??eRJ2vwn5eSQ+ZX{ z4=>p=_N^BuC61Z%5L9hAx%Rb!%nzbxztMX9;N=H4Le-@A&6|H*_!alct3N)rYxl%* zs5&??{gu;?RzBYL=R;@I!`{A6_MC|v4S-@6GEx6Oc`hRphx}pDuDkEq5Rp=wwr}X7 RT_@YIYwv6!JePHC{{xt@&5r;8 delta 168 zcmbR6Lgd^t{s|(yYz$!F;mE*{QaDl3o-uY~;|%eM6BH&(N@z)~+4LU@m=Yd;n%U06 z3RcY=c5ZX5#A|)mlmwu*gxR^JC0TiCiRMXpNx3uQyEN!VsE%F`U_T`-9KS>)4tb{M#G+8G)E-dxJmoxy1m)8%9(B diff --git a/.gradle/8.9/executionHistory/executionHistory.lock b/.gradle/8.9/executionHistory/executionHistory.lock index ec2d17efa8cdd8915bbac8ae5c2e4300beb15670..8257808885d2741b58a4d1a0414af31d73cb5b8b 100644 GIT binary patch literal 17 UcmZSP<;eMVZ?EC;$Ke diff --git a/.gradle/8.9/fileHashes/fileHashes.bin b/.gradle/8.9/fileHashes/fileHashes.bin index ff6f6be417372dd0cccb5542917f49627838f4d5..592bb47ecd431196215dac4dc5eaee453347e5ec 100644 GIT binary patch delta 4549 zcma)<3p|urAIAsdPV=}F#%*+Ay1677$!#l1E7#mFp)sNoi?A{&WuQ>-p}VfpN|>7&+qsD|Ic~;=RA+*T8WMx ziRzV_TIbRof323HT>6V57~9%D5Cd3fIvE}Dl{WtJ9zPvj4Cjy+^OS#M1zObTA|49j zH4T{gDI2`k=%jyx7<)0P{Z>-ur^RuaM-dM`2zZ(d<_W`EryZ$F0}=G^CdH?Yp7`^) zR`Ml+7lBeuH>@_a`eX5ezaS z!&XeZd1~jMsET+*J;^IKugkhsq>znxU@LIZa${EQ@mf!_rPLu9W=)E#vhC9nr_Plj z?sp#?*NVjIW;o}Uow{0q;5HL5rNzLmpTNS*iyMjBIO#x{&R{kixe+r|Gc*-1ehHy#ot=zm{7aABuA|CcVu%R=sw$_lO^$H~n z1h-xQTVRBCY-h^Id0QU@gBr;Q?E%(FYq$f45%-SQj6;+_Iu z<5}-91;oSO{lg1uPfHaJmLeWX14VQL+Wh>|=-9W<5#tPlI(j7YaaD|37|-w}f&u1a zfM1^ay061d84$b!%++T34y29ccIhOVAs8-2iU+tB6~iYgjv*egh2(<;^h#^hdRN4Q zet(r&)Fr2M{0oe+AM5zt#`n8W!NnQgR((_HUs;e{;uxlayg>iIIe)FZ9t<& za;khwh&~Qn4oV>_nC!hf{L5-&4wDCs&^$S>Q};IO^a=z+zXJEQS@wTj?My3g(xf7| z?KN4`Y+a92_f2jG;{LKEf7kg;uWMI(G~ygxAgxo4$&3d0JUp~94Z$Eka8ZYWDLth= zzF4KO6Txr`(5Ay+V&=0BsSdhCKLorb!(t`pYj+0uA3E!T-2>{+ARHX6M|d$WG=%s zQC%CK99V^T$Wzdz%U~LnT>Q#WlglNnwr+5`d>?K%3(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^RgE=R?827e>JfG>^R(y}ES4k#I|SlnSM zd&ReGqsvjfmHC#{a=!5YH$2Dd$54syITJWN(Ihf0jvG2UmKBx^u6lN|!3Q>%U=Qqq zN;o7v;fF|Bzt!X!rMnbKyFQ6IIdwe&KJ$ef_*#fKdi~`Rxv_NmonV#DpX38dN(6No z%1z-ZU=kQY)bhEqlnhnV1&05-Ea<==32;c7|Bt%F%TmoJEcZdnCN=KM$rO|N1&>{s z&uSM-CBg#;E~!^EzHQ-<{mdCWC(1eLa=fZ%@Pa(;=ee{p3CUQvJh2J9UBUk-r zT+wcg>s{N^LaC?xVSC}X?fEO*0q>h)mAGZ&)b1d^TDJ|6KJiU+yt?Ni%XA-Zp-_zA zofl0KwYt^v-(PLkVD*>0+T4&*OgILh5{}P3I=zNt5(c@6Uz?uni^ z{Z#ls5=}BVlM)?xe*c}JTMURtquj0(jS?RTJdI-mR KVZ(U}Ma zHw%%CLWE3Gp5U{6((~Q#>&N?i^3w}9lLPE_*|H&wJI9g zsK8(#giccDKCx_*XP%nEN=2!5YMwg$%rVJ??`%Xbw@h>4 vBRA~x0kaE>Ul?wR0oy|8mHIDrqjX$d+Uno`RVpX#MS7?&?56hCb-!mvDKAd) diff --git a/.gradle/8.9/fileHashes/fileHashes.lock b/.gradle/8.9/fileHashes/fileHashes.lock index 0c5b469c9dfee7d4fa923824c3964b3df5e529c5..6d3ceeb68c2165f5aab6a3a32ac577bf14efff5e 100644 GIT binary patch literal 17 VcmZSH*WdW1chikf1~6dm0sulb1-}3Q literal 17 VcmZSH*WdW1chikf1~6dy4gf--1}gvn diff --git a/.gradle/8.9/fileHashes/resourceHashesCache.bin b/.gradle/8.9/fileHashes/resourceHashesCache.bin index 40b0c3bf4ff25443ba7f2087a47bc2169d9d6984..8e9d177547c32cd5477fc1533818fa306c9381c5 100644 GIT binary patch delta 1086 zcmeypgz@P*#tkMCl0^;I4s)`w&5>jPgRt`dP%zn4!b6~I(%&0w56>7vBtwKJmr5uI zOlqjfTgkM=2qGBnJh@jwL1UJwfcN}{+=URq;7ph?vlHhjdhdR55-NUv@=~A)^A*1c z|96N!3=s@wj7uD)w=*sI-E>m)DD24HBegLj{>9>q=V){JQRJbxfY;6I5{RMSwCD|Chqd}H$*UO_vEG0R(ve7Z5-RyK{cyRzA7D{!Q*nxhNq?C z15}+c%$O=gsVC=RNIDHiLr4zOQX@*E-_t_TyC zRoPN+?cV7JHT>@6RGAC`4FwhP07cd<5WlaI<|I2ajQy=wa>Z~!70vKMB8@yd(~ zo^G?DZVqLHiJSUmoc?*V@;cPy|C3c^6$H#I)85^G#l;UbotOt_N- z5e!{DIal_CM#AC%iR{hY8=%?+Va6sb=aD{V)wBm99`tatuACPm6W76wia*3R8bt7J zcJ#2~n(XLtYx4Pkw8_drN|P6RzMEVbs5E)Am(t|fK>E8^$7E9=?dhj9`Junkwf-)%p4ZEYekbLHhRF#u!mdo!|3pj?I0BZE#`Dn delta 140 zcmaF5j`8;r#tkMCjJ}h7B|Ijtm5`Wx7l>6QB_@XgajT@qs0Cht`^uz9Vb6C)G5=SIaJ;u{Sv2yAxru;Ky$gtai) diff --git a/.gradle/buildOutputCleanup/buildOutputCleanup.lock b/.gradle/buildOutputCleanup/buildOutputCleanup.lock index a33bca4557f8f53b6bb1c93282f5c0127c35b643..cd37e02f4dfda5ed9dc927c2650fe9847814fdd2 100644 GIT binary patch literal 17 VcmZR+p%iF3>C>VJ1~6b&2LLg+1S|jm literal 17 VcmZR+p%iF3>C>VJ1~6dy3;;5M1or>{ diff --git a/.gradle/buildOutputCleanup/outputFiles.bin b/.gradle/buildOutputCleanup/outputFiles.bin index d84ecdad8b8cfdd5c54b08ced462e7ae70bfb92f..e49ba499327cf4caf7426866ec9e3e4a8ed176ef 100644 GIT binary patch delta 537 zcmcaQgYn^P#tkMCi~*ZXB{&!b=A|y48Kh{F#{dRC2Pd0KT4*fYX3NSq_p}d0&{y|A z6s(Z?cp@(4!Az*)(8;Ni3L2ZYT6$zPM%qIa2f`F@Wm(5MvwO!hs5s~3TFD;*SGtoU zCKlMcLrs`FIakU;bmIB&5HW^DIlSLpx;&P)UM1f9(_P?e=HW4Was39Vh3Qwp{2GE7_| z*T`^3Ht#B^`1;Ac(u(}StzYNmoR|O=OP{<{+Co5P-M`!!^K_tszR8oXN;e1?v$$m% zn*;_yZCgFrSEfP0S6Y4UJ?=UKsNmkoM`bKD!fwo)%K;t%nS1|0&M9X&)?Chzy)oxH$HWpjc@G$R1G!ptuK delta 102 zcmaDjoAK%l#tkMCj8>aXB{&!-he{eu-YO|E`LE=M$*j@_lT(3st#rj?TN#hZXJsTO z|C7<5>?&I^`6>{n${9>PDkm}dD-f&7SMdCY0tN=w#*K token.startsWith("Bearer ")) - .map(token -> token.substring(7)) + .map(token -> token.substring(7).trim()) // 공백 제거 .orElse(null); } } diff --git a/src/main/java/com/example/likelion12/util/JwtProvider.java b/src/main/java/com/example/likelion12/util/JwtProvider.java index f3419ea..e874982 100644 --- a/src/main/java/com/example/likelion12/util/JwtProvider.java +++ b/src/main/java/com/example/likelion12/util/JwtProvider.java @@ -4,7 +4,6 @@ import io.jsonwebtoken.Claims; import io.jsonwebtoken.Jwts; import io.jsonwebtoken.SignatureAlgorithm; -import lombok.AllArgsConstructor; import org.springframework.beans.factory.annotation.Value; import org.springframework.stereotype.Component; @@ -22,7 +21,7 @@ public class JwtProvider { // Access Token 생성 public String createAccessToken(String email, Long memberId) { - Claims claims = Jwts.claims().setSubject(email); + Claims claims = Jwts.claims().setSubject(email.trim()); Date now = new Date(); Date validity = new Date(now.getTime() + accessTokenExpiration); @@ -30,7 +29,7 @@ public String createAccessToken(String email, Long memberId) { .setClaims(claims) .setIssuedAt(now) .setExpiration(validity) - .claim("memberId",memberId) + .claim("memberId", memberId) .signWith(SignatureAlgorithm.HS256, secretKey) .compact(); } @@ -52,7 +51,7 @@ public Long extractIdFromHeader(String authorization) { try { jwtToken = extractJwtToken(authorization); } catch (IllegalArgumentException e) { - throw new IllegalArgumentException("유효하지 않은 헤더 포멧입니다."); + throw new IllegalArgumentException("유효하지 않은 헤더 포맷입니다."); } // JWT 토큰에서 사용자 정보 추출 @@ -71,9 +70,9 @@ public Long extractIdFromHeader(String authorization) { public String extractJwtToken(String authorizationHeader) { String[] parts = authorizationHeader.split(" "); if (parts.length == 2) { - return parts[1]; // 토큰 부분 추출 + return parts[1].trim(); // 토큰 부분 추출 및 공백 제거 } - throw new IllegalArgumentException("유효하지 않은 헤더 포멧입니다."); + throw new IllegalArgumentException("유효하지 않은 헤더 포맷입니다."); } public Long extractMemberIdFromJwtToken(String jwtToken) { @@ -91,5 +90,4 @@ public Long extractMemberIdFromJwtToken(String jwtToken) { return memberId; } - } diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml index 591590d..b313c5f 100644 --- a/src/main/resources/application.yml +++ b/src/main/resources/application.yml @@ -26,7 +26,8 @@ spring: registration: kakao: client-id: ${CLIENT_ID} - redirect-uri: "http://43.202.94.241:8080/auth/kakao/callback" +# redirect-uri: "http://43.202.94.241:8080/auth/kakao/callback" + redirect-uri: "http://localhost:8080/auth/kakao/callback" --- jwt: secret: ${JWT_SECRET} From f49a852d2bf93f08452ed3711a8fcf86c1c214a4 Mon Sep 17 00:00:00 2001 From: hd0rable Date: Thu, 1 Aug 2024 17:50:21 +0900 Subject: [PATCH 2/4] =?UTF-8?q?feat=20:=20=EC=86=8C=EC=85=9C=EB=A7=81=20?= =?UTF-8?q?=EB=93=B1=EB=A1=9D=20=EA=B5=AC=ED=98=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/SocialringController.java | 28 ++++++++ .../likelion12/domain/MemberSocialring.java | 6 ++ .../example/likelion12/domain/Socialring.java | 22 +++++- .../likelion12/dto/PostSocialringRequest.java | 25 +++++++ .../dto/PostSocialringResponse.java | 10 +++ .../MembersSocialringRepository.java | 7 ++ .../repository/SocialringRepository.java | 9 +++ .../service/MemberSocialringService.java | 29 ++++++++ .../likelion12/service/SocialringService.java | 69 +++++++++++++++++++ 9 files changed, 203 insertions(+), 2 deletions(-) create mode 100644 src/main/java/com/example/likelion12/controller/SocialringController.java create mode 100644 src/main/java/com/example/likelion12/dto/PostSocialringRequest.java create mode 100644 src/main/java/com/example/likelion12/dto/PostSocialringResponse.java create mode 100644 src/main/java/com/example/likelion12/repository/MembersSocialringRepository.java create mode 100644 src/main/java/com/example/likelion12/repository/SocialringRepository.java create mode 100644 src/main/java/com/example/likelion12/service/MemberSocialringService.java create mode 100644 src/main/java/com/example/likelion12/service/SocialringService.java diff --git a/src/main/java/com/example/likelion12/controller/SocialringController.java b/src/main/java/com/example/likelion12/controller/SocialringController.java new file mode 100644 index 0000000..81c594a --- /dev/null +++ b/src/main/java/com/example/likelion12/controller/SocialringController.java @@ -0,0 +1,28 @@ +package com.example.likelion12.controller; + +import com.example.likelion12.common.response.BaseResponse; +import com.example.likelion12.dto.PostSocialringRequest; +import com.example.likelion12.dto.PostSocialringResponse; +import com.example.likelion12.service.SocialringService; +import com.example.likelion12.util.JwtProvider; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springframework.web.bind.annotation.*; + +@Slf4j +@RestController +@RequiredArgsConstructor +@RequestMapping("/socialring") + +public class SocialringController { + + private final SocialringService socialringService; + private final JwtProvider jwtProvider; + + @PostMapping("") + public BaseResponse createSocialring(@RequestHeader("Authorization") String authorization , @RequestBody PostSocialringRequest postSocialringRequest) + { //헤더에서 소셜링 등록하는 멤버아이디 찾기 + Long memberId = jwtProvider.extractIdFromHeader(authorization); + return new BaseResponse<>(socialringService.createSocialring(memberId,postSocialringRequest)); + } +} diff --git a/src/main/java/com/example/likelion12/domain/MemberSocialring.java b/src/main/java/com/example/likelion12/domain/MemberSocialring.java index 264b57a..a60cde3 100644 --- a/src/main/java/com/example/likelion12/domain/MemberSocialring.java +++ b/src/main/java/com/example/likelion12/domain/MemberSocialring.java @@ -39,4 +39,10 @@ public class MemberSocialring extends BaseTime { @JoinColumn(name = "member_id") private Member member; + public MemberSocialring(BaseRole baseRole, Socialring socialring, Member member, BaseStatus baseStatus) { + this.role = baseRole; + this.socialring = socialring; + this.member = member; + this.status = baseStatus; + } } diff --git a/src/main/java/com/example/likelion12/domain/Socialring.java b/src/main/java/com/example/likelion12/domain/Socialring.java index 8468678..4330c89 100644 --- a/src/main/java/com/example/likelion12/domain/Socialring.java +++ b/src/main/java/com/example/likelion12/domain/Socialring.java @@ -10,7 +10,7 @@ import lombok.Getter; import lombok.NoArgsConstructor; -import java.time.LocalDateTime; +import java.time.LocalDate; import java.util.ArrayList; import java.util.List; @@ -36,7 +36,7 @@ public class Socialring extends BaseTime { private int totalRecruits; @Column(nullable = false) - private LocalDateTime socialringDate; + private LocalDate socialringDate; @Column(nullable = false) private int socialringCost; @@ -77,4 +77,22 @@ public class Socialring extends BaseTime { @ManyToOne(fetch = LAZY) @JoinColumn(name = "exercise_id") private Exercise exercise; + + public Socialring(String socialringName, String socialringImg, int totalRecruits, LocalDate socialringDate, + int socialringCost, String comment, String commentSimple, BaseGender gender, BaseLevel level, + ActivityRegion activityRegion, Facility facility, Exercise exercise, BaseStatus baseStatus) { + this.socialringName = socialringName; + this.socialringImg = socialringImg; + this.totalRecruits = totalRecruits; + this.socialringDate = socialringDate; + this.socialringCost = socialringCost; + this.commentSimple = commentSimple; + this.comment = comment; + this.gender = gender; + this.level = level; + this.activityRegion = activityRegion; + this.facility = facility; + this.exercise = exercise; + this.status = baseStatus; + } } diff --git a/src/main/java/com/example/likelion12/dto/PostSocialringRequest.java b/src/main/java/com/example/likelion12/dto/PostSocialringRequest.java new file mode 100644 index 0000000..3e7394c --- /dev/null +++ b/src/main/java/com/example/likelion12/dto/PostSocialringRequest.java @@ -0,0 +1,25 @@ +package com.example.likelion12.dto; + +import com.example.likelion12.domain.base.BaseGender; +import com.example.likelion12.domain.base.BaseLevel; +import lombok.AllArgsConstructor; +import lombok.Getter; + +import java.time.LocalDate; + +@Getter +@AllArgsConstructor +public class PostSocialringRequest { + private String socialringName; + private String socialringImg; + private long activityRegionId; + private long facilityId; + private long exerciseId; + private int totalRecruits; + private LocalDate socialringDate; + private int socialringCost; + private String comment; + private String commentSimple; + private BaseGender gender; + private BaseLevel level; +} diff --git a/src/main/java/com/example/likelion12/dto/PostSocialringResponse.java b/src/main/java/com/example/likelion12/dto/PostSocialringResponse.java new file mode 100644 index 0000000..a986b24 --- /dev/null +++ b/src/main/java/com/example/likelion12/dto/PostSocialringResponse.java @@ -0,0 +1,10 @@ +package com.example.likelion12.dto; + +import lombok.AllArgsConstructor; +import lombok.Getter; + +@Getter +@AllArgsConstructor +public class PostSocialringResponse { + private long socialringId; +} diff --git a/src/main/java/com/example/likelion12/repository/MembersSocialringRepository.java b/src/main/java/com/example/likelion12/repository/MembersSocialringRepository.java new file mode 100644 index 0000000..70a693a --- /dev/null +++ b/src/main/java/com/example/likelion12/repository/MembersSocialringRepository.java @@ -0,0 +1,7 @@ +package com.example.likelion12.repository; + +import com.example.likelion12.domain.MemberSocialring; +import org.springframework.data.jpa.repository.JpaRepository; + +public interface MembersSocialringRepository extends JpaRepository { +} diff --git a/src/main/java/com/example/likelion12/repository/SocialringRepository.java b/src/main/java/com/example/likelion12/repository/SocialringRepository.java new file mode 100644 index 0000000..303ffd1 --- /dev/null +++ b/src/main/java/com/example/likelion12/repository/SocialringRepository.java @@ -0,0 +1,9 @@ +package com.example.likelion12.repository; + + +import com.example.likelion12.domain.Socialring; +import org.springframework.data.jpa.repository.JpaRepository; + +public interface SocialringRepository extends JpaRepository { + //Optional findBySocialringIdAndStatus(Long socialringId, BaseStatus status); +} diff --git a/src/main/java/com/example/likelion12/service/MemberSocialringService.java b/src/main/java/com/example/likelion12/service/MemberSocialringService.java new file mode 100644 index 0000000..11d4c8f --- /dev/null +++ b/src/main/java/com/example/likelion12/service/MemberSocialringService.java @@ -0,0 +1,29 @@ +package com.example.likelion12.service; + +import com.example.likelion12.domain.*; +import com.example.likelion12.domain.base.BaseRole; +import com.example.likelion12.domain.base.BaseStatus; +import com.example.likelion12.repository.MembersSocialringRepository; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; + +@Slf4j +@Service +@RequiredArgsConstructor +@Transactional(readOnly = true) +public class MemberSocialringService { + + private final MembersSocialringRepository membersSocialringRepository; + + /** + * 소셜링 등록 시 소셜링 만든 사람이 CAPTAIN 이 되도록 + */ + @Transactional + public void createMemberSocialring(Member member, Socialring socialring){ + log.info("[MemberSocialringService.createMemberSocialring]"); + MemberSocialring memberSocialring = new MemberSocialring(BaseRole.CAPTAIN,socialring,member,BaseStatus.ACTIVE); + membersSocialringRepository.save(memberSocialring); + } +} diff --git a/src/main/java/com/example/likelion12/service/SocialringService.java b/src/main/java/com/example/likelion12/service/SocialringService.java new file mode 100644 index 0000000..10a09d7 --- /dev/null +++ b/src/main/java/com/example/likelion12/service/SocialringService.java @@ -0,0 +1,69 @@ +package com.example.likelion12.service; + +import com.example.likelion12.common.exception.ActivityRegionException; +import com.example.likelion12.common.exception.ExerciseException; +import com.example.likelion12.common.exception.FacilityException; +import com.example.likelion12.common.exception.MemberException; +import com.example.likelion12.domain.*; +import com.example.likelion12.domain.base.BaseGender; +import com.example.likelion12.domain.base.BaseLevel; +import com.example.likelion12.domain.base.BaseStatus; +import com.example.likelion12.dto.PostSocialringRequest; +import com.example.likelion12.dto.PostSocialringResponse; +import com.example.likelion12.repository.*; +import lombok.RequiredArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; + +import java.time.LocalDate; + +import static com.example.likelion12.common.response.status.BaseExceptionResponseStatus.*; + +@Slf4j +@Service +@RequiredArgsConstructor +public class SocialringService { + private final SocialringRepository socialringRepository; + private final MemberRepository memberRepository; + private final FacilityRepository facilityRepository; + private final ExerciseRepository exerciseRepository; + private final MemberSocialringService memberSocialringService; + private final ActivityRegionRepository activityRegionRepository; + + //소셜링등록 + @Transactional + public PostSocialringResponse createSocialring(Long memberId, PostSocialringRequest postSocialringRequest) { + log.info("[SocialringService.createSocialring]"); + Member member = memberRepository.findByMemberIdAndStatus(memberId, BaseStatus.ACTIVE) + .orElseThrow(() -> new MemberException(CANNOT_FOUND_MEMBER)); + + String socialringName = postSocialringRequest.getSocialringName(); + String socialringImg = postSocialringRequest.getSocialringImg(); + long activityRegionId = postSocialringRequest.getActivityRegionId(); + long facilityId = postSocialringRequest.getFacilityId(); + long exerciseId = postSocialringRequest.getExerciseId(); + int totalRecruits = postSocialringRequest.getTotalRecruits(); + LocalDate socialringDate = postSocialringRequest.getSocialringDate(); + int socialringCost = postSocialringRequest.getSocialringCost(); + String comment = postSocialringRequest.getComment(); + String commentSimple = postSocialringRequest.getCommentSimple(); + BaseGender gender = postSocialringRequest.getGender(); + BaseLevel level = postSocialringRequest.getLevel(); + + ActivityRegion activityRegion = activityRegionRepository.findByActivityRegionIdAndStatus(activityRegionId, BaseStatus.ACTIVE) + .orElseThrow(()-> new ActivityRegionException(CANNOT_FOUND_ACTIVITYREGION)); + Facility facility = facilityRepository.findByFacilityIdAndStatus(facilityId, BaseStatus.ACTIVE) + .orElseThrow(()-> new FacilityException(CANOOT_FOUND_FACILITY)); + Exercise exercise = exerciseRepository.findByExerciseIdAndStatus(exerciseId,BaseStatus.ACTIVE) + .orElseThrow(()-> new ExerciseException(CANNOT_FOUND_EXERCISE)); + + Socialring socialring = new Socialring(socialringName,socialringImg,totalRecruits,socialringDate,socialringCost,comment,commentSimple, + gender,level,activityRegion,facility, exercise, BaseStatus.ACTIVE); + socialringRepository.save(socialring); + + //소셜링을 만든 사람이 CAPTAIN 이 되도록 + memberSocialringService.createMemberSocialring(member,socialring); + return new PostSocialringResponse(socialring.getSocialringId()); + } +} From 06273ccbb08031364ca9d77e9c29849bf21d9be1 Mon Sep 17 00:00:00 2001 From: hd0rable Date: Thu, 1 Aug 2024 18:05:52 +0900 Subject: [PATCH 3/4] =?UTF-8?q?refator=20:=20=EB=A9=A4=EB=B2=84=EC=86=8C?= =?UTF-8?q?=EC=85=9C=EB=A7=81=20=EB=A0=88=ED=8F=AC=EC=A7=80=ED=86=A0?= =?UTF-8?q?=EB=A6=AC=ED=8C=8C=EC=9D=BC=20=EC=9D=B4=EB=A6=84=20=EC=88=98?= =?UTF-8?q?=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...lringRepository.java => MemberSocialringRepository.java} | 2 +- .../example/likelion12/service/MemberSocialringService.java | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) rename src/main/java/com/example/likelion12/repository/{MembersSocialringRepository.java => MemberSocialringRepository.java} (63%) diff --git a/src/main/java/com/example/likelion12/repository/MembersSocialringRepository.java b/src/main/java/com/example/likelion12/repository/MemberSocialringRepository.java similarity index 63% rename from src/main/java/com/example/likelion12/repository/MembersSocialringRepository.java rename to src/main/java/com/example/likelion12/repository/MemberSocialringRepository.java index 70a693a..601e0d1 100644 --- a/src/main/java/com/example/likelion12/repository/MembersSocialringRepository.java +++ b/src/main/java/com/example/likelion12/repository/MemberSocialringRepository.java @@ -3,5 +3,5 @@ import com.example.likelion12.domain.MemberSocialring; import org.springframework.data.jpa.repository.JpaRepository; -public interface MembersSocialringRepository extends JpaRepository { +public interface MemberSocialringRepository extends JpaRepository { } diff --git a/src/main/java/com/example/likelion12/service/MemberSocialringService.java b/src/main/java/com/example/likelion12/service/MemberSocialringService.java index 11d4c8f..e994da3 100644 --- a/src/main/java/com/example/likelion12/service/MemberSocialringService.java +++ b/src/main/java/com/example/likelion12/service/MemberSocialringService.java @@ -3,7 +3,7 @@ import com.example.likelion12.domain.*; import com.example.likelion12.domain.base.BaseRole; import com.example.likelion12.domain.base.BaseStatus; -import com.example.likelion12.repository.MembersSocialringRepository; +import com.example.likelion12.repository.MemberSocialringRepository; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; import org.springframework.stereotype.Service; @@ -15,7 +15,7 @@ @Transactional(readOnly = true) public class MemberSocialringService { - private final MembersSocialringRepository membersSocialringRepository; + private final MemberSocialringRepository memberSocialringRepository; /** * 소셜링 등록 시 소셜링 만든 사람이 CAPTAIN 이 되도록 @@ -24,6 +24,6 @@ public class MemberSocialringService { public void createMemberSocialring(Member member, Socialring socialring){ log.info("[MemberSocialringService.createMemberSocialring]"); MemberSocialring memberSocialring = new MemberSocialring(BaseRole.CAPTAIN,socialring,member,BaseStatus.ACTIVE); - membersSocialringRepository.save(memberSocialring); + memberSocialringRepository.save(memberSocialring); } } From 8c56a6d39fc60eacaf20cb42d678560bfa8f3ead Mon Sep 17 00:00:00 2001 From: hd0rable Date: Thu, 1 Aug 2024 18:10:11 +0900 Subject: [PATCH 4/4] =?UTF-8?q?feat=20:=20=EC=86=8C=EC=85=9C=EB=A7=81=20?= =?UTF-8?q?=EC=98=88=EC=99=B8=20=ED=81=B4=EB=9E=98=EC=8A=A4=20=EC=9E=91?= =?UTF-8?q?=EC=84=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../common/exception/SocialringException.java | 19 ++++++++++++++++ .../SocialringExceptionControllerAdvice.java | 22 +++++++++++++++++++ 2 files changed, 41 insertions(+) create mode 100644 src/main/java/com/example/likelion12/common/exception/SocialringException.java create mode 100644 src/main/java/com/example/likelion12/common/exception_handler/SocialringExceptionControllerAdvice.java diff --git a/src/main/java/com/example/likelion12/common/exception/SocialringException.java b/src/main/java/com/example/likelion12/common/exception/SocialringException.java new file mode 100644 index 0000000..59d2b5f --- /dev/null +++ b/src/main/java/com/example/likelion12/common/exception/SocialringException.java @@ -0,0 +1,19 @@ +package com.example.likelion12.common.exception; + +import com.example.likelion12.common.response.status.ResponseStatus; +import lombok.Getter; + +@Getter +public class SocialringException extends RuntimeException{ + private final ResponseStatus exceptionStatus; + + public SocialringException(ResponseStatus exceptionStatus) { + super(exceptionStatus.getMessage()); + this.exceptionStatus = exceptionStatus; + } + + public SocialringException(ResponseStatus exceptionStatus, String message) { + super(message); + this.exceptionStatus = exceptionStatus; + } +} diff --git a/src/main/java/com/example/likelion12/common/exception_handler/SocialringExceptionControllerAdvice.java b/src/main/java/com/example/likelion12/common/exception_handler/SocialringExceptionControllerAdvice.java new file mode 100644 index 0000000..8ca6572 --- /dev/null +++ b/src/main/java/com/example/likelion12/common/exception_handler/SocialringExceptionControllerAdvice.java @@ -0,0 +1,22 @@ +package com.example.likelion12.common.exception_handler; + +import com.example.likelion12.common.exception.SocialringException; +import com.example.likelion12.common.response.BaseErrorResponse; +import jakarta.annotation.Priority; +import lombok.extern.slf4j.Slf4j; +import org.springframework.http.HttpStatus; +import org.springframework.web.bind.annotation.ExceptionHandler; +import org.springframework.web.bind.annotation.ResponseStatus; +import org.springframework.web.bind.annotation.RestControllerAdvice; + +@Slf4j +@Priority(0) +@RestControllerAdvice +public class SocialringExceptionControllerAdvice { + @ResponseStatus(HttpStatus.BAD_REQUEST) + @ExceptionHandler(SocialringException.class) + public BaseErrorResponse handle_SocialringException(SocialringException e) { + log.error("[handle_SocialringException]", e); + return new BaseErrorResponse(e.getExceptionStatus(), e.getMessage()); + } +}