Skip to content

Commit

Permalink
Merge pull request #20 from depromeet/feat/LS-6
Browse files Browse the repository at this point in the history
Feat/ls 6
  • Loading branch information
clean2001 authored Jul 10, 2024
2 parents 468c916 + 63f5aa4 commit 9dfe21e
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ private void setHttp(HttpSecurity http) throws Exception {
.requestMatchers(new AntPathRequestMatcher("/api/auth/oauth2/google")).permitAll()
.requestMatchers(new AntPathRequestMatcher("/api/test")).permitAll()
.requestMatchers(new AntPathRequestMatcher("/api/auth/oauth2/kakao")).permitAll()
.requestMatchers(new AntPathRequestMatcher("/api/auth/test")).permitAll()
.anyRequest().authenticated()
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,10 @@
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.layer.domain.auth.controller.dto.*;
import org.layer.domain.auth.service.AuthService;
import org.layer.domain.auth.service.dto.SignInServiceResponse;
import org.layer.domain.auth.service.dto.SignUpServiceResponse;
import org.layer.domain.member.repository.MemberRepository;
import org.layer.oauth.service.GoogleService;
import org.layer.oauth.service.KakaoService;
import org.springframework.http.HttpStatus;
Expand All @@ -13,7 +15,7 @@
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
import org.layer.domain.auth.service.AuthService;

@Slf4j
@RequiredArgsConstructor
@RequestMapping("/api/auth")
Expand All @@ -22,6 +24,7 @@ public class AuthController {
private final AuthService authService;
private final GoogleService googleService;
private final KakaoService kakaoService;
private final MemberRepository memberRepository;

// 로그인
@PostMapping("/sign-in")
Expand Down
Empty file removed layer-domain/build.gradle
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import jakarta.persistence.GeneratedValue;
import jakarta.persistence.GenerationType;
import jakarta.persistence.Id;
import jakarta.validation.Valid;
import jakarta.validation.constraints.NotNull;
import lombok.AccessLevel;
import lombok.Builder;
Expand All @@ -32,10 +33,12 @@ public class Member {
@Enumerated(value = EnumType.STRING)
private MemberRole memberRole;

@Valid
@NotNull
@Enumerated(value = EnumType.STRING)
private SocialType socialType;

@Valid
@NotNull
private String socialId;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,4 @@

public interface MemberRepository extends JpaRepository<Member, Long> {
Optional<Member> findBySocialIdAndSocialType(@NotNull String socialId, @NotNull SocialType socialType);

}

0 comments on commit 9dfe21e

Please sign in to comment.