Skip to content

feat: storeReviews 사진후기 필터(photoOnly)·photoTotalCount 추가 - #171

Merged
chanwoo7 merged 1 commit into
developfrom
feat/store-reviews-photo-filter
Aug 5, 2026
Merged

feat: storeReviews 사진후기 필터(photoOnly)·photoTotalCount 추가#171
chanwoo7 merged 1 commit into
developfrom
feat/store-reviews-photo-filter

Conversation

@chanwoo7

@chanwoo7 chanwoo7 commented Aug 5, 2026

Copy link
Copy Markdown
Member

Summary

FE 요청 반영: 매장 사진후기 화면을 위해 storeReviews에 사진 필터·카운트를 추가한다. productReviews에는 이미 있는 기능으로, 동일 의미론을 미러링한다.

  • StoreReviewsInput.photoOnly: Boolean = false — true면 활성 미디어가 있는 리뷰만 조회
  • StoreReviewConnection.photoTotalCount: Int! — 사진 리뷰 총수. 필터와 무관하게 항상 반환 (productReviews.photoTotalCount와 동일 의미)

배경: 서버 필터 없이 FE가 최신 N건에서 사진 리뷰를 골라내면, 사진 없는 리뷰가 몰린 구간에서 사진후기 그리드가 빈 화면이 되는 문제가 있었다.

Scope

  • store-reviews.graphql — SDL 필드 2개 추가 (additive, 기존 호출 breaking 없음)
  • store-reviews.input.tsphotoOnly 검증 데코레이터 추가
  • store-review.repository.ts — product 쪽 publicReviewWhere 패턴 미러링: media.some(deleted_at: null) 필터, countStoreReviews{ storeId, photoOnly } 시그니처로 변경
  • store-review.service.ts — 목록 + 전체/사진 카운트 병렬 조회
  • store-review-output.type.tsphotoTotalCount 추가

진행 상황

  • SDL/DTO/repository/service/output type 구현
  • codegen 재생성 · yarn dto:check 통과
  • 테스트 추가 (아래 Test plan)
  • yarn validate 통과

Impact

  • 기존 FE 호출은 그대로 동작 (photoOnly 기본 false, photoTotalCount는 additive 필드).
  • 사진후기 그리드: storeReviews(photoOnly: true) + 헤더 카운트 photoTotalCount로 시안 구현 가능.
  • soft-delete된 미디어만 있는 리뷰는 사진후기로 집계·노출되지 않는다.

Test plan

  • service: photoOnly=true면 활성 미디어 있는 리뷰만 반환, totalCount(전체)/photoTotalCount(사진) 분리 검증
  • service: soft-delete된 미디어만 있는 리뷰는 사진후기 제외
  • service: 빈 목록·미디어 포함 목록에서 photoTotalCount 값 검증
  • resolver 통합: photoOnly 입력이 service까지 전달, photoTotalCount 반환 경로 검증
  • 기존 store 스위트 13개(76건) 전체 green

매장 사진후기 화면(FE 요청)을 위해 productReviews와 동일 의미론으로
StoreReviewsInput.photoOnly(기본 false), StoreReviewConnection.photoTotalCount를
추가한다. photoTotalCount는 필터와 무관하게 항상 사진 리뷰 총수.

repository는 product 쪽 publicReviewWhere 패턴을 미러링해 활성 미디어
존재(media.some, soft-delete 제외) 기준으로 필터·카운트한다.
@coderabbitai

coderabbitai Bot commented Aug 5, 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: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: d9be5ac3-fd76-4b36-9413-ecc136007340

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

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 Aug 5, 2026

Copy link
Copy Markdown

🧹 knip — dead-code 리포트

요약 항목 없음
전체 리포트
(knip 출력 없음 — 이슈 0이거나 실행 실패)

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

@github-actions

github-actions Bot commented Aug 5, 2026

Copy link
Copy Markdown

🩺 NestJS Doctor — 89/100 (Good)

진단 270건 (error 0).

Category error warning info
architecture 0 0 13
correctness 0 118 0
performance 0 24 16
schema 0 0 86
security 0 13 0
architecture / security 상위 항목
  • 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.
  • info architecture/architecture/no-barrel-export-internals: Barrel file re-exports internal module '@/features/conversation/repositories/conversation.repository'.
  • info architecture/architecture/no-barrel-export-internals: Barrel file re-exports internal type 'ConversationRepository'.
  • info architecture/architecture/no-barrel-export-internals: Barrel file re-exports internal module '@/features/order/repositories/order.repository'.
  • info architecture/architecture/no-barrel-export-internals: Barrel file re-exports internal type 'OrderRepository'.
  • info architecture/architecture/no-barrel-export-internals: Barrel file re-exports internal module '@/features/product/repositories/product.repository'.

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

@github-actions

github-actions Bot commented Aug 5, 2026

Copy link
Copy Markdown

Coverage report

St.
Category Percentage Covered / Total
🟢 Statements 97.68% 4304/4406
🟢 Branches 93.69% 1366/1458
🟢 Functions 95.62% 830/868
🟢 Lines 98.1% 3922/3998

Test suite run success

1466 tests passing in 173 suites.

Report generated by 🧪jest coverage report action from 5f29ec1

@codecov

codecov Bot commented Aug 5, 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 fd23698 into develop Aug 5, 2026
12 checks passed
@chanwoo7
chanwoo7 deleted the feat/store-reviews-photo-filter branch August 5, 2026 13:39
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