-
Notifications
You must be signed in to change notification settings - Fork 0
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 #45 from kusitms-28th-Meetup-E/feat/contents
Feat/contents
- Loading branch information
Showing
8 changed files
with
145 additions
and
21 deletions.
There are no files selected for viewing
54 changes: 54 additions & 0 deletions
54
src/main/java/gwangjang/server/domain/contents/application/dto/res/ContentsLikeCount.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,54 @@ | ||
package gwangjang.server.domain.contents.application.dto.res; | ||
|
||
import gwangjang.server.domain.contents.domain.entity.constant.ApiType; | ||
import io.swagger.models.auth.In; | ||
import lombok.*; | ||
|
||
@Getter | ||
@Builder | ||
@Setter | ||
@NoArgsConstructor | ||
public class ContentsLikeCount { | ||
private Integer contentsId; | ||
private String url; | ||
private String title; | ||
private String description; | ||
private ApiType type; | ||
private String issueTitle; | ||
private String keyword; | ||
private String pubDate; | ||
private String topic; | ||
private String imgUrl; | ||
private long likeCount; // Change from int to long | ||
private boolean userLiked; | ||
|
||
public ContentsLikeCount( | ||
Integer contentsId, | ||
String url, | ||
String title, | ||
String description, | ||
ApiType type, | ||
String issueTitle, | ||
String keyword, | ||
String pubDate, | ||
String topic, | ||
String imgUrl, | ||
long likeCount, // Change from int to long | ||
boolean userLiked | ||
) { | ||
this.contentsId = contentsId; | ||
this.url = url; | ||
this.title = title; | ||
this.description = description; | ||
this.type = type; | ||
this.issueTitle = issueTitle; | ||
this.keyword = keyword; | ||
this.pubDate = pubDate; | ||
this.topic = topic; | ||
this.imgUrl = imgUrl; | ||
this.likeCount = likeCount; | ||
this.userLiked = userLiked; | ||
} | ||
|
||
// Add getters for all fields | ||
} |
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 |
---|---|---|
|
@@ -20,4 +20,6 @@ public class ContentsRes { | |
private String topic; | ||
private String imgUrl; | ||
|
||
private Long likeCount; | ||
|
||
} |
24 changes: 24 additions & 0 deletions
24
...main/java/gwangjang/server/domain/contents/application/dto/res/ContentsWithLikeCount.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,24 @@ | ||
package gwangjang.server.domain.contents.application.dto.res; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
import gwangjang.server.domain.contents.domain.entity.Contents; | ||
import gwangjang.server.domain.contents.domain.entity.constant.ApiType; | ||
|
||
public class ContentsWithLikeCount { | ||
private Integer contents_id; | ||
private String url; | ||
private String title; | ||
private String description; | ||
ApiType type; | ||
private String issueTitle; | ||
private String keyword; | ||
private String pubDate; | ||
private String topic; | ||
private String imgUrl; | ||
|
||
private Long likeCount; | ||
|
||
private long likeStatus; | ||
|
||
|
||
} |
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
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