-
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] #97 - Notification 관련 API & View 구현 및 수정
- Loading branch information
Showing
18 changed files
with
427 additions
and
156 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
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
12 changes: 12 additions & 0 deletions
12
Treehouse/Treehouse/Domain/Entities/Notification/CheckNotificationsResponseEntity.swift
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,12 @@ | ||
// | ||
// CheckNotificationsResponseEntity.swift | ||
// Treehouse | ||
// | ||
// Created by ParkJunHyuk on 8/7/24. | ||
// | ||
|
||
import Foundation | ||
|
||
struct CheckNotificationsResponseEntity: Decodable { | ||
let notificationId: Int | ||
} |
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
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
24 changes: 24 additions & 0 deletions
24
Treehouse/Treehouse/Domain/UseCases/Notification/ReadNotificationUseCase.swift
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,24 @@ | ||
// | ||
// CheckNotificationUseCase.swift | ||
// Treehouse | ||
// | ||
// Created by 윤영서 on 7/10/24. | ||
// | ||
|
||
import Foundation | ||
|
||
protocol GetReadNotificationUseCaseProtocol { | ||
func execute() async -> Result<ReadNotificationResponseEntity, NetworkError> | ||
} | ||
|
||
final class ReadNotificationUseCase: GetReadNotificationUseCaseProtocol { | ||
private let repository: NotificationRepositoryProtocol | ||
|
||
init(repository: NotificationRepositoryProtocol) { | ||
self.repository = repository | ||
} | ||
|
||
func execute() async -> Result<ReadNotificationResponseEntity, NetworkError> { | ||
return await repository.getReadNotification() | ||
} | ||
} |
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: 0 additions & 16 deletions
16
Treehouse/Treehouse/Network/Notification/DTO/Response/GetCheckNotificationsResponseDTO.swift
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.