Skip to content

Conversation

@kamillcream
Copy link
Contributor

@kamillcream kamillcream commented Sep 16, 2025

📌 PR 개요

  • 추천 관광 코스 조회 응답에 addressId와 관광지별 이미지 주소 포함

✅ 변경사항

  • CourseComponentDto에 addressId와 tourspotImage 추가

🔍 체크리스트

  • PR 제목은 명확한가요?
  • 관련 이슈가 있다면 연결했나요?
  • 로컬 테스트는 통과했나요?
  • 코드에 불필요한 부분은 없나요?

📎 관련 이슈

Closes #


💬 기타 참고사항

Summary by CodeRabbit

  • 신규 기능
    • 코스 구성 요소 응답에 주소 ID(addressId)와 관광지 대표 이미지 URL(tourspotImg) 필드가 추가되었습니다.
    • API 응답이 해당 정보를 포함하도록 생성 로직이 업데이트되었습니다.

@kamillcream kamillcream linked an issue Sep 16, 2025 that may be closed by this pull request
2 tasks
@coderabbitai
Copy link

coderabbitai bot commented Sep 16, 2025

Caution

Review failed

The pull request is closed.

Walkthrough

CourseComponentDto 레코드에 addressId(Long)와 tourspotImg(String) 필드를 추가하고, 생성자 및 from(CourseComponent, CongestionLevel) 팩토리 메서드를 이 필드들을 포함하도록 수정했습니다. TourSpot에서 addressId를, 첫 번째 이미지에서 tourspotImg URL을 추출해 매핑합니다.

Changes

Cohort / File(s) Summary
DTO 업데이트 (CourseComponentDto)
src/main/java/com/opendata/domain/course/dto/response/CourseComponentDto.java
레코드 필드 2개 추가: addressId(Long), tourspotImg(String); 생성자 시그니처 확장; from(CourseComponent, CongestionLevel)에서 tourSpot.getAddress().getAddressId()tourSpot.getImages().get(0).getTourspotImgUrl()로 신규 필드 매핑

Sequence Diagram(s)

sequenceDiagram
    participant Service as CourseService
    participant Domain as CourseComponent / TourSpot
    participant DTO as CourseComponentDto

    Service->>Domain: 조회된 CourseComponent와 CongestionLevel
    Note over Domain: CourseComponent.tourSpot에서<br/>addressId, 첫 이미지 URL 접근
    Domain->>DTO: CourseComponentDto.from(component, level)
    activate DTO
    DTO-->>Service: DTO(tourSpotName, tourspotId, addressId, tourspotImg, congestionLevel, time, lat, lon)
    deactivate DTO
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related issues

Poem

달빛 아래 코스가 반짝, 길표가 생겼네
주소와 사진 손에 쥐고, 토끼는 껑충껑충 🐇
첫 사진 살짝 미소 짓고, 지도가 길을 열고
바람 따라 코스 완성, 밤하늘에 딱! ✨

✨ Finishing touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feat/#96-add-course-api-addressId-image

📜 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 86ad33c and a1c8d3b.

📒 Files selected for processing (1)
  • src/main/java/com/opendata/domain/course/dto/response/CourseComponentDto.java (1 hunks)

Tip

👮 Agentic pre-merge checks are now available in preview!

Pro plan users can now enable pre-merge checks in their settings to enforce checklists before merging PRs.

  • Built-in checks – Quickly apply ready-made checks to enforce title conventions, require pull request descriptions that follow templates, validate linked issues for compliance, and more.
  • Custom agentic checks – Define your own rules using CodeRabbit’s advanced agentic capabilities to enforce organization-specific policies and workflows. For example, you can instruct CodeRabbit’s agent to verify that API documentation is updated whenever API schema files are modified in a PR. Note: Upto 5 custom checks are currently allowed during the preview period. Pricing for this feature will be announced in a few weeks.

Please see the documentation for more information.

Example:

reviews:
  pre_merge_checks:
    custom_checks:
      - name: "Undocumented Breaking Changes"
        mode: "warning"
        instructions: |
          Pass/fail criteria: All breaking changes to public APIs, CLI flags, environment variables, configuration keys, database schemas, or HTTP/GraphQL endpoints must be documented in the "Breaking Change" section of the PR description and in CHANGELOG.md. Exclude purely internal or private changes (e.g., code not exported from package entry points or explicitly marked as internal).

Please share your feedback with us on this Discord post.


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 and usage tips.

@kamillcream kamillcream merged commit 60b0d1e into main Sep 16, 2025
1 of 2 checks passed
@kamillcream kamillcream deleted the feat/#96-add-course-api-addressId-image branch September 16, 2025 08:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[feat] 추천 관광 코스 조회에 addressId과 관광지별 이미지 반환

2 participants