-
Notifications
You must be signed in to change notification settings - Fork 0
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
feat : 최근 상품 코멘트 조회 api #57
Conversation
.where(productComment.valid.isTrue) | ||
.orderBy(productComment.productCommentId.desc()) | ||
.select(productDetailVOProjection()) | ||
.limit(10) |
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.
이렇게 query에 조회 size 매직넘버 다는것보다, 메소드 파람으로 들고오는게 맞아보여요
productDetailVOProjection 보다 ProductComment로 뽑아내고
코멘트 도메인이 자주 쓰일거라 ProductComment에 조인된 애들 Lazy로 걸어 놓는게 나을거 맞을거 같아요. Product 쪽 참고
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.
쿼리 고치는김에, 무한 스크롤대비 offset 조회로 만들면 좋을듯
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.
반영했습니다!
…-Team-1-BE into feature/geng/issue-56-recent-comment
@JoinColumn(name = "productId", referencedColumnName = "productId", insertable = false, updatable = false) | ||
@JoinColumn(name = "memberId", referencedColumnName = "memberId", insertable = false, updatable = false) | ||
val memberProductLikeMappingList: Set<MemberProductLikeMapping> = setOf() | ||
): BaseEntity(), Serializable |
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.
복합키로 테이블 가져오려면 Serializable 을 implement 해야한다는데 이 부분 괜찮을까요
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.
앗... 그럼 그냥 VO 처리해요.
그리고 OneToMany 가져가는 애들 편의를 위해 fetchJoin 처리 하자는거여서
ManyToOne 은 예전 형태로 해주세요... 원복처리 쏘리...
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.
넵 commentDetailVO 로 롤백할게요 😥
개요
작업사항
변경로직
api/comment
domain/comment
참고사항
ProductCommentLike
작업 후 수정 가능성 있음