-
Notifications
You must be signed in to change notification settings - Fork 1
[Feat-T3-159] 루틴 리스트 화면 구현 및 서버 v2 연동 #54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
ab4a460
f2932b8
84818be
45bf1b6
cd7d032
0b2dfa4
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,5 @@ | ||
| // | ||
| // TokenResponseDTO.swift | ||
| // LoginResponseDTO.swift | ||
| // DataSource | ||
| // | ||
| // Created by 최정인 on 6/30/25. | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,46 @@ | ||
| // | ||
| // RoutineDTO.swift | ||
| // DataSource | ||
| // | ||
| // Created by 최정인 on 8/19/25. | ||
| // | ||
|
|
||
| import Domain | ||
|
|
||
| struct RoutineDictionaryDTO: Decodable { | ||
| let routines: [String: RoutineDateDTO] | ||
| } | ||
|
|
||
| struct RoutineDateDTO: Decodable { | ||
| let routineList: [RoutineDTO] | ||
| let allCompleted: Bool | ||
| } | ||
|
|
||
| struct RoutineDTO: Decodable { | ||
| let routineId: String | ||
| let routineName: String | ||
| let repeatDay: [String] | ||
| let executionTime: String | ||
| let routineCompleteYn: Bool | ||
| let subRoutineNames: [String] | ||
| let subRoutineCompleteYn: [Bool] | ||
| let recommendedRoutineType: String? | ||
| let routineDeletedYn: Bool | ||
| let routineStartDate: String | ||
| let routineEndDate: String | ||
|
|
||
| func toRoutineEntity() -> RoutineEntity { | ||
| return RoutineEntity( | ||
| routineId: routineId, | ||
| routineName: routineName, | ||
| repeatDay: repeatDay, | ||
| executionTime: executionTime, | ||
| routineCompleteYn: routineCompleteYn, | ||
| subRoutineNames: subRoutineNames, | ||
| subRoutineCompleteYn: subRoutineCompleteYn, | ||
| recommendedRoutineType: recommendedRoutineType, | ||
| routineDeletedYn: routineDeletedYn, | ||
| routineStartDate: routineStartDate, | ||
| routineEndDate: routineEndDate) | ||
| } | ||
| } |
This file was deleted.
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -10,13 +10,13 @@ import Foundation | |
| public protocol RoutineUseCaseProtocol { | ||
| func fetchRoutine(routineId: String) async throws -> RoutineEntity? | ||
|
|
||
| func fetchRoutines(startDate: Date, endDate: Date) async throws -> [String: [RoutineEntity]] | ||
| func fetchRoutines(startDate: Date, endDate: Date) async throws -> [String: (routines: [RoutineEntity], allCompleted: Bool)] | ||
|
|
||
| func saveRoutine(routine: RoutineCreationEntity) async throws | ||
|
|
||
| func deleteAllRoutine(routineId: String) async throws | ||
|
|
||
| func deleteDailyRoutine(routine: DeleteRoutineEntity) async throws | ||
| func deleteDailyRoutine(routineId: String) async throws | ||
|
|
||
|
Comment on lines
+19
to
20
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 💡 Verification agent 🧩 Analysis chain삭제 유스케이스 시그니처 단순화 OK — 호출처 정리 여부 확인
다음 스크립트로 남아있는 구 호출 패턴을 점검할 수 있습니다. 🏁 Script executed: #!/bin/bash
rg -nP 'deleteDailyRoutine\s*\(\s*routine:' -C2
rg -n 'DeleteRoutineEntity' -C2Length of output: 1282 HomeViewModel 호출부 및 HomeViewModel에서 여전히 구 버전 시그니처(
이렇게 변경하면 삭제 유스케이스 시그니처 단순화 작업이 완결됩니다. 🤖 Prompt for AI Agents |
||
| func updateRoutineCompletions(routines: [RoutineCompletionEntity]) async throws | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| { | ||
| "info" : { | ||
| "author" : "xcode", | ||
| "version" : 1 | ||
| } | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Verification agent
🧩 Analysis chain
시그니처 변경 자체는 일관성 있게 반영됨
deleteDailyRoutine(routineId:)로 단순화된 파라미터는 Repository/UseCase 계층과도 정합성이 맞습니다. 다만 하위 호출처에 기존DeleteRoutineEntity기반 호출이 남아 있지 않은지 확인이 필요합니다.다음 스크립트로 이전 시그니처 사용 및 관련 엔티티 잔존 여부를 빠르게 점검해 주세요.
🏁 Script executed:
Length of output: 2066
HomeViewModel에서 deleteDailyRoutine 호출 시그니처와 레거시 엔티티/DTO 제거 필요
다음 사항을 반영해 주세요:
Projects/Presentation/Sources/Home/ViewModel/HomeViewModel.swift
• 라인 247:
현재
수정 후
• 관련 변수명(
deleteRoutinEntity→deleteRoutineEntity) 오타도 함께 정정 필요합니다.레거시 엔티티/DTO 제거 또는 리팩터링
•
DeleteSubRoutineEntity,DeleteRoutineEntity(라인 235–239)•
Projects/DataSource/Sources/DTO/DeleteRoutineDTO.swift이제 API 호출 계층에서
DeleteRoutineDTO를 직접 사용하거나, 별도 변환 로직 없이routineId만 넘기는 구조로 통일하시면 됩니다.🤖 Prompt for AI Agents