From c254c10cf6784bf4db9ba81178b1e69b9d7e9fae Mon Sep 17 00:00:00 2001 From: p2glet Date: Tue, 21 Apr 2026 21:22:06 +0900 Subject: [PATCH 1/4] =?UTF-8?q?fix/#319:=20API=20=EB=8F=84=EB=A9=94?= =?UTF-8?q?=EC=9D=B8=20=EC=88=98=EC=A0=95=20set-read=20=EC=A0=9C=EC=99=B8?= =?UTF-8?q?=ED=95=9C=20=EC=95=8C=EB=9E=8C=EA=B4=80=EB=A0=A8=20API=20?= =?UTF-8?q?=EB=8F=84=EB=A9=94=EC=9D=B8=20=EC=A3=BC=EC=86=8C=EB=A5=BC=20v1-?= =?UTF-8?q?>v2=EB=A1=9C=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- MLS/Data/Data/Network/Endpoints/AlarmEndPoint.swift | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/MLS/Data/Data/Network/Endpoints/AlarmEndPoint.swift b/MLS/Data/Data/Network/Endpoints/AlarmEndPoint.swift index 6a331b6d..3cf91795 100644 --- a/MLS/Data/Data/Network/Endpoints/AlarmEndPoint.swift +++ b/MLS/Data/Data/Network/Endpoints/AlarmEndPoint.swift @@ -6,7 +6,7 @@ public enum AlarmEndPoint { public static func fetchPatchNotes(query: Encodable) -> ResponsableEndPoint { .init( baseURL: base, - path: "/api/v1/alrim/list/patch-notes", + path: "/api/v2/alrim/list/patch-notes", method: .GET, query: query ) @@ -15,7 +15,7 @@ public enum AlarmEndPoint { public static func fetchNotices(query: Encodable) -> ResponsableEndPoint { .init( baseURL: base, - path: "/api/v1/alrim/list/notices", + path: "/api/v2/alrim/list/notices", method: .GET, query: query ) @@ -24,7 +24,7 @@ public enum AlarmEndPoint { public static func fetchOutdatedEvents(query: Encodable) -> ResponsableEndPoint { .init( baseURL: base, - path: "/api/v1/alrim/list/events/outdated", + path: "/api/v2/alrim/list/events/outdated", method: .GET, query: query ) @@ -33,7 +33,7 @@ public enum AlarmEndPoint { public static func fetchOngoingEvents(query: Encodable) -> ResponsableEndPoint { .init( baseURL: base, - path: "/api/v1/alrim/list/events/ongoing", + path: "/api/v2/alrim/list/events/ongoing", method: .GET, query: query ) @@ -42,7 +42,7 @@ public enum AlarmEndPoint { public static func fetchAll(query: Encodable) -> ResponsableEndPoint { .init( baseURL: base, - path: "/api/v1/alrim/all", + path: "/api/v2/alrim/all", method: .GET, query: query ) From 1af18983bce03341e97bba02221bc3ca6338ba80 Mon Sep 17 00:00:00 2001 From: p2glet Date: Wed, 22 Apr 2026 15:21:38 +0900 Subject: [PATCH 2/4] =?UTF-8?q?fix/#319:=20=EA=B3=B5=EC=A7=80=EC=82=AC?= =?UTF-8?q?=ED=95=AD=20/=20=ED=8C=A8=EC=B9=98=EB=85=B8=ED=8A=B8=20?= =?UTF-8?q?=ED=8E=98=EC=9D=B4=EC=A7=95=20=EC=88=98=EC=A0=95=20=ED=8E=98?= =?UTF-8?q?=EC=9D=B4=EC=A7=95=20=EC=8B=9C=20=EA=B8=B0=EC=A1=B4=20=EB=8D=B0?= =?UTF-8?q?=EC=9D=B4=ED=84=B0=EC=97=90=20=EB=8D=AE=EC=96=B4=EC=93=B0?= =?UTF-8?q?=EA=B8=B0=EA=B0=80=20=EC=95=84=EB=8B=8C=20=EC=B6=94=EA=B0=80=20?= =?UTF-8?q?=EB=90=98=EA=B3=A0=EC=9E=88=EB=8D=98=20=EC=9D=B4=EC=8A=88=20?= =?UTF-8?q?=ED=95=B4=EA=B2=B0=20+=20=EC=A7=84=ED=96=89=EC=A4=91=20?= =?UTF-8?q?=EC=9D=B4=EB=B2=A4=ED=8A=B8=20=ED=81=B4=EB=A6=AD=20=EC=9D=B4?= =?UTF-8?q?=EC=8A=88=EB=8A=94=20=ED=98=84=EC=9E=AC=20=ED=99=95=EC=9D=B8=20?= =?UTF-8?q?=EB=B6=88=EA=B0=80=EB=8A=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../DTO/AlarmDTO/AlarmResponseDTO.swift | 4 + .../Repository/AlarmAPIRepositoryImpl.swift | 12 +- .../Alarm/FetchAllAlarmUseCaseImpl.swift | 4 +- .../Alarm/FetchNoticesUseCaseImpl.swift | 4 +- .../Alarm/FetchOngoingEventsUseCaseImpl.swift | 4 +- .../FetchOutdatedEventsUseCaseImpl.swift | 4 +- .../Alarm/FetchPatchNotesUseCaseImpl.swift | 4 +- .../Entity/Alarm/AlarmResponse.swift | 8 +- .../Repository/AlarmAPIRepository.swift | 10 +- .../UseCase/Alarm/FetchAllAlarmUseCase.swift | 2 +- .../UseCase/Alarm/FetchNoticesUseCase.swift | 2 +- .../Alarm/FetchOngoingEventsUseCase.swift | 2 +- .../Alarm/FetchOutdatedEventsUseCase.swift | 2 +- .../Alarm/FetchPatchNotesUseCase.swift | 2 +- .../MyPageFeature.xcodeproj/project.pbxproj | 22 +-- .../Announcement/AnnouncementReactor.swift | 6 +- .../AnnouncementViewController.swift | 8 +- .../CustomerSupport/Event/EventReactor.swift | 8 +- .../Event/EventViewController.swift | 3 +- .../PatchNote/PatchNoteReactor.swift | 6 +- .../PatchNote/PatchNoteViewController.swift | 8 +- .../MyPageFeatureDemo/AppDelegate.swift | 148 ++++++++---------- .../Mock/MockLoginFactory.swift | 10 ++ .../MyPageFeatureDemo/ViewController.swift | 2 +- 24 files changed, 138 insertions(+), 147 deletions(-) create mode 100644 MLS/Presentation/MyPageFeature/MyPageFeatureDemo/Mock/MockLoginFactory.swift diff --git a/MLS/Data/Data/Network/DTO/AlarmDTO/AlarmResponseDTO.swift b/MLS/Data/Data/Network/DTO/AlarmDTO/AlarmResponseDTO.swift index c531c810..519a8084 100644 --- a/MLS/Data/Data/Network/DTO/AlarmDTO/AlarmResponseDTO.swift +++ b/MLS/Data/Data/Network/DTO/AlarmDTO/AlarmResponseDTO.swift @@ -32,6 +32,7 @@ public struct AlarmResponseDTO: Decodable { } public struct NormalContent: Decodable { + public let id: Int public let type: String public let title: String public let link: String @@ -50,6 +51,7 @@ public extension AlarmResponseDTO { switch content { case .normal(let normal): return AlarmResponse( + id: normal.id, type: normal.type, title: normal.title, link: normal.link, @@ -57,6 +59,7 @@ public extension AlarmResponseDTO { ) case .all(let all): return AlarmResponse( + id: all.alrim.id, type: all.alrim.type, title: all.alrim.title, link: all.alrim.link, @@ -72,6 +75,7 @@ public extension AlarmResponseDTO { switch content { case .all(let all): return AllAlarmResponse( + id: all.alrim.id, type: all.alrim.type, title: all.alrim.title, link: all.alrim.link, diff --git a/MLS/Data/Data/Repository/AlarmAPIRepositoryImpl.swift b/MLS/Data/Data/Repository/AlarmAPIRepositoryImpl.swift index 6e2763d7..ab98afde 100644 --- a/MLS/Data/Data/Repository/AlarmAPIRepositoryImpl.swift +++ b/MLS/Data/Data/Repository/AlarmAPIRepositoryImpl.swift @@ -13,31 +13,31 @@ public class AlarmAPIRepositoryImpl: AlarmAPIRepository { self.tokenInterceptor = interceptor } - public func fetchPatchNotes(cursor: String?, pageSize: Int) -> Observable> { + public func fetchPatchNotes(cursor: Int?, pageSize: Int) -> Observable> { let endpoint = AlarmEndPoint.fetchPatchNotes(query: AlarmQuery(cursor: cursor, pageSize: pageSize)) return provider.requestData(endPoint: endpoint, interceptor: tokenInterceptor) .map { $0.toAlarmDomain() } } - public func fetchNotices(cursor: String?, pageSize: Int) -> Observable> { + public func fetchNotices(cursor: Int?, pageSize: Int) -> Observable> { let endpoint = AlarmEndPoint.fetchNotices(query: AlarmQuery(cursor: cursor, pageSize: pageSize)) return provider.requestData(endPoint: endpoint, interceptor: tokenInterceptor) .map { $0.toAlarmDomain() } } - public func fetchOutdatedEvents(cursor: String?, pageSize: Int) -> Observable> { + public func fetchOutdatedEvents(cursor: Int?, pageSize: Int) -> Observable> { let endpoint = AlarmEndPoint.fetchOutdatedEvents(query: AlarmQuery(cursor: cursor, pageSize: pageSize)) return provider.requestData(endPoint: endpoint, interceptor: tokenInterceptor) .map { $0.toAlarmDomain() } } - public func fetchOngoingEvents(cursor: String?, pageSize: Int) -> Observable> { + public func fetchOngoingEvents(cursor: Int?, pageSize: Int) -> Observable> { let endpoint = AlarmEndPoint.fetchOngoingEvents(query: AlarmQuery(cursor: cursor, pageSize: pageSize)) return provider.requestData(endPoint: endpoint, interceptor: tokenInterceptor) .map { $0.toAlarmDomain() } } - public func fetchAll(cursor: String?, pageSize: Int) -> Observable> { + public func fetchAll(cursor: Int?, pageSize: Int) -> Observable> { let endpoint = AlarmEndPoint.fetchAll(query: AlarmQuery(cursor: cursor, pageSize: pageSize)) return provider.requestData(endPoint: endpoint, interceptor: tokenInterceptor) .map { $0.toAllAlarmDomain() } @@ -52,7 +52,7 @@ public class AlarmAPIRepositoryImpl: AlarmAPIRepository { private extension AlarmAPIRepositoryImpl { struct AlarmQuery: Encodable { - let cursor: String? + let cursor: Int? let pageSize: Int } diff --git a/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchAllAlarmUseCaseImpl.swift b/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchAllAlarmUseCaseImpl.swift index 47060dfb..9622cd52 100644 --- a/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchAllAlarmUseCaseImpl.swift +++ b/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchAllAlarmUseCaseImpl.swift @@ -11,7 +11,7 @@ public class FetchAllAlarmUseCaseImpl: FetchAllAlarmUseCase { self.repository = repository } - public func execute(cursor: String?, pageSize: Int) -> Observable> { - return repository.fetchAll(cursor: cursor, pageSize: pageSize) + public func execute(id: Int?, pageSize: Int) -> Observable> { + return repository.fetchAll(cursor: id, pageSize: pageSize) } } diff --git a/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchNoticesUseCaseImpl.swift b/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchNoticesUseCaseImpl.swift index 410913be..b464aeed 100644 --- a/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchNoticesUseCaseImpl.swift +++ b/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchNoticesUseCaseImpl.swift @@ -11,7 +11,7 @@ public class FetchNoticesUseCaseImpl: FetchNoticesUseCase { self.repository = repository } - public func execute(cursor: String?, pageSize: Int) -> Observable> { - return repository.fetchNotices(cursor: cursor, pageSize: pageSize) + public func execute(id: Int?, pageSize: Int) -> Observable> { + return repository.fetchNotices(cursor: id, pageSize: pageSize) } } diff --git a/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchOngoingEventsUseCaseImpl.swift b/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchOngoingEventsUseCaseImpl.swift index dd28aa8d..2a1c961f 100644 --- a/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchOngoingEventsUseCaseImpl.swift +++ b/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchOngoingEventsUseCaseImpl.swift @@ -11,7 +11,7 @@ public class FetchOngoingEventsUseCaseImpl: FetchOngoingEventsUseCase { self.repository = repository } - public func execute(cursor: String?, pageSize: Int) -> Observable> { - return repository.fetchOngoingEvents(cursor: cursor, pageSize: pageSize) + public func execute(id: Int?, pageSize: Int) -> Observable> { + return repository.fetchOngoingEvents(cursor: id, pageSize: pageSize) } } diff --git a/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchOutdatedEventsUseCaseImpl.swift b/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchOutdatedEventsUseCaseImpl.swift index f3571532..ba778aa4 100644 --- a/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchOutdatedEventsUseCaseImpl.swift +++ b/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchOutdatedEventsUseCaseImpl.swift @@ -11,7 +11,7 @@ public class FetchOutdatedEventsUseCaseImpl: FetchOutdatedEventsUseCase { self.repository = repository } - public func execute(cursor: String?, pageSize: Int) -> Observable> { - return repository.fetchOutdatedEvents(cursor: cursor, pageSize: pageSize) + public func execute(id: Int?, pageSize: Int) -> Observable> { + return repository.fetchOutdatedEvents(cursor: id, pageSize: pageSize) } } diff --git a/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchPatchNotesUseCaseImpl.swift b/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchPatchNotesUseCaseImpl.swift index 2817b0ef..122fa2ec 100644 --- a/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchPatchNotesUseCaseImpl.swift +++ b/MLS/Domain/Domain/UseCaseImpl/Alarm/FetchPatchNotesUseCaseImpl.swift @@ -11,7 +11,7 @@ public class FetchPatchNotesUseCaseImpl: FetchPatchNotesUseCase { self.repository = repository } - public func execute(cursor: String?, pageSize: Int) -> Observable> { - return repository.fetchPatchNotes(cursor: cursor, pageSize: pageSize) + public func execute(id: Int?, pageSize: Int) -> Observable> { + return repository.fetchPatchNotes(cursor: id, pageSize: pageSize) } } diff --git a/MLS/Domain/DomainInterface/Entity/Alarm/AlarmResponse.swift b/MLS/Domain/DomainInterface/Entity/Alarm/AlarmResponse.swift index 78b27ee3..0f486c35 100644 --- a/MLS/Domain/DomainInterface/Entity/Alarm/AlarmResponse.swift +++ b/MLS/Domain/DomainInterface/Entity/Alarm/AlarmResponse.swift @@ -1,12 +1,14 @@ import Foundation public struct AlarmResponse: Equatable { + public let id: Int public let type: String public let title: String public let link: String public let date: String - public init(type: String, title: String, link: String, date: String) { + public init(id: Int, type: String, title: String, link: String, date: String) { + self.id = id self.type = type self.title = title self.link = link @@ -15,13 +17,15 @@ public struct AlarmResponse: Equatable { } public struct AllAlarmResponse: Equatable { + public let id: Int public let type: String public let title: String public let link: String public let date: String public var alreadyRead: Bool - public init(type: String, title: String, link: String, date: String, alreadyRead: Bool) { + public init(id: Int, type: String, title: String, link: String, date: String, alreadyRead: Bool) { + self.id = id self.type = type self.title = title self.link = link diff --git a/MLS/Domain/DomainInterface/Repository/AlarmAPIRepository.swift b/MLS/Domain/DomainInterface/Repository/AlarmAPIRepository.swift index 4c3c303b..e5c975b0 100644 --- a/MLS/Domain/DomainInterface/Repository/AlarmAPIRepository.swift +++ b/MLS/Domain/DomainInterface/Repository/AlarmAPIRepository.swift @@ -3,15 +3,15 @@ import Foundation import RxSwift public protocol AlarmAPIRepository { - func fetchPatchNotes(cursor: String?, pageSize: Int) -> Observable> + func fetchPatchNotes(cursor: Int?, pageSize: Int) -> Observable> - func fetchNotices(cursor: String?, pageSize: Int) -> Observable> + func fetchNotices(cursor: Int?, pageSize: Int) -> Observable> - func fetchOutdatedEvents(cursor: String?, pageSize: Int) -> Observable> + func fetchOutdatedEvents(cursor: Int?, pageSize: Int) -> Observable> - func fetchOngoingEvents(cursor: String?, pageSize: Int) -> Observable> + func fetchOngoingEvents(cursor: Int?, pageSize: Int) -> Observable> - func fetchAll(cursor: String?, pageSize: Int) -> Observable> + func fetchAll(cursor: Int?, pageSize: Int) -> Observable> func setRead(alarmLink: String) -> Completable } diff --git a/MLS/Domain/DomainInterface/UseCase/Alarm/FetchAllAlarmUseCase.swift b/MLS/Domain/DomainInterface/UseCase/Alarm/FetchAllAlarmUseCase.swift index 41206233..b4dcccab 100644 --- a/MLS/Domain/DomainInterface/UseCase/Alarm/FetchAllAlarmUseCase.swift +++ b/MLS/Domain/DomainInterface/UseCase/Alarm/FetchAllAlarmUseCase.swift @@ -1,5 +1,5 @@ import RxSwift public protocol FetchAllAlarmUseCase { - func execute(cursor: String?, pageSize: Int) -> Observable> + func execute(id: Int?, pageSize: Int) -> Observable> } diff --git a/MLS/Domain/DomainInterface/UseCase/Alarm/FetchNoticesUseCase.swift b/MLS/Domain/DomainInterface/UseCase/Alarm/FetchNoticesUseCase.swift index f5d75581..3f2e85fb 100644 --- a/MLS/Domain/DomainInterface/UseCase/Alarm/FetchNoticesUseCase.swift +++ b/MLS/Domain/DomainInterface/UseCase/Alarm/FetchNoticesUseCase.swift @@ -1,5 +1,5 @@ import RxSwift public protocol FetchNoticesUseCase { - func execute(cursor: String?, pageSize: Int) -> Observable> + func execute(id: Int?, pageSize: Int) -> Observable> } diff --git a/MLS/Domain/DomainInterface/UseCase/Alarm/FetchOngoingEventsUseCase.swift b/MLS/Domain/DomainInterface/UseCase/Alarm/FetchOngoingEventsUseCase.swift index 80303048..d1ca0894 100644 --- a/MLS/Domain/DomainInterface/UseCase/Alarm/FetchOngoingEventsUseCase.swift +++ b/MLS/Domain/DomainInterface/UseCase/Alarm/FetchOngoingEventsUseCase.swift @@ -1,5 +1,5 @@ import RxSwift public protocol FetchOngoingEventsUseCase { - func execute(cursor: String?, pageSize: Int) -> Observable> + func execute(id: Int?, pageSize: Int) -> Observable> } diff --git a/MLS/Domain/DomainInterface/UseCase/Alarm/FetchOutdatedEventsUseCase.swift b/MLS/Domain/DomainInterface/UseCase/Alarm/FetchOutdatedEventsUseCase.swift index 959663ea..e322d2af 100644 --- a/MLS/Domain/DomainInterface/UseCase/Alarm/FetchOutdatedEventsUseCase.swift +++ b/MLS/Domain/DomainInterface/UseCase/Alarm/FetchOutdatedEventsUseCase.swift @@ -1,5 +1,5 @@ import RxSwift public protocol FetchOutdatedEventsUseCase { - func execute(cursor: String?, pageSize: Int) -> Observable> + func execute(id: Int?, pageSize: Int) -> Observable> } diff --git a/MLS/Domain/DomainInterface/UseCase/Alarm/FetchPatchNotesUseCase.swift b/MLS/Domain/DomainInterface/UseCase/Alarm/FetchPatchNotesUseCase.swift index 62d27587..2439fb39 100644 --- a/MLS/Domain/DomainInterface/UseCase/Alarm/FetchPatchNotesUseCase.swift +++ b/MLS/Domain/DomainInterface/UseCase/Alarm/FetchPatchNotesUseCase.swift @@ -1,5 +1,5 @@ import RxSwift public protocol FetchPatchNotesUseCase { - func execute(cursor: String?, pageSize: Int) -> Observable> + func execute(id: Int?, pageSize: Int) -> Observable> } diff --git a/MLS/Presentation/MyPageFeature/MyPageFeature.xcodeproj/project.pbxproj b/MLS/Presentation/MyPageFeature/MyPageFeature.xcodeproj/project.pbxproj index 77c3b916..dae3ecdd 100644 --- a/MLS/Presentation/MyPageFeature/MyPageFeature.xcodeproj/project.pbxproj +++ b/MLS/Presentation/MyPageFeature/MyPageFeature.xcodeproj/project.pbxproj @@ -27,10 +27,6 @@ 773A3F6F2E71736300F75B30 /* BaseFeature.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 773A3F6D2E71736300F75B30 /* BaseFeature.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 773A3F712E71736A00F75B30 /* BaseFeature.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 773A3F702E71736A00F75B30 /* BaseFeature.framework */; }; 773A42D02E717B8900F75B30 /* BaseFeature.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 773A42CF2E717B8900F75B30 /* BaseFeature.framework */; }; - 7746A7EF2E841C9C0046F603 /* Data.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7746A7EE2E841C9C0046F603 /* Data.framework */; }; - 7746A7F02E841C9C0046F603 /* Data.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 7746A7EE2E841C9C0046F603 /* Data.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; - 7746A7F22E841CEA0046F603 /* DataMock.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7746A7F12E841CEA0046F603 /* DataMock.framework */; }; - 7746A7F32E841CEA0046F603 /* DataMock.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 7746A7F12E841CEA0046F603 /* DataMock.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 7746ABAA2E84225A0046F603 /* Core.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7746ABA92E84225A0046F603 /* Core.framework */; }; 7746ABAB2E84225A0046F603 /* Core.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 7746ABA92E84225A0046F603 /* Core.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 7746ABAD2E84227A0046F603 /* DomainInterface.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7746ABAC2E84227A0046F603 /* DomainInterface.framework */; }; @@ -38,13 +34,11 @@ 7746ABB32E8425E00046F603 /* DesignSystem.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7746ABB22E8425E00046F603 /* DesignSystem.framework */; }; 7746ABB72E8427F80046F603 /* RxKeyboard in Frameworks */ = {isa = PBXBuildFile; productRef = 7746ABB62E8427F80046F603 /* RxKeyboard */; }; 775966F32EC30B3A00CC389B /* AuthFeatureInterface.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 775966F22EC30B3A00CC389B /* AuthFeatureInterface.framework */; }; - 776FEA342EA4D29B0039ACE2 /* AuthFeatureInterface.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 776FEA332EA4D29B0039ACE2 /* AuthFeatureInterface.framework */; }; - 776FEA352EA4D29B0039ACE2 /* AuthFeatureInterface.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 776FEA332EA4D29B0039ACE2 /* AuthFeatureInterface.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 777C28142E7D87B8000765F2 /* RxKeyboard in Frameworks */ = {isa = PBXBuildFile; productRef = 777C28132E7D87B8000765F2 /* RxKeyboard */; }; - 77BE55BA2E78596900522216 /* Domain.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 77BE55B82E78596900522216 /* Domain.framework */; }; - 77BE55BB2E78596900522216 /* Domain.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 77BE55B82E78596900522216 /* Domain.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 77BE55BC2E78596900522216 /* DomainInterface.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 77BE55B92E78596900522216 /* DomainInterface.framework */; }; 77BE55BD2E78596900522216 /* DomainInterface.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 77BE55B92E78596900522216 /* DomainInterface.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; + 77D0AD422F97DA78008B0C57 /* AuthFeatureInterface.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 77D0AD412F97DA78008B0C57 /* AuthFeatureInterface.framework */; }; + 77D0AD432F97DA78008B0C57 /* AuthFeatureInterface.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 77D0AD412F97DA78008B0C57 /* AuthFeatureInterface.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; D22195C52E83FA81001203D4 /* RxGesture in Frameworks */ = {isa = PBXBuildFile; productRef = D22195C42E83FA81001203D4 /* RxGesture */; }; D2DA8C322E798917009C53BA /* ReactorKit in Frameworks */ = {isa = PBXBuildFile; productRef = D2227A7C2E76A84A0095343A /* ReactorKit */; }; /* End PBXBuildFile section */ @@ -80,13 +74,10 @@ dstPath = ""; dstSubfolderSpec = 10; files = ( + 77D0AD432F97DA78008B0C57 /* AuthFeatureInterface.framework in Embed Frameworks */, 77BE55BD2E78596900522216 /* DomainInterface.framework in Embed Frameworks */, - 77BE55BB2E78596900522216 /* Domain.framework in Embed Frameworks */, - 7746A7F32E841CEA0046F603 /* DataMock.framework in Embed Frameworks */, - 776FEA352EA4D29B0039ACE2 /* AuthFeatureInterface.framework in Embed Frameworks */, 773A3F6F2E71736300F75B30 /* BaseFeature.framework in Embed Frameworks */, 773A3F6C2E71734600F75B30 /* DesignSystem.framework in Embed Frameworks */, - 7746A7F02E841C9C0046F603 /* Data.framework in Embed Frameworks */, 773A3F672E71731700F75B30 /* MyPageFeature.framework in Embed Frameworks */, 7746ABAB2E84225A0046F603 /* Core.framework in Embed Frameworks */, 773A3C002E7170A700F75B30 /* MyPageFeatureInterface.framework in Embed Frameworks */, @@ -113,6 +104,7 @@ 776FEA332EA4D29B0039ACE2 /* AuthFeatureInterface.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = AuthFeatureInterface.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 77BE55B82E78596900522216 /* Domain.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = Domain.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 77BE55B92E78596900522216 /* DomainInterface.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = DomainInterface.framework; sourceTree = BUILT_PRODUCTS_DIR; }; + 77D0AD412F97DA78008B0C57 /* AuthFeatureInterface.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = AuthFeatureInterface.framework; sourceTree = BUILT_PRODUCTS_DIR; }; D2227A762E76A7E70095343A /* Core.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = Core.framework; sourceTree = BUILT_PRODUCTS_DIR; }; /* End PBXFileReference section */ @@ -179,20 +171,17 @@ isa = PBXFrameworksBuildPhase; buildActionMask = 2147483647; files = ( - 7746A7EF2E841C9C0046F603 /* Data.framework in Frameworks */, D2DA8C322E798917009C53BA /* ReactorKit in Frameworks */, 77BE55BC2E78596900522216 /* DomainInterface.framework in Frameworks */, 773A3F6E2E71736300F75B30 /* BaseFeature.framework in Frameworks */, 773A3F6B2E71734600F75B30 /* DesignSystem.framework in Frameworks */, 7746ABB72E8427F80046F603 /* RxKeyboard in Frameworks */, 773A3F662E71731700F75B30 /* MyPageFeature.framework in Frameworks */, - 77BE55BA2E78596900522216 /* Domain.framework in Frameworks */, 7746ABB12E84245D0046F603 /* RxGesture in Frameworks */, + 77D0AD422F97DA78008B0C57 /* AuthFeatureInterface.framework in Frameworks */, 7746ABAA2E84225A0046F603 /* Core.framework in Frameworks */, 773A3BFC2E71701D00F75B30 /* RxSwift in Frameworks */, 773A3BFE2E71702300F75B30 /* SnapKit in Frameworks */, - 776FEA342EA4D29B0039ACE2 /* AuthFeatureInterface.framework in Frameworks */, - 7746A7F22E841CEA0046F603 /* DataMock.framework in Frameworks */, 773A3BFA2E71701D00F75B30 /* RxRelay in Frameworks */, 773A3BF82E71701D00F75B30 /* RxCocoa in Frameworks */, 773A3BFF2E7170A700F75B30 /* MyPageFeatureInterface.framework in Frameworks */, @@ -226,6 +215,7 @@ 773A3BF62E71701D00F75B30 /* Frameworks */ = { isa = PBXGroup; children = ( + 77D0AD412F97DA78008B0C57 /* AuthFeatureInterface.framework */, 775966F22EC30B3A00CC389B /* AuthFeatureInterface.framework */, 776FEA332EA4D29B0039ACE2 /* AuthFeatureInterface.framework */, 7746ABB22E8425E00046F603 /* DesignSystem.framework */, diff --git a/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Announcement/AnnouncementReactor.swift b/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Announcement/AnnouncementReactor.swift index cfaf96ec..ff7ee125 100644 --- a/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Announcement/AnnouncementReactor.swift +++ b/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Announcement/AnnouncementReactor.swift @@ -42,7 +42,7 @@ public final class AnnouncementReactor: Reactor { case .viewWillAppear: return .concat([ .just(.setLoading(true)), - fetchNoticesUseCase.execute(cursor: nil, pageSize: 20) + fetchNoticesUseCase.execute(id: nil, pageSize: 20) .map { paged in .setAlarms(paged.items, hasMore: paged.hasMore, reset: true) }, @@ -50,10 +50,10 @@ public final class AnnouncementReactor: Reactor { ]) case .loadMore: guard currentState.hasMore, !currentState.isLoading else { return .empty() } - let lastCursor = currentState.alarms.last?.date + let lastCursor = currentState.alarms.last?.id return .concat([ .just(.setLoading(true)), - fetchNoticesUseCase.execute(cursor: lastCursor, pageSize: 20) + fetchNoticesUseCase.execute(id: lastCursor, pageSize: 20) .map { paged in .setAlarms(paged.items, hasMore: paged.hasMore, reset: false) }, diff --git a/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Announcement/AnnouncementViewController.swift b/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Announcement/AnnouncementViewController.swift index 4261d67c..d7f8a2fd 100644 --- a/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Announcement/AnnouncementViewController.swift +++ b/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Announcement/AnnouncementViewController.swift @@ -50,8 +50,12 @@ extension AnnouncementViewController { .distinctUntilChanged() .withUnretained(self) .observe(on: MainScheduler.instance) - .bind(onNext: { owner, _ in - owner.createDetailItem(items: reactor.currentState.alarms) + .bind(onNext: { owner, items in + owner.mainView.detailItemStackView.arrangedSubviews.forEach { + owner.mainView.detailItemStackView.removeArrangedSubview($0) + $0.removeFromSuperview() + } + owner.createDetailItem(items: items) }) .disposed(by: disposeBag) } diff --git a/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Event/EventReactor.swift b/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Event/EventReactor.swift index 654c0dab..92b9ebce 100644 --- a/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Event/EventReactor.swift +++ b/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Event/EventReactor.swift @@ -45,8 +45,8 @@ public final class EventReactor: Reactor { switch action { case let .selectTab(index): let fetchObservable = (index == 0 - ? fetchOngoingEventsUseCase.execute(cursor: nil, pageSize: 20) - : fetchOutdatedEventsUseCase.execute(cursor: nil, pageSize: 20)) + ? fetchOngoingEventsUseCase.execute(id: nil, pageSize: 20) + : fetchOutdatedEventsUseCase.execute(id: nil, pageSize: 20)) .map { paged -> Mutation in .setAlarms(paged.items, hasMore: paged.hasMore, reset: true) } @@ -64,11 +64,11 @@ public final class EventReactor: Reactor { case .loadMore: guard currentState.hasMore, !currentState.isLoading else { return .empty() } - let lastCursor = currentState.alarms.last?.date + let lastCursor = currentState.alarms.last?.id return .concat([ .just(.setLoading(true)), - (currentState.selectedIndex == 0 ? fetchOngoingEventsUseCase.execute(cursor: lastCursor, pageSize: 20) : fetchOutdatedEventsUseCase.execute(cursor: lastCursor, pageSize: 20)) + (currentState.selectedIndex == 0 ? fetchOngoingEventsUseCase.execute(id: lastCursor, pageSize: 20) : fetchOutdatedEventsUseCase.execute(id: lastCursor, pageSize: 20)) .map { paged in .setAlarms(paged.items, hasMore: paged.hasMore, reset: false) }, diff --git a/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Event/EventViewController.swift b/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Event/EventViewController.swift index f49ec0cb..146c91c1 100644 --- a/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Event/EventViewController.swift +++ b/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/Event/EventViewController.swift @@ -32,8 +32,6 @@ final class EventViewController: CustomerSupportBaseViewController, View { mainView.menuStackView.addArrangedSubview(endedButton) mainView.setupSpacerView() - reactor?.action.onNext(.selectTab(0)) - guard let reactor = reactor else { return } mainView.menuStackView.arrangedSubviews .compactMap { $0 as? UIButton } @@ -49,6 +47,7 @@ final class EventViewController: CustomerSupportBaseViewController, View { // MARK: - Bind extension EventViewController { func bind(reactor: Reactor) { + reactor.action.onNext(.selectTab(0)) bindViewState(reactor: reactor) } diff --git a/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/PatchNote/PatchNoteReactor.swift b/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/PatchNote/PatchNoteReactor.swift index 465827d0..8aaa10c0 100644 --- a/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/PatchNote/PatchNoteReactor.swift +++ b/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/PatchNote/PatchNoteReactor.swift @@ -42,7 +42,7 @@ public final class PatchNoteReactor: Reactor { case .viewWillAppear: return .concat([ .just(.setLoading(true)), - fetchPatchNotesUseCase.execute(cursor: nil, pageSize: 20) + fetchPatchNotesUseCase.execute(id: nil, pageSize: 20) .map { paged in .setAlarms(paged.items, hasMore: paged.hasMore, reset: true) }, @@ -50,10 +50,10 @@ public final class PatchNoteReactor: Reactor { ]) case .loadMore: guard currentState.hasMore, !currentState.isLoading else { return .empty() } - let lastCursor = currentState.alarms.last?.date + let lastCursor = currentState.alarms.last?.id return .concat([ .just(.setLoading(true)), - fetchPatchNotesUseCase.execute(cursor: lastCursor, pageSize: 20) + fetchPatchNotesUseCase.execute(id: lastCursor, pageSize: 20) .map { paged in .setAlarms(paged.items, hasMore: paged.hasMore, reset: false) }, diff --git a/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/PatchNote/PatchNoteViewController.swift b/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/PatchNote/PatchNoteViewController.swift index 56397f22..3935c851 100644 --- a/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/PatchNote/PatchNoteViewController.swift +++ b/MLS/Presentation/MyPageFeature/MyPageFeature/CustomerSupport/PatchNote/PatchNoteViewController.swift @@ -50,8 +50,12 @@ extension PatchNoteViewController { .distinctUntilChanged() .withUnretained(self) .observe(on: MainScheduler.instance) - .bind(onNext: { owner, _ in - owner.createDetailItem(items: reactor.currentState.alarms) + .bind(onNext: { owner, alarms in + owner.mainView.detailItemStackView.arrangedSubviews.forEach { + owner.mainView.detailItemStackView.removeArrangedSubview($0) + $0.removeFromSuperview() + } + owner.createDetailItem(items: alarms) }) .disposed(by: disposeBag) } diff --git a/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/AppDelegate.swift b/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/AppDelegate.swift index a643b7e0..48dd0f63 100644 --- a/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/AppDelegate.swift +++ b/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/AppDelegate.swift @@ -5,10 +5,7 @@ import UIKit import AuthFeatureInterface import BaseFeature import Core -import Data -import DataMock import DesignSystem -import Domain import DomainInterface import MyPageFeature import MyPageFeatureInterface @@ -54,91 +51,69 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UNUserNotificationCenterD private extension AppDelegate { func registerDependencies() { - registerProvider() - registerRepository() registerUseCase() registerFactory() } - func registerProvider() { - DIContainer.register(type: NetworkProvider.self) { - NetworkProviderImpl() - } - DIContainer.register(type: Interceptor.self) { - TokenInterceptor(fetchTokenUseCase: DIContainer.resolve(type: FetchTokenFromLocalUseCase.self)) - } - } - - func registerRepository() { - DIContainer.register(type: TokenRepository.self) { - KeyChainRepositoryImpl() - } - DIContainer.register(type: AuthAPIRepository.self) { - AuthAPIRepositoryImpl(provider: DIContainer.resolve(type: NetworkProvider.self), interceptor: TokenInterceptor(fetchTokenUseCase: DIContainer.resolve(type: FetchTokenFromLocalUseCase.self))) - } - DIContainer.register(type: AlarmAPIRepository.self) { - AlarmAPIRepositoryImpl(provider: DIContainer.resolve(type: NetworkProvider.self), interceptor: DIContainer.resolve(type: Interceptor.self)) - } - } - func registerUseCase() { - DIContainer.register(type: CheckNickNameUseCase.self) { - CheckNickNameUseCaseImpl() - } - DIContainer.register(type: CheckEmptyLevelAndRoleUseCase.self) { - CheckEmptyLevelAndRoleUseCaseImpl() - } - DIContainer.register(type: CheckValidLevelUseCase.self) { - CheckValidLevelUseCaseImpl() - } - DIContainer.register(type: FetchJobListUseCase.self) { - FetchJobListUseCaseImpl(repository: DIContainer.resolve(type: AuthAPIRepository.self)) - } - DIContainer.register(type: UpdateUserInfoUseCase.self) { - UpdateUserInfoUseCaseImpl(repository: DIContainer.resolve(type: AuthAPIRepository.self)) - } - DIContainer.register(type: UpdateNickNameUseCase.self) { - UpdateNickNameUseCaseImpl(repository: DIContainer.resolve(type: AuthAPIRepository.self)) - } - DIContainer.register(type: LogoutUseCase.self) { - LogoutUseCaseImpl(repository: DIContainer.resolve(type: TokenRepository.self)) - } - DIContainer.register(type: WithdrawUseCase.self) { - WithdrawUseCaseImpl(authRepository: DIContainer.resolve(type: AuthAPIRepository.self), tokenRepository: DIContainer.resolve(type: TokenRepository.self)) - } - DIContainer.register(type: FetchTokenFromLocalUseCase.self) { - FetchTokenFromLocalUseCaseImpl(repository: DIContainer.resolve(type: TokenRepository.self)) - } - DIContainer.register(type: FetchNoticesUseCase.self) { - FetchNoticesUseCaseImpl(repository: DIContainer.resolve(type: AlarmAPIRepository.self)) - } - DIContainer.register(type: FetchOngoingEventsUseCase.self) { - FetchOngoingEventsUseCaseImpl(repository: DIContainer.resolve(type: AlarmAPIRepository.self)) - } - DIContainer.register(type: FetchOutdatedEventsUseCase.self) { - FetchOutdatedEventsUseCaseImpl(repository: DIContainer.resolve(type: AlarmAPIRepository.self)) - } - DIContainer.register(type: FetchPatchNotesUseCase.self) { - FetchPatchNotesUseCaseImpl(repository: DIContainer.resolve(type: AlarmAPIRepository.self)) - } - DIContainer.register(type: SetReadUseCase.self) { - SetReadUseCaseImpl(repository: DIContainer.resolve(type: AlarmAPIRepository.self)) - } - DIContainer.register(type: CheckNotificationPermissionUseCase.self) { - CheckNotificationPermissionUseCaseImpl() - } - DIContainer.register(type: UpdateNotificationAgreementUseCase.self) { - UpdateNotificationAgreementUseCaseImpl(authRepository: DIContainer.resolve(type: AuthAPIRepository.self)) - } - DIContainer.register(type: UpdateProfileImageUseCase.self) { - UpdateProfileImageUseCaseImpl(repository: DIContainer.resolve(type: AuthAPIRepository.self)) - } - DIContainer.register(type: FetchJobUseCase.self) { - FetchJobUseCaseImpl(repository: DIContainer.resolve(type: AuthAPIRepository.self)) - } - DIContainer.register(type: FetchProfileUseCase.self) { - FetchProfileUseCaseImpl(repository: DIContainer.resolve(type: AuthAPIRepository.self), fetchJobUseCase: DIContainer.resolve(type: FetchJobUseCase.self)) - } + ///테스트 코드에 맞게 등록 +// DIContainer.register(type: CheckNickNameUseCase.self) { +// CheckNickNameUseCaseImpl() +// } +// DIContainer.register(type: CheckEmptyLevelAndRoleUseCase.self) { +// CheckEmptyLevelAndRoleUseCaseImpl() +// } +// DIContainer.register(type: CheckValidLevelUseCase.self) { +// CheckValidLevelUseCaseImpl() +// } +// DIContainer.register(type: FetchJobListUseCase.self) { +// FetchJobListUseCaseImpl(repository: DIContainer.resolve(type: AuthAPIRepository.self)) +// } +// DIContainer.register(type: UpdateUserInfoUseCase.self) { +// UpdateUserInfoUseCaseImpl(repository: DIContainer.resolve(type: AuthAPIRepository.self)) +// } +// DIContainer.register(type: UpdateNickNameUseCase.self) { +// UpdateNickNameUseCaseImpl(repository: DIContainer.resolve(type: AuthAPIRepository.self)) +// } +// DIContainer.register(type: LogoutUseCase.self) { +// LogoutUseCaseImpl(repository: DIContainer.resolve(type: TokenRepository.self)) +// } +// DIContainer.register(type: WithdrawUseCase.self) { +// WithdrawUseCaseImpl(authRepository: DIContainer.resolve(type: AuthAPIRepository.self), tokenRepository: DIContainer.resolve(type: TokenRepository.self)) +// } +// DIContainer.register(type: FetchTokenFromLocalUseCase.self) { +// FetchTokenFromLocalUseCaseImpl(repository: DIContainer.resolve(type: TokenRepository.self)) +// } +// DIContainer.register(type: FetchNoticesUseCase.self) { +// FetchNoticesUseCaseImpl(repository: DIContainer.resolve(type: AlarmAPIRepository.self)) +// } +// DIContainer.register(type: FetchOngoingEventsUseCase.self) { +// FetchOngoingEventsUseCaseImpl(repository: DIContainer.resolve(type: AlarmAPIRepository.self)) +// } +// DIContainer.register(type: FetchOutdatedEventsUseCase.self) { +// FetchOutdatedEventsUseCaseImpl(repository: DIContainer.resolve(type: AlarmAPIRepository.self)) +// } +// DIContainer.register(type: FetchPatchNotesUseCase.self) { +// FetchPatchNotesUseCaseImpl(repository: DIContainer.resolve(type: AlarmAPIRepository.self)) +// } +// DIContainer.register(type: SetReadUseCase.self) { +// SetReadUseCaseImpl(repository: DIContainer.resolve(type: AlarmAPIRepository.self)) +// } +// DIContainer.register(type: CheckNotificationPermissionUseCase.self) { +// CheckNotificationPermissionUseCaseImpl() +// } +// DIContainer.register(type: UpdateNotificationAgreementUseCase.self) { +// UpdateNotificationAgreementUseCaseImpl(authRepository: DIContainer.resolve(type: AuthAPIRepository.self)) +// } +// DIContainer.register(type: UpdateProfileImageUseCase.self) { +// UpdateProfileImageUseCaseImpl(repository: DIContainer.resolve(type: AuthAPIRepository.self)) +// } +// DIContainer.register(type: FetchJobUseCase.self) { +// FetchJobUseCaseImpl(repository: DIContainer.resolve(type: AuthAPIRepository.self)) +// } +// DIContainer.register(type: FetchProfileUseCase.self) { +// FetchProfileUseCaseImpl(repository: DIContainer.resolve(type: AuthAPIRepository.self), fetchJobUseCase: DIContainer.resolve(type: FetchJobUseCase.self)) +// } } func registerFactory() { @@ -147,7 +122,7 @@ private extension AppDelegate { } DIContainer.register(type: SetProfileFactory.self) { - SetProfileFactoryImpl(selectImageFactory: DIContainer.resolve(type: SelectImageFactory.self), checkNickNameUseCase: DIContainer.resolve(type: CheckNickNameUseCase.self), updateNickNameUseCase: DIContainer.resolve(type: UpdateNickNameUseCase.self), logoutUseCase: DIContainer.resolve(type: LogoutUseCase.self), withdrawUseCase: DIContainer.resolve(type: WithdrawUseCase.self)) + SetProfileFactoryImpl(selectImageFactory: DIContainer.resolve(type: SelectImageFactory.self), checkNickNameUseCase: DIContainer.resolve(type: CheckNickNameUseCase.self), updateNickNameUseCase: DIContainer.resolve(type: UpdateNickNameUseCase.self), logoutUseCase: DIContainer.resolve(type: LogoutUseCase.self), withdrawUseCase: DIContainer.resolve(type: WithdrawUseCase.self), fetchProfileUseCase: DIContainer.resolve(type: FetchProfileUseCase.self)) } DIContainer.register(type: SetCharacterFactory.self) { @@ -177,14 +152,15 @@ private extension AppDelegate { } DIContainer.register(type: CustomerSupportFactory.self) { - CustomerSupportBaseViewFactoryImpl(fetchNoticesUseCase: DIContainer.resolve(type: FetchNoticesUseCase.self), fetchOngoingEventsUseCase: DIContainer.resolve(type: FetchOngoingEventsUseCase.self), fetchOutdatedEventsUseCase: DIContainer.resolve(type: FetchOutdatedEventsUseCase.self), fetchPatchNotesUseCase: DIContainer.resolve(type: FetchPatchNotesUseCase.self), setReadUseCase: DIContainer.resolve(type: SetReadUseCase.self)) + CustomerSupportBaseViewFactoryImpl(policyFactory: DIContainer.resolve(type: PolicyFactory.self), fetchNoticesUseCase: DIContainer.resolve(type: FetchNoticesUseCase.self), fetchOngoingEventsUseCase: DIContainer.resolve(type: FetchOngoingEventsUseCase.self), fetchOutdatedEventsUseCase: DIContainer.resolve(type: FetchOutdatedEventsUseCase.self), fetchPatchNotesUseCase: DIContainer.resolve(type: FetchPatchNotesUseCase.self), setReadUseCase: DIContainer.resolve(type: SetReadUseCase.self)) } DIContainer.register(type: NotificationSettingFactory.self) { NotificationSettingFactoryImpl(checkNotificationPermissionUseCase: DIContainer.resolve(type: CheckNotificationPermissionUseCase.self), updateNotificationAgreementUseCase: DIContainer.resolve(type: UpdateNotificationAgreementUseCase.self)) } + DIContainer.register(type: LoginFactory.self) { - LoginFactoryMock() + MockLoginFactory() } } } diff --git a/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/Mock/MockLoginFactory.swift b/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/Mock/MockLoginFactory.swift new file mode 100644 index 00000000..0c68c7f6 --- /dev/null +++ b/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/Mock/MockLoginFactory.swift @@ -0,0 +1,10 @@ +import BaseFeature +import AuthFeatureInterface + +public final class MockLoginFactory: LoginFactory { + public func make(exitRoute: LoginExitRoute, onLoginCompleted: (() -> Void)?) -> BaseViewController { + let viewcontroller = BaseViewController() + viewcontroller.view.backgroundColor = .redMLS + return viewcontroller + } +} diff --git a/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/ViewController.swift b/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/ViewController.swift index 6d46746a..d1f3a414 100644 --- a/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/ViewController.swift +++ b/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/ViewController.swift @@ -33,7 +33,7 @@ class ViewController: UIViewController { ]) let notiView = BottomTabBarController(viewControllers: [ - DIContainer.resolve(type: NotificationSettingFactory.self).make() + DIContainer.resolve(type: NotificationSettingFactory.self).make(isAgreeEventNotification: false, isAgreeNoticeNotification: false, isAgreePatchNoteNotification: false) ]) mainView.title = "마이페이지 메인" From df224db019b49d84d091366022ae524b67ebce43 Mon Sep 17 00:00:00 2001 From: p2glet Date: Wed, 22 Apr 2026 15:25:49 +0900 Subject: [PATCH 3/4] =?UTF-8?q?fix/#319:=20=EA=B3=B5=EC=A7=80=EC=82=AC?= =?UTF-8?q?=ED=95=AD=20/=20=ED=8C=A8=EC=B9=98=EB=85=B8=ED=8A=B8=20?= =?UTF-8?q?=ED=8E=98=EC=9D=B4=EC=A7=95=20=EC=88=98=EC=A0=95=20+=20?= =?UTF-8?q?=EB=B2=84=EC=A0=84=203.0.0=20=EB=B0=8F=20=EC=95=B1=20=EC=9D=B4?= =?UTF-8?q?=EB=A6=84=20=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- MLS/MLS.xcodeproj/project.pbxproj | 6 ++++-- .../DictionaryNotificationReactor.swift | 6 +++--- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/MLS/MLS.xcodeproj/project.pbxproj b/MLS/MLS.xcodeproj/project.pbxproj index 250c07a5..053ef9dd 100644 --- a/MLS/MLS.xcodeproj/project.pbxproj +++ b/MLS/MLS.xcodeproj/project.pbxproj @@ -681,6 +681,7 @@ "DEVELOPMENT_TEAM[sdk=iphoneos*]" = W5QTRMS954; GENERATE_INFOPLIST_FILE = YES; INFOPLIST_FILE = MLS/Resource/Info.plist; + INFOPLIST_KEY_CFBundleDisplayName = "메랜사"; INFOPLIST_KEY_ITSAppUsesNonExemptEncryption = NO; INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen; @@ -693,7 +694,7 @@ "@executable_path/Frameworks", ); MACH_O_TYPE = mh_execute; - MARKETING_VERSION = 3.0.2; + MARKETING_VERSION = 3.0.3; PRODUCT_BUNDLE_IDENTIFIER = com.donggle.MLS; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE_SPECIFIER = ""; @@ -723,6 +724,7 @@ "DEVELOPMENT_TEAM[sdk=iphoneos*]" = W5QTRMS954; GENERATE_INFOPLIST_FILE = YES; INFOPLIST_FILE = MLS/Resource/Info.plist; + INFOPLIST_KEY_CFBundleDisplayName = "메랜사"; INFOPLIST_KEY_ITSAppUsesNonExemptEncryption = NO; INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen; @@ -735,7 +737,7 @@ "@executable_path/Frameworks", ); MACH_O_TYPE = mh_execute; - MARKETING_VERSION = 3.0.2; + MARKETING_VERSION = 3.0.3; PRODUCT_BUNDLE_IDENTIFIER = com.donggle.MLS; PRODUCT_NAME = "$(TARGET_NAME)"; PROVISIONING_PROFILE_SPECIFIER = ""; diff --git a/MLS/Presentation/DictionaryFeature/DictionaryFeature/DictionaryNotification/DictionaryNotificationReactor.swift b/MLS/Presentation/DictionaryFeature/DictionaryFeature/DictionaryNotification/DictionaryNotificationReactor.swift index 305f8bf7..20e8e42c 100644 --- a/MLS/Presentation/DictionaryFeature/DictionaryFeature/DictionaryNotification/DictionaryNotificationReactor.swift +++ b/MLS/Presentation/DictionaryFeature/DictionaryFeature/DictionaryNotification/DictionaryNotificationReactor.swift @@ -63,7 +63,7 @@ public final class DictionaryNotificationReactor: Reactor { let notificationStream: Observable = Observable.concat([ Observable.just(.setLoading(true)), - fetchAllAlarmUseCase.execute(cursor: nil, pageSize: 20) + fetchAllAlarmUseCase.execute(id: nil, pageSize: 20) .map { paged in Mutation.setNotifications(paged.items, hasMore: paged.hasMore, reset: true) }, @@ -78,11 +78,11 @@ public final class DictionaryNotificationReactor: Reactor { case .loadMore: guard currentState.hasMore, !currentState.isLoading else { return .empty() } - let cursor = currentState.notifications.last?.date + let cursor = currentState.notifications.last?.id return Observable.concat([ Observable.just(.setLoading(true)), - fetchAllAlarmUseCase.execute(cursor: cursor, pageSize: 20) + fetchAllAlarmUseCase.execute(id: cursor, pageSize: 20) .map { paged in Mutation.setNotifications(paged.items, hasMore: paged.hasMore, reset: false) }, From 59eabc74b9e2b8ac31e4a91f591499ec47e5efae Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 22 Apr 2026 06:38:44 +0000 Subject: [PATCH 4/4] style/#319: Apply SwiftLint autocorrect --- .../MyPageFeature/MyPageFeatureDemo/AppDelegate.swift | 2 +- .../MyPageFeature/MyPageFeatureDemo/Mock/MockLoginFactory.swift | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/AppDelegate.swift b/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/AppDelegate.swift index 48dd0f63..d71869df 100644 --- a/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/AppDelegate.swift +++ b/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/AppDelegate.swift @@ -56,7 +56,7 @@ private extension AppDelegate { } func registerUseCase() { - ///테스트 코드에 맞게 등록 + /// 테스트 코드에 맞게 등록 // DIContainer.register(type: CheckNickNameUseCase.self) { // CheckNickNameUseCaseImpl() // } diff --git a/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/Mock/MockLoginFactory.swift b/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/Mock/MockLoginFactory.swift index 0c68c7f6..ff98072c 100644 --- a/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/Mock/MockLoginFactory.swift +++ b/MLS/Presentation/MyPageFeature/MyPageFeatureDemo/Mock/MockLoginFactory.swift @@ -1,5 +1,5 @@ -import BaseFeature import AuthFeatureInterface +import BaseFeature public final class MockLoginFactory: LoginFactory { public func make(exitRoute: LoginExitRoute, onLoginCompleted: (() -> Void)?) -> BaseViewController {