-
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.
* [FEAT] Notification 알림 확인 API 구현 * [FEAT] Swagger 구현
- Loading branch information
Showing
8 changed files
with
71 additions
and
0 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
9 changes: 9 additions & 0 deletions
9
.../java/io/oeid/mogakgo/core/properties/swagger/error/SwaggerNotificationErrorExamples.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,9 @@ | ||
package io.oeid.mogakgo.core.properties.swagger.error; | ||
|
||
public class SwaggerNotificationErrorExamples { | ||
|
||
public static final String NOTIFICATION_FCM_TOKEN_NOT_FOUND = "{\"timestamp\":\"2024-02-17T10:07:31.404Z\",\"statusCode\":404,\"code\":\"E060301\",\"message\":\"해당 유저의 FCM 토큰이 존재하지 않습니다.\"}"; | ||
public static final String NOTIFICATION_NOT_FOUND = "{\"timestamp\":\"2024-02-17T10:07:31.404Z\",\"statusCode\":404,\"code\":\"E060302\",\"message\":\"해당 알림이 존재하지 않습니다.\"}"; | ||
private SwaggerNotificationErrorExamples() { | ||
} | ||
} |
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
.../java/io/oeid/mogakgo/domain/notification/application/dto/res/NotificationCheckedRes.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 io.oeid.mogakgo.domain.notification.application.dto.res; | ||
|
||
import io.swagger.v3.oas.annotations.media.Schema; | ||
import lombok.AllArgsConstructor; | ||
import lombok.Getter; | ||
import lombok.NoArgsConstructor; | ||
|
||
@Schema(description = "알림 확인 응답") | ||
@Getter | ||
@AllArgsConstructor | ||
@NoArgsConstructor | ||
public class NotificationCheckedRes { | ||
|
||
@Schema(description = "알림 ID", example = "1", implementation = Long.class) | ||
private Long notificationId; | ||
} |
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
3 changes: 3 additions & 0 deletions
3
...in/java/io/oeid/mogakgo/domain/notification/infrastructure/NotificationJpaRepository.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 |
---|---|---|
@@ -1,11 +1,14 @@ | ||
package io.oeid.mogakgo.domain.notification.infrastructure; | ||
|
||
import io.oeid.mogakgo.domain.notification.domain.Notification; | ||
import io.oeid.mogakgo.domain.user.domain.User; | ||
import java.util.Optional; | ||
import org.springframework.data.jpa.repository.JpaRepository; | ||
import org.springframework.stereotype.Repository; | ||
|
||
@Repository | ||
public interface NotificationJpaRepository extends JpaRepository<Notification, Long>, | ||
NotificationCustomRepository { | ||
|
||
Optional<Notification> findByIdAndReceiver(Long id, User receiver); | ||
} |
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