Skip to content

Commit

Permalink
Merge pull request #23 from f-lab-edu/refactor/22
Browse files Browse the repository at this point in the history
refactor: 독서 시작일, 종료일 변수명 변경
  • Loading branch information
dani820 authored Sep 15, 2024
2 parents 2a8266c + f320080 commit ea2702e
Show file tree
Hide file tree
Showing 9 changed files with 20 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
public record ContentRequest(
String title,
String content,
String fromDate,
String toDate,
String readingStartDate,
String readingEndDate,
double rating,
String isPublic
) {
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/com/inmybook/adapter/in/web/dto/PostMapper.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ public RegisterPostCommand createRegisterPostCommand(RegisterPostInput registerP
.publisher(registerPostInput.book().publisher())
.title(registerPostInput.content().title())
.content(registerPostInput.content().content())
.fromDate(registerPostInput.content().fromDate())
.toDate(registerPostInput.content().toDate())
.readingStartDate(registerPostInput.content().readingStartDate())
.readingEndDate(registerPostInput.content().readingEndDate())
.rating(registerPostInput.content().rating())
.isPublic(registerPostInput.content().isPublic())
.memberId(registerPostInput.member().memberId())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ public record RegisterPostCommand(
@NotNull
String title,
String content,
String fromDate,
String toDate,
String readingStartDate,
String readingEndDate,
double rating,
String isPublic,
@NotNull
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
public record ContentDetailsOutput(
String title,
String content,
String fromDate,
String toDate,
String readingStartDate,
String readingEndDate,
double rating,
int likeCount,
int bookmarkCount,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ public PostDetailsOutput findPostById(ReadPostInput readPostInput) {
ContentDetailsOutput contentDetailsOutput = ContentDetailsOutput.builder()
.title(post.getContent().getTitle())
.content(post.getContent().getContent())
.fromDate(post.getContent().getFromDate())
.toDate(post.getContent().getToDate())
.readingStartDate(post.getContent().getReadingStartDate())
.readingEndDate(post.getContent().getReadingEndDate())
.rating(post.getContent().getRating())
.likeCount(post.getContent().getLikeCount())
.bookmarkCount(post.getContent().getBookmarkCount())
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/com/inmybook/domain/post/Content.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
public class Content {
private String title;
private String content;
private String fromDate;
private String toDate;
private String readingStartDate;
private String readingEndDate;
@Builder.Default
private double rating = 0;
@Builder.Default
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/com/inmybook/domain/post/PostFactory.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ public Post createPost(RegisterPostCommand registerPostCommand) {
Content content = Content.builder()
.title(registerPostCommand.title())
.content(registerPostCommand.content())
.fromDate(registerPostCommand.fromDate())
.toDate(registerPostCommand.toDate())
.readingStartDate(registerPostCommand.readingStartDate())
.readingEndDate(registerPostCommand.readingEndDate())
.rating(registerPostCommand.rating())
.likeCount(0)
.bookmarkCount(0)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ void readPost() {
Content content = Content.builder()
.title("HTTP 완벽 가이드 독서록")
.content("유익합니다.")
.fromDate("2024-07-14")
.toDate("2024-07-21")
.readingStartDate("2024-07-14")
.readingEndDate("2024-07-21")
.rating(4.5)
.likeCount(0)
.bookmarkCount(0)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ void registerPostWithUploadImgTest() {
.publisher("인사이트")
.title("HTTP 완벽 가이드 독서록")
.content("유익합니다.")
.fromDate("2024-07-14")
.toDate("2024-07-21")
.readingStartDate("2024-07-14")
.readingEndDate("2024-07-21")
.rating(4.5)
.isPublic("Y")
.memberId("dani820")
Expand Down Expand Up @@ -76,8 +76,8 @@ void registerPostWithoutUploadImgTest() {
.publisher("인사이트")
.title("HTTP 완벽 가이드 독서록")
.content("유익합니다.")
.fromDate("2024-07-14")
.toDate("2024-07-21")
.readingStartDate("2024-07-14")
.readingEndDate("2024-07-21")
.rating(4.5)
.isPublic("Y")
.memberId("dani820")
Expand Down

0 comments on commit ea2702e

Please sign in to comment.