We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ccd41ba commit d65da0fCopy full SHA for d65da0f
src/main/java/com/moa/moa_server/domain/vote/dto/response/mine/MyVoteItem.java
@@ -17,11 +17,12 @@ public record MyVoteItem(
17
) {
18
19
public static MyVoteItem from(Vote vote, List<VoteOptionResultWithId> results) {
20
+ String status = vote.getClosedAt().isAfter(LocalDateTime.now()) ? "OPEN" : "CLOSED";
21
return new MyVoteItem(
22
vote.getId(),
23
vote.getGroup().getId(),
24
vote.getContent(),
- vote.getVoteStatus().name(),
25
+ status,
26
vote.getCreatedAt(),
27
vote.getClosedAt(),
28
results
0 commit comments