-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #131 from oduck-team/feature/130
작성한 리뷰 목록에 애니 제목 추가 #130
- Loading branch information
Showing
11 changed files
with
133 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 5 additions & 17 deletions
22
src/main/java/io/oduck/api/domain/member/dto/MemberDslDto.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,43 +1,31 @@ | ||
package io.oduck.api.domain.member.dto; | ||
|
||
import lombok.AllArgsConstructor; | ||
import lombok.Builder; | ||
import lombok.Getter; | ||
import lombok.NoArgsConstructor; | ||
|
||
// TODO: VO로 변경 할지 논의 필요 | ||
public class MemberDslDto { | ||
@Getter | ||
@Builder | ||
@NoArgsConstructor | ||
@AllArgsConstructor | ||
public static class ProfileWithoutActivity { | ||
private Long memberId; | ||
private String name; | ||
private String description; | ||
private String thumbnail; | ||
private String backgroundImage; | ||
private Long point; | ||
|
||
@Builder | ||
public ProfileWithoutActivity(Long memberId, String name, String description, String thumbnail, | ||
String backgroundImage, Long point) { | ||
this.memberId = memberId; | ||
this.name = name; | ||
this.description = description; | ||
this.thumbnail = thumbnail; | ||
this.backgroundImage = backgroundImage; | ||
this.point = point; | ||
} | ||
} | ||
|
||
@Getter | ||
@Builder | ||
@NoArgsConstructor | ||
@AllArgsConstructor | ||
public static class MemberActivity { | ||
private Long reviews; | ||
private Long likes; | ||
|
||
@Builder | ||
public MemberActivity(Long reviews, Long likes) { | ||
this.reviews = reviews; | ||
this.likes = likes; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
src/main/java/io/oduck/api/domain/review/repository/ShortReviewRepositoryCustom.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,12 @@ | ||
package io.oduck.api.domain.review.repository; | ||
|
||
import io.oduck.api.domain.review.dto.ShortReviewDslDto.ShortReviewDsl; | ||
import io.oduck.api.domain.review.dto.ShortReviewDslDto.ShortReviewDslWithTitle; | ||
import org.springframework.data.domain.Pageable; | ||
import org.springframework.data.domain.Slice; | ||
|
||
public interface ShortReviewRepositoryCustom { | ||
|
||
Slice<ShortReviewDsl> selectShortReviews(Long animeId, String cursor, Pageable pageable); | ||
Slice<ShortReviewDsl> selectShortReviewsByMemberId(Long memberId, String cursor, Pageable pageable); | ||
Slice<ShortReviewDslWithTitle> selectShortReviewsByMemberId(Long memberId, String cursor, Pageable pageable); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 12 additions & 0 deletions
12
src/main/java/io/oduck/api/global/converter/StringToMemerReviewsConverter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
package io.oduck.api.global.converter; | ||
|
||
import io.oduck.api.domain.review.dto.ShortReviewReqDto.SortForProfile; | ||
import org.springframework.core.convert.converter.Converter; | ||
|
||
public class StringToMemerReviewsConverter implements Converter<String, SortForProfile> { | ||
|
||
@Override | ||
public SortForProfile convert(String sort) { | ||
return SortForProfile.valueOf(sort.toUpperCase()); | ||
} | ||
} |