-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathActiveGroupsResponse.java
More file actions
38 lines (35 loc) · 1.07 KB
/
ActiveGroupsResponse.java
File metadata and controls
38 lines (35 loc) · 1.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
package com.ggang.be.api.group.dto;
import com.ggang.be.domain.constant.Category;
import com.ggang.be.domain.constant.GroupType;
import com.ggang.be.domain.constant.WeekDay;
import com.ggang.be.domain.group.dto.GroupVo;
import java.time.LocalDate;
public record ActiveGroupsResponse(
long groupId,
Category category,
int coverImg,
int profileImg,
GroupType groupType,
String groupTitle,
WeekDay weekDay,
LocalDate weekDate,
double startTime,
double endTime,
String location
) {
public static ActiveGroupsResponse fromGroupVo(GroupVo groupVo) {
return new ActiveGroupsResponse(
groupVo.groupId(),
groupVo.category(),
groupVo.coverImg(),
groupVo.profileImg(),
groupVo.groupType(),
groupVo.groupTitle(),
groupVo.weekDay(),
groupVo.weekDate(),
groupVo.startTime(),
groupVo.endTime(),
groupVo.location()
);
}
}