Skip to content

Conversation

wjdrjs00
Copy link
Member

@wjdrjs00 wjdrjs00 commented Aug 6, 2025

[ PR Content ]

온보딩 추천 루틴이 삭제 안되던 문제를 해결했습니다.

Related issue

Screenshot 📸

  • N/A

Work Description

  • 당일 삭제 api 요청 dto에 routineType 필드 추가

To Reviewers 📢

  • 긴급 수정!
  • 수정된 api 명세에 맞춰서 요청 dto에 routineType 필드를 추가했습니다!

Summary by CodeRabbit

  • 신규 기능

    • 루틴 삭제 시 루틴 유형(routineType) 정보를 함께 처리하도록 개선되었습니다.
  • 버그 수정

    • 루틴 삭제 동작이 일부 상황에서 정확하게 동작하도록 수정되었습니다.
  • 기타

    • 앱 버전이 1.0.1로 업데이트되었습니다.

l5x5l and others added 3 commits August 3, 2025 01:41
[Release/1.0] 1.0버전 main 브랜치 병합
- RoutineByDayDeletion, RoutineByDayDeletionRequestDto에 routineType 필드 추가
- versionCode: 2 -> 3
- versionName: 1.0 -> 1.0.1
@wjdrjs00 wjdrjs00 requested a review from l5x5l August 6, 2025 11:58
@wjdrjs00 wjdrjs00 self-assigned this Aug 6, 2025
Copy link

coderabbitai bot commented Aug 6, 2025

Walkthrough

루틴 삭제 관련 기능에서 온보딩 추천 루틴 삭제 오류를 수정하기 위해 routineType 필드를 도메인, DTO, UI 모델에 추가 및 전달하도록 변경되었습니다. 또한, 삭제 API 호출 시 해당 타입 정보를 포함하도록 로직이 수정되었으며, 앱 버전 정보가 소폭 업데이트되었습니다.

Changes

Cohort / File(s) Change Summary
도메인 및 DTO 모델 확장
domain/.../RoutineByDayDeletion.kt, data/.../RoutineByDayDeletionRequestDto.kt
RoutineByDayDeletionRoutineByDayDeletionRequestDtoroutineType 필드 추가 및 매핑 확장
UI 모델 및 변환 함수 수정
presentation/.../model/RoutineUiModel.kt
RoutineUiModel.toRoutineByDayDeletion 함수에서 routineType 전달 추가
홈 화면 삭제 로직 변경
presentation/.../home/HomeScreen.kt
repeatDay가 비어있는 루틴 삭제 시 deleteRoutineByDay를 호출하도록 변경
버전 정보 업데이트
gradle/libs.versions.toml
앱 버전코드 2→3, 버전명 1.0→1.0.1로 변경

Sequence Diagram(s)

sequenceDiagram
    participant UI as HomeScreen
    participant VM as HomeViewModel
    participant Domain as RoutineByDayDeletion
    participant Data as RoutineByDayDeletionRequestDto
    participant Server

    UI->>VM: deleteRoutineByDay(routine)
    VM->>Domain: RoutineUiModel.toRoutineByDayDeletion(routine)
    Domain->>Data: toDto() (routineType 포함)
    Data->>Server: DELETE /routineByDay (routineType 포함)
    Server-->>Data: 삭제 결과 반환
    Data-->>VM: 결과 전달
    VM-->>UI: UI 업데이트
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~15 minutes

Assessment against linked issues

Objective Addressed Explanation
routineType 추가 (#74)
온보딩 추천 루틴 정상 삭제 가능 (#74)
당일 삭제 API 요청 DTO에 routineType 추가 (#74)

Assessment against linked issues: Out-of-scope changes

(해당 변경사항에는 이슈 목표와 무관한 변경이 발견되지 않았습니다.)

Suggested labels

🐞 Fix, 세환

Suggested reviewers

  • l5x5l

Poem

🐰
루틴 삭제, 이제는 OK!
타입 정보 담아 보내,
온보딩 추천도 문제 없네.
버전도 한 단계 UP,
깔끔한 코드, 모두가 웃네!

(코드토끼가 응원합니다!)

Note

⚡️ Unit Test Generation is now available in beta!

Learn more here, or try it out under "Finishing Touches" below.


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between c4a1e0e and c5d0224.

📒 Files selected for processing (5)
  • data/src/main/java/com/threegap/bitnagil/data/routine/model/request/RoutineByDayDeletionRequestDto.kt (2 hunks)
  • domain/src/main/java/com/threegap/bitnagil/domain/routine/model/RoutineByDayDeletion.kt (1 hunks)
  • gradle/libs.versions.toml (1 hunks)
  • presentation/src/main/java/com/threegap/bitnagil/presentation/home/HomeScreen.kt (1 hunks)
  • presentation/src/main/java/com/threegap/bitnagil/presentation/home/model/RoutineUiModel.kt (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: build
🔇 Additional comments (6)
gradle/libs.versions.toml (1)

8-9: 버전 코드/네임 증가 확인 – 추가 후속 작업 필요

패치성 핫픽스이므로 versionCode = "3", versionName = "1.0.1" 로 올린 것은 적절합니다.
다만

  1. CHANGELOG.md 또는 릴리즈 노트에 1.0.1 변경사항(온보딩 추천 루틴 삭제 버그 수정)을 반드시 기록해 주세요.
  2. app/build.gradle (또는 버전 카탈로그를 참조하지 않는 모듈)에 동일 값이 하드코딩돼 있지 않은지 한번 더 점검 바랍니다. 동기화 누락 시 Play Store 업로드에서 충돌이 날 수 있습니다.

기능적으로는 문제 없으므로 변경 자체는 승인합니다.

domain/src/main/java/com/threegap/bitnagil/domain/routine/model/RoutineByDayDeletion.kt (1)

6-6: 도메인 모델에 routineType 필드 추가가 적절합니다.

RoutineByDayDeletion 데이터 클래스에 routineType 필드를 추가한 것이 온보딩 추천 루틴 삭제 오류 수정 목적에 부합합니다.

presentation/src/main/java/com/threegap/bitnagil/presentation/home/model/RoutineUiModel.kt (1)

42-42: UI 모델에서 도메인 모델로 routineType 매핑이 올바릅니다.

toRoutineByDayDeletion 확장 함수에서 routineType을 올바르게 전달하여 삭제 과정에서 루틴 타입 정보가 유지됩니다.

presentation/src/main/java/com/threegap/bitnagil/presentation/home/HomeScreen.kt (1)

98-98: 반복 없는 루틴 삭제 로직 개선이 적절합니다.

repeatDay가 비어있는 루틴에 대해 deleteRoutineByDay를 호출하도록 변경하여, routineType 정보를 포함한 전체 루틴 객체가 삭제 프로세스에 전달됩니다. 이는 온보딩 추천 루틴 삭제 오류 수정에 필요한 변경사항입니다.

data/src/main/java/com/threegap/bitnagil/data/routine/model/request/RoutineByDayDeletionRequestDto.kt (2)

13-14: DTO에 routineType 필드 추가가 올바릅니다.

@SerialName 어노테이션을 사용한 필드 추가가 적절합니다.


27-27: RoutineType.name으로 변환되는 값 확인 요청

파일: data/src/main/java/com/threegap/bitnagil/data/routine/model/request/RoutineByDayDeletionRequestDto.kt:27

  • routineType = this.routineType.name 구문이 반환하는 문자열은 다음과 같습니다:
    • "ROUTINE"
    • "SUB_ROUTINE"
    • "CHANGED_ROUTINE"
    • "CHANGED_SUB_ROUTINE"

서버 API가 위와 같은 값을 정확히 기대하도록 스펙이 정의되어 있는지 API 문서 또는 백엔드 담당자에게 확인해 주세요.

✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch hotfix/#74-routine-delete

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.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai generate unit tests to generate unit tests for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@wjdrjs00 wjdrjs00 added 🐞 Fix 버그 수정 🧤 대현 labels Aug 6, 2025
Copy link
Contributor

@l5x5l l5x5l left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

심사 통과되었습니다! 머지 진행하시죠!

@wjdrjs00 wjdrjs00 merged commit af43a04 into develop Aug 6, 2025
2 checks passed
@wjdrjs00 wjdrjs00 deleted the hotfix/#74-routine-delete branch August 6, 2025 12:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[FIX] 온보딩 추천 루틴 삭제 오류 수정
2 participants