Skip to content

Commit

Permalink
Refact/#335 notification tag (#336)
Browse files Browse the repository at this point in the history
* [REFACT] `NotificationTag` Enum Value 변경

* [REFACT] flyway 적용
  • Loading branch information
tidavid1 authored Mar 23, 2024
1 parent c52b702 commit be71627
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ public static Notification newRequestArrivalNotification(User user) {
}

public static Notification newMatchingSuccessNotification(User user, Project project) {
return new Notification(NotificationTag.MATCHING_SUCCEEDED,
return new Notification(NotificationTag.MATCHING_SUCCESS,
NotificationMessage.MATCHING_SUCCESS_MESSAGE.getMessage(), user, project);
}

Expand All @@ -127,7 +127,7 @@ public static Notification newMatchingFailedNotification(User user, Project proj
}

private NotificationTag validateNotificationTag(NotificationTag notificationTag) {
if (!notificationTag.equals(NotificationTag.MATCHING_SUCCEEDED) && !notificationTag.equals(
if (!notificationTag.equals(NotificationTag.MATCHING_SUCCESS) && !notificationTag.equals(
NotificationTag.MATCHING_FAILED)) {
throw new NotificationException(ErrorCode400.NOTIFICATION_TAG_SHOULD_LIKE_MATCHING);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ public enum NotificationTag {
ACHIEVEMENT,
REQUEST_ARRIVAL,
MATCHING_FINISHED,
MATCHING_SUCCEEDED,
MATCHING_SUCCESS,
MATCHING_FAILED,
REVIEW_REQUEST,
;
Expand Down
2 changes: 2 additions & 0 deletions src/main/resources/db/migration/V5_notification_tag.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
alter table user_tb modify region enum ('JONGNO', 'JUNG', 'YONGSAN', 'SEONGDONG', 'GWANGJIN', 'DONGDAEMUN', 'JUNGNANG', 'SEONGBUK', 'GANGBUK', 'DOBONG', 'NOWON', 'EUNPYEONG', 'SEODAEMUN', 'MAPO', 'YANGCHEON', 'GANGSEO', 'GURO', 'GEUMCHEON', 'YEONGDEUNGPO', 'DONGJAK', 'GWANAK', 'SEOCHO', 'GANGNAM', 'SONGPA', 'GANGDONG', 'BUNDANG') null;
alter table notification_tb modify tag enum ('ACHIEVEMENT', 'REQUEST_ARRIVAL', 'MATCHING_FINISHED', 'MATCHING_SUCCESS', 'MATCHING_FAILED', 'REVIEW_REQUEST') null;

0 comments on commit be71627

Please sign in to comment.