-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #38 from SWM-Flash/integration
�문제 단건 조회 응답에 클라이밍장 이름 추가
- Loading branch information
Showing
24 changed files
with
366 additions
and
84 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
src/main/java/com/first/flash/climbing/gym/application/ClimbingGymEventHandler.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package com.first.flash.climbing.gym.application; | ||
|
||
import com.first.flash.climbing.gym.domian.ClimbingGymIdConfirmRequestedEvent; | ||
import lombok.RequiredArgsConstructor; | ||
import org.springframework.context.event.EventListener; | ||
import org.springframework.stereotype.Component; | ||
import org.springframework.transaction.annotation.Transactional; | ||
|
||
@Component | ||
@RequiredArgsConstructor | ||
public class ClimbingGymEventHandler { | ||
|
||
private final ClimbingGymService gymService; | ||
|
||
@EventListener | ||
@Transactional | ||
public void confirmGymId(final ClimbingGymIdConfirmRequestedEvent event) { | ||
gymService.findClimbingGymById(event.getGymId()); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 16 additions & 0 deletions
16
src/main/java/com/first/flash/climbing/gym/domian/ClimbingGymIdConfirmRequestedEvent.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package com.first.flash.climbing.gym.domian; | ||
|
||
import com.first.flash.global.event.Event; | ||
import lombok.AllArgsConstructor; | ||
import lombok.Getter; | ||
|
||
@Getter | ||
@AllArgsConstructor | ||
public class ClimbingGymIdConfirmRequestedEvent extends Event { | ||
|
||
private final Long gymId; | ||
|
||
public static ClimbingGymIdConfirmRequestedEvent of(final Long gymId) { | ||
return new ClimbingGymIdConfirmRequestedEvent(gymId); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
.../com/first/flash/climbing/gym/exception/exceptions/DuplicateDifficultyLevelException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package com.first.flash.climbing.gym.exception.exceptions; | ||
|
||
public class DuplicateDifficultyLevelException extends RuntimeException { | ||
|
||
public DuplicateDifficultyLevelException(final Integer difficultyLevel) { | ||
super(String.format("난이도 레벨이 중복되었습니다: %d", difficultyLevel)); | ||
} | ||
} |
8 changes: 8 additions & 0 deletions
8
...a/com/first/flash/climbing/gym/exception/exceptions/DuplicateDifficultyNameException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package com.first.flash.climbing.gym.exception.exceptions; | ||
|
||
public class DuplicateDifficultyNameException extends RuntimeException { | ||
|
||
public DuplicateDifficultyNameException(final String difficultyName) { | ||
super(String.format("난이도 이름이 중복되었습니다: %s", difficultyName)); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.