Skip to content

fix: 판매자가 숨김 상품 상세를 열 수 있게 - #491

Merged
chanwoo7 merged 1 commit into
developfrom
fix/seller-hidden-product-detail
Oct 4, 2026
Merged

chanwoo7 merged 1 commit into
developfrom
fix/seller-hidden-product-detail

Conversation

@chanwoo7

@chanwoo7 chanwoo7 commented Oct 4, 2026

Copy link
Copy Markdown
Member

배경

  • 이슈 #447입니다. 판매자 상품 목록(sellerProducts)은 숨긴 상품도 보여 주는데, 상세(sellerProduct)만 is_active: true로 찾아 숨긴 자기 상품을 열면 PRODUCT_NOT_FOUND가 났습니다.

변경

  • sellerProduct가 findProductByIdIncludingInactive를 쓰게 바꿨습니다.
    • 판매자의 수정·옵션·분류 경로가 이미 쓰는 메서드이고, 소유 매장 범위(store_id)와 삭제 상품 제외는 그대로입니다.
    • 두 메서드의 include가 같아 응답 매핑은 바뀌지 않습니다.
  • 호출처가 없어진 findProductById를 지웠습니다.
    • repository spec의 매장 불일치·카테고리/태그 삭제 가드 케이스는 남은 메서드 쪽으로 옮겼습니다.

테스트

  • 숨긴 자기 상품의 상세가 isActive: false로 돌아오는 케이스를 추가했습니다. 수정을 되돌리면 PRODUCT_NOT_FOUND로 실패하는 것을 확인했습니다.
  • 삭제한 상품은 계속 PRODUCT_NOT_FOUND인 케이스를 추가했습니다. 다른 매장 상품 케이스는 기존 것을 그대로 둡니다.

플랜 대조

플랜 3번 불릿 상태
findProductByIdIncludingInactive로 전환(소유권·삭제 제외 유지) 한 것
회귀: 숨긴 자기 상품 상세 반환 한 것
회귀: 삭제 상품·다른 매장 상품은 PRODUCT_NOT_FOUND 한 것

- sellerProducts는 숨김(is_active=false) 상품도 보여주는데 sellerProduct만 is_active: true인 findProductById를 써서 목록에서 연 숨김 상품이 PRODUCT_NOT_FOUND
- sellerProduct를 findProductByIdIncludingInactive로 전환(lifecycle·option·taxonomy 판매자 경로와 같은 메서드, store_id 소유 범위 그대로, soft-delete는 루트 findFirst가 제외)
  - 두 메서드 include가 동일해 toProductOutput 매핑은 변화 없음
  - 호출처가 없어진 findProductById 삭제, repository spec의 store_id 불일치·카테고리/태그 삭제 가드 케이스는 남은 메서드로 이전
- 회귀: 숨김 본인 상품 상세는 isActive false로 반환(수정 전 PRODUCT_NOT_FOUND로 실패 확인), soft-delete 상품은 PRODUCT_NOT_FOUND 유지
@coderabbitai

coderabbitai Bot commented Oct 4, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration
  • Configuration used: Repository: CaQuick/caquick-be/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: d8f7a8c4-e03b-472a-8bc2-960612ce1afe

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

@github-actions

github-actions Bot commented Oct 4, 2026

Copy link
Copy Markdown

🧹 knip — dead-code 리포트

Unused exported types (1)
전체 리포트
Unused exported types (1)
RateLimitPolicy  type  src/global/rate-limit/index.ts:4:8

청소 후보(오탐 가능) · 기준 docs/guide/architecture-conventions.md

@github-actions

github-actions Bot commented Oct 4, 2026

Copy link
Copy Markdown

🩺 NestJS Doctor — 90/100 (Excellent)

진단 469건 (error 12).

Category error warning info
architecture 1 1 42
correctness 0 260 0
performance 0 30 28
schema 0 0 75
security 11 21 0
architecture / security 상위 항목
  • error architecture/architecture/no-manual-instantiation: Manual instantiation of 'OutboxRepository' detected. Use dependency injection instead.
  • info architecture/architecture/no-barrel-export-internals: Barrel file re-exports internal type 'IAuditLogRepository'.
  • warning security/security/no-exposed-env-vars: Direct 'process.env.NODE_ENV' access in 'AuthController'. Use ConfigService instead.
  • warning security/security/require-guards-on-endpoints: Endpoint 'start' has no @UseGuards() at class or method level.
  • warning security/security/require-guards-on-endpoints: Endpoint 'callback' has no @UseGuards() at class or method level.
  • warning security/security/require-guards-on-endpoints: Endpoint 'refresh' has no @UseGuards() at class or method level.
  • warning security/security/require-guards-on-endpoints: Endpoint 'logout' has no @UseGuards() at class or method level.
  • warning security/security/require-guards-on-endpoints: Endpoint 'sellerLogin' has no @UseGuards() at class or method level.
  • warning security/security/require-guards-on-endpoints: Endpoint 'sellerRefresh' has no @UseGuards() at class or method level.
  • warning security/security/require-guards-on-endpoints: Endpoint 'sellerLogout' has no @UseGuards() at class or method level.
  • warning security/security/require-guards-on-endpoints: Endpoint 'devIssueToken' has no @UseGuards() at class or method level.
  • warning security/security/require-guards-on-endpoints: Endpoint 'adminLogin' has no @UseGuards() at class or method level.
  • warning security/security/require-guards-on-endpoints: Endpoint 'adminRefresh' has no @UseGuards() at class or method level.
  • warning security/security/require-guards-on-endpoints: Endpoint 'adminLogout' has no @UseGuards() at class or method level.
  • warning security/security/require-guards-on-endpoints: Endpoint 'getJwks' has no @UseGuards() at class or method level.

오탐 포함 가능 · 기준 docs/guide/architecture-conventions.md

@github-actions

github-actions Bot commented Oct 4, 2026

Copy link
Copy Markdown

Coverage report

St.❔
Category Percentage Covered / Total
🟢 Statements 97.91% 10043/10257
🟢 Branches 92.41% 3785/4096
🟢 Functions 97.44% 2020/2073
🟢 Lines 98.51% 9137/9275

Test suite run success

3730 tests passing in 355 suites.

Report generated by 🧪jest coverage report action from 471bd85

@codecov

codecov Bot commented Oct 4, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@chanwoo7
chanwoo7 merged commit 6ab836b into develop Oct 4, 2026
13 checks passed
@chanwoo7
chanwoo7 deleted the fix/seller-hidden-product-detail branch October 4, 2026 16:01
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.

1 participant