Skip to content

[Feat/#164] 등록 뷰 배송가격 수정 가능하게 변경 - #165

Merged
doyeon0307 merged 6 commits into
developfrom
feat/#164-create-delivery-option
Jul 28, 2026
Merged

[Feat/#164] 등록 뷰 배송가격 수정 가능하게 변경#165
doyeon0307 merged 6 commits into
developfrom
feat/#164-create-delivery-option

Conversation

@doyeon0307

@doyeon0307 doyeon0307 commented Jul 26, 2026

Copy link
Copy Markdown
Contributor

Related issue 🛠️

Work Description ✏️

  • 등록 뷰에서 배송가격 수정 가능하게 변경했습니다.
  • 스프린트 때 배송 수단도 4개로 늘었는데, 배송 수단과 기본값은 서버값으로 세팅되는 거라 제가 수정하지는 않았어요.
  • 이전에는 DeliveryOption 도메인 모델로만 관리했는데 서버 기본값 리스트, 현재 수정 중인 배송옵션 리스트, 선택된 옵션 리스트 3개를 별도로 관리해야 합니다. 그래서 isSelected 필드를 갖는 DeliveryOptionUiModel로 리팩토링했습니다.
  • 선택된 배송 옵션 가격이 미입력된 경우 선택된 멤버 가격 미입력 케이스와 동일하게 에러처리 했습니다. (자동 스크롤+에러 문구)

Screenshot 📸

정상 입력 가격 공란
default.mp4
default.mp4
API
image

Uncompleted Tasks 😅

  • N/A

To Reviewers 📢

포티 화이팅!!

Summary by CodeRabbit

요약 (CodeRabbit)

  • 새로운 기능

    • 파티 생성 시 배송 옵션별 배송비를 직접 입력하고 수정할 수 있습니다.
    • 선택한 배송 옵션만 배송 정보에 반영됩니다.
    • 배송 옵션 선택 및 배송비 입력 상태가 화면에 즉시 반영됩니다.
  • 개선

    • 배송 옵션을 선택해야 배송비를 편집할 수 있도록 사용성이 개선되었습니다.
    • 선택 상태 변경은 최소 2개 이상 선택된 경우에만 가능합니다.
    • 배송비가 누락되거나 형식에 맞지 않을 경우 안내 메시지가 표시됩니다.

@doyeon0307
doyeon0307 requested review from cmj7271 and jyvnee July 26, 2026 05:23
@doyeon0307 doyeon0307 self-assigned this Jul 26, 2026
@doyeon0307 doyeon0307 added 🌟 Feat 새로운 기능 구현 🔎 UI UI 작업 labels Jul 26, 2026
@doyeon0307 doyeon0307 linked an issue Jul 26, 2026 that may be closed by this pull request
2 tasks
@coderabbitai

coderabbitai Bot commented Jul 26, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: d6462185-ce3d-4238-b8a2-bd2a05f16922

📥 Commits

Reviewing files that changed from the base of the PR and between 12a4d3a and 70f8678.

📒 Files selected for processing (2)
  • app/src/main/java/com/poti/android/presentation/party/create/PartyCreateViewModel.kt
  • app/src/main/java/com/poti/android/presentation/party/create/model/Contracts.kt
💤 Files with no reviewable changes (1)
  • app/src/main/java/com/poti/android/presentation/party/create/model/Contracts.kt
🚧 Files skipped from review as they are similar to previous changes (1)
  • app/src/main/java/com/poti/android/presentation/party/create/PartyCreateViewModel.kt

📝 Walkthrough

Walkthrough

배송 옵션 상태를 DeliveryOptionUiModel 기반으로 통합하고, 선택·가격 입력·가격 검증을 CreateDeliverySetting에서 ViewModel까지 연결했습니다. 등록 시 선택된 옵션은 도메인 DeliveryOption으로 변환됩니다.

Changes

배송 옵션 등록 흐름

Layer / File(s) Summary
배송 옵션 UI 계약
app/src/main/java/com/poti/android/presentation/party/create/model/*
배송 옵션 UI 모델을 추가하고 상태·인텐트·오류 계약을 UI 모델 및 배송 가격 오류 기준으로 변경했습니다.
배송 설정 입력 및 화면 연결
app/src/main/java/com/poti/android/presentation/party/create/component/CreateDeliverySetting.kt, app/src/main/java/com/poti/android/presentation/party/create/PartyCreateScreen.kt, app/src/main/res/values/strings.xml
선택 상태에 따른 가격 입력 활성화와 오류 메시지 표시를 추가하고, 가격 변경을 ViewModel 이벤트로 연결했습니다.
배송 상태 처리 및 등록 변환
app/src/main/java/com/poti/android/presentation/party/create/PartyCreateViewModel.kt
배송 옵션을 초기화하고 선택·가격 변경 및 가격 유효성 검사를 처리하며, 등록 시 선택된 옵션을 도메인 모델로 변환합니다.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Sequence Diagram(s)

sequenceDiagram
  participant CreateDeliverySetting
  participant PartyCreateScreen
  participant PartyCreateViewModel
  participant createPartyUseCase
  CreateDeliverySetting->>PartyCreateScreen: 배송 가격 입력
  PartyCreateScreen->>PartyCreateViewModel: OnDeliveryPriceChange
  PartyCreateViewModel->>PartyCreateViewModel: deliveryOptions 가격 및 오류 상태 갱신
  PartyCreateScreen->>PartyCreateViewModel: 등록 요청
  PartyCreateViewModel->>createPartyUseCase: 선택 배송 옵션 변환 및 전달
Loading

Possibly related PRs

  • team-poti/POTI-ANDROID#106: PartyCreateViewModelPartyCreateScreen의 배송 옵션 초기화 흐름을 함께 변경합니다.
  • team-poti/POTI-ANDROID#144: PartyCreateScreen, PartyCreateViewModel, CreateDeliverySetting의 배송 옵션 타입과 상태 전달을 함께 변경합니다.

Suggested reviewers: jyvnee, cmj7271

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed 제목이 등록 뷰의 배송 가격 수정 가능 변경이라는 핵심 내용을 명확히 담고 있습니다.
Description check ✅ Passed 이슈, 작업 내용, 스크린샷, 완료 여부, 리뷰어 메모가 모두 포함되어 있어 템플릿을 대부분 충족합니다.
Linked Issues check ✅ Passed 직접 이슈 #164의 배송 옵션 추가와 가격 수정 가능화 요구를 UI 모델 리팩토링과 입력 검증으로 충족했습니다.
Out of Scope Changes check ✅ Passed 추가된 모델, 에러 문구, 스크롤 처리도 모두 배송 가격 수정 기능을 위한 범위 안에 있습니다.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/#164-create-delivery-option

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

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@app/src/main/java/com/poti/android/presentation/party/create/model/DeliveryOptionUiModel.kt`:
- Around line 3-8: 배송비 입력 오류가 0원으로 변환되지 않도록 편집값과 검증된 가격을 분리하세요.
app/src/main/java/com/poti/android/presentation/party/create/model/DeliveryOptionUiModel.kt#L3-L8에서는
원본 가격 문자열과 유효한 도메인 가격을 표현하도록 모델을 조정하고,
app/src/main/java/com/poti/android/presentation/party/create/component/CreateDeliverySetting.kt#L48-L50에서는
toIntOrNull() ?: 0 대신 원본 입력을 전달하세요.
app/src/main/java/com/poti/android/presentation/party/create/PartyCreateViewModel.kt#L429-L438에서는
필수값과 Int 범위를 검증한 뒤 유효한 값만 등록 요청에 포함하고 잘못된 값은 등록 상태에 반영하지 않도록 수정하세요.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: ff27cdf4-87cc-4c5c-9ad2-5d620690a4f0

📥 Commits

Reviewing files that changed from the base of the PR and between 06da0dd and c30f539.

📒 Files selected for processing (5)
  • app/src/main/java/com/poti/android/presentation/party/create/PartyCreateScreen.kt
  • app/src/main/java/com/poti/android/presentation/party/create/PartyCreateViewModel.kt
  • app/src/main/java/com/poti/android/presentation/party/create/component/CreateDeliverySetting.kt
  • app/src/main/java/com/poti/android/presentation/party/create/model/Contracts.kt
  • app/src/main/java/com/poti/android/presentation/party/create/model/DeliveryOptionUiModel.kt

@cmj7271 cmj7271 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

수고많으셨습니닷

@@ -64,8 +65,9 @@ data class CreateUiState(
val isMemberBottomSheetTouched: Boolean = false,
val memberError: FieldError? = null,
val deliveriesState: ApiState<List<DeliveryOption>> = ApiState.Init,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

p3: 사용을 확인해보니까, API 상태만 표현하고 별도로 활용하지 않는 변수같아요

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

맞네요!!

@jyvnee jyvnee left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

수고햇성

@doyeon0307
doyeon0307 merged commit c9f823c into develop Jul 28, 2026
2 checks passed
@github-project-automation github-project-automation Bot moved this from To-do to Done in POTI-ANDROID Jul 28, 2026
@doyeon0307
doyeon0307 deleted the feat/#164-create-delivery-option branch July 28, 2026 11:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🌟 Feat 새로운 기능 구현 🐣 도연 🔎 UI UI 작업

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

[Feat] 등록 배송 가격 수정

3 participants