diff --git a/build.gradle b/build.gradle index 314d911..465f823 100644 --- a/build.gradle +++ b/build.gradle @@ -44,7 +44,7 @@ dependencies { implementation 'org.springframework.boot:spring-boot-starter-validation' // ModelMapper 추가 - implementation 'org.modelmapper:modelmapper:3.1.1' + implementation 'org.modelmapper:modelmapper:3.0.0' // MyBatis 추가 implementation 'org.mybatis.spring.boot:mybatis-spring-boot-starter:3.0.3' diff --git a/src/main/java/com/bio/bio_backend/domain/user/member/controller/MemberController.java b/src/main/java/com/bio/bio_backend/domain/user/member/controller/MemberController.java index 2c1c066..47de88e 100644 --- a/src/main/java/com/bio/bio_backend/domain/user/member/controller/MemberController.java +++ b/src/main/java/com/bio/bio_backend/domain/user/member/controller/MemberController.java @@ -36,6 +36,10 @@ public class MemberController { private final BCryptPasswordEncoder bCryptPasswordEncoder; + @GetMapping("/join") + public ResponseEntity createMember1() { + return ResponseEntity.status(HttpStatus.CREATED).body("test"); + } @PostMapping("/join") public ResponseEntity createMember(@RequestBody @Valid CreateMemberRequestDTO requestDto) { diff --git a/src/main/java/com/bio/bio_backend/global/config/AppConfig.java b/src/main/java/com/bio/bio_backend/global/config/AppConfig.java index 0b22fb7..098924a 100644 --- a/src/main/java/com/bio/bio_backend/global/config/AppConfig.java +++ b/src/main/java/com/bio/bio_backend/global/config/AppConfig.java @@ -1,8 +1,15 @@ package com.bio.bio_backend.global.config; +import org.modelmapper.ModelMapper; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder; +import org.springframework.web.cors.CorsConfiguration; + +import org.springframework.context.annotation.Bean; +import org.springframework.web.cors.CorsConfiguration; +import org.springframework.web.cors.CorsConfigurationSource; +import org.springframework.web.cors.UrlBasedCorsConfigurationSource; @Configuration public class AppConfig { @@ -11,4 +18,9 @@ public class AppConfig { public BCryptPasswordEncoder bCryptPasswordEncoder() { return new BCryptPasswordEncoder(); } + + @Bean + public ModelMapper modelMapper() { + return new ModelMapper(); + } } \ No newline at end of file