Skip to content

Commit

Permalink
πŸ› [FIX] popularRate κ΄€λ ¨ 였λ₯˜ μˆ˜μ • #80
Browse files Browse the repository at this point in the history
  • Loading branch information
eeddiinn committed Mar 27, 2024
1 parent bee359d commit 042631e
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions src/main/java/org/sopt/lequuServer/domain/book/model/Book.java
Original file line number Diff line number Diff line change
Expand Up @@ -64,18 +64,22 @@ public void addFavorite(Favorite favorite) {
favorites.add(favorite);
}

@Column(nullable = false)
private int popularRate;

@Builder
public Book(String uuid, String favoriteName, String favoriteImage, String title, String description, String backgroundColor, Member member) {
public Book(String uuid, String favoriteName, String favoriteImage, String title, String description, String backgroundColor, Member member, int popularRate) {
this.uuid = uuid;
this.favoriteName = favoriteName;
this.favoriteImage = favoriteImage;
this.title = title;
this.description = description;
this.backgroundColor = backgroundColor;
this.member = member;
this.popularRate = popularRate;
}

public static Book of(String uuid, String favoriteName, String favoriteImage, String title, String description, String backgroundColor, Member member) {
return new Book(uuid, favoriteName, favoriteImage, title, description, backgroundColor, member);
public static Book of(String uuid, String favoriteName, String favoriteImage, String title, String description, String backgroundColor, Member member, int popularRate) {
return new Book(uuid, favoriteName, favoriteImage, title, description, backgroundColor, member, popularRate);
}
}

0 comments on commit 042631e

Please sign in to comment.