[feat] #71 - 하위 태스크 완료/미완료#77
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (5)
🚧 Files skipped from review as they are similar to previous changes (4)
Walkthrough하위 태스크 완료 상태를 변경하는 PATCH 엔드포인트가 추가되었습니다. 관련 요청/응답 DTO, 서비스 메서드, 엔티티 갱신 메서드가 도입되었고, 성공/오류 코드가 조정되었습니다. 기존 todo 완료 처리의 null 검증은 제거되었고, todo 완료 요청에는 null 금지 검증이 추가되었습니다. Changes하위 태스크 상태 변경 기능
Estimated code review effort: 2 (Simple) | ~12 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
| import com.fasterxml.jackson.annotation.JsonProperty; | ||
|
|
||
| public record SubtaskStatusUpdateRequest( | ||
| @JsonProperty("isCompleted") |
There was a problem hiding this comment.
@NotNull, @Valid를 사용하면 컨트롤러 진입 전에 걸러질 수 있을 것 같은데 Service 레이어에서 isCompleted가 null인 경우를 체크하는 이유가 따로 있을까용
aneykrap
left a comment
There was a problem hiding this comment.
p3 내용 한번 확인해주시면 감사하겟습니다.
| .findFirst() | ||
| .orElseThrow(() -> new CustomException(TodoErrorCode.SUBTASK_NOT_FOUND)); | ||
|
|
||
| subtask.updateCompleted(request.isCompleted()); |
There was a problem hiding this comment.
p3) 현재 Subtask 엔티티의 completed 값을 직접 변경하고 있어서, daily TODO의 오늘 하위 태스크를 완료하면 다른 날짜에서도 같은 하위 태스크가 완료 상태로 보일 수 있을 것 같아요. 하위 태스크 완료 상태도 날짜별로 관리되어야 하지 않을까용
| throw new CustomException(TodoErrorCode.IS_COMPLETED_REQUIRED); | ||
| } | ||
|
|
||
| Todo todo = todoRepository.findByIdAndUser_Id(todoId, userId) |
There was a problem hiding this comment.
소유한 TODO를 먼저 조회한 뒤 그 안에서 하위 태스크를 찾는 흐름이라 권한 확인과 소속 검증이 같이 처리되네용 짱짱쓴
하위 태스크 완료 여부 브랜치와 develop의 TODO 상세 조회/수정/삭제/순서 정렬 기능 간 충돌을 해소했습니다. - TodoController/TodoService: changeSubtaskCompletion과 develop의 getTodoDetail/updateTodo/deleteTodo/reorderTodo 양쪽 유지 - TodoControllerDocs: develop 문서를 기준으로 하위 태스크 완료 상태 변경 문서 추가 - TodoSuccessCode: SUBTASK_STATUS_CHANGED 포함 전체 통합 - TodoErrorCode: 이 브랜치의 의도(@NotNull 검증으로 대체)에 따라 IS_COMPLETED_REQUIRED 제거, SUBTASK_NOT_FOUND는 develop 정의(SUBTASK_404) 채택 Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
관련 이슈 🛠
작업 내용 요약 ✏️
하위 태스크의 완료 여부를 변환하는 api
주요 변경 사항 🛠️
트러블 슈팅 ⚽️
없었습니당
스크린샷 📷
리뷰 요구사항 📢
나의 하위태스크들을 봐주세용
Summary by CodeRabbit
isCompleted값에 대한 필수 검증이 반영되어 요청 누락 시 오류 처리가 더 일관됩니다.