-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
특정 사용자가 작성한 리뷰 목록 조회 API 추가 #107
Conversation
* @param userId 사용자 ID | ||
* @param sortBy 정렬 정보 | ||
* @param pageable 페이지 정보 | ||
* @return 리뷰 목록 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* @return 리뷰 목록 | |
* @return 리뷰 목록 | |
* @throws ForbiddenException 정회원이 아닌 회원이 0페이지가 아닌 다른 페이지를 조회하는 경우 | |
* @throws NotFoundException 해당 회원이 존재하지 않는 경우 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chaewss 수정했습니다~
if (loginUser == null || loginUser.getRole() != Role.REGULAR) { | ||
if (pageable.getPageNumber() > 0) { | ||
throw FORBIDDEN_REVIEW; | ||
} else { | ||
pageable = PageRequest.of(pageable.getPageNumber(), 5); | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
해당 부분은 특정 상품 리뷰 목록 조회 API에서도 사용하는 로직이라 모듈화하는건 어떻게 생각하세요?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chaewss 좋은 생각인 것 같아요. 수정했습니다!
src/docs/asciidoc/api-doc.adoc
Outdated
@@ -362,7 +362,25 @@ include::{snippets}/review-controller-test/respond_200_when_success_to_read_prod | |||
==== Sample Response | |||
include::{snippets}/review-controller-test/respond_200_when_success_to_read_product_reviews/http-response.adoc[] | |||
|
|||
=== 4-5. 리뷰 좋아요 추가 | |||
=== 4-5. 특정 사용자의 리뷰 목록 조회 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
저는 특정 회원의 값을 조회하는 api들은 1. 회원
부분에 넣었는데 이 부분 상의해보면 좋을 것 같아요~
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
고생하셨어요👍
🎯 Issue
🔑 Key Changes