-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[#125] feat: 모임 홈 개선 - 모임 둘러보기 API 개발
- Loading branch information
Showing
13 changed files
with
241 additions
and
90 deletions.
There are no files selected for viewing
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
32 changes: 32 additions & 0 deletions
32
main/src/main/java/org/sopt/makers/crew/main/entity/meeting/enums/EnMeetingStatus.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,32 @@ | ||
package org.sopt.makers.crew.main.entity.meeting.enums; | ||
|
||
import java.util.Arrays; | ||
import org.sopt.makers.crew.main.common.exception.BadRequestException; | ||
|
||
/** 모임 상태 */ | ||
public enum EnMeetingStatus { | ||
/** 시작 전 */ | ||
BEFORE_START(0), | ||
|
||
/** 지원 가능 */ | ||
APPLY_ABLE(1), | ||
|
||
/** 모집 완료 */ | ||
RECRUITMENT_COMPLETE(2); | ||
|
||
private final int value; | ||
|
||
EnMeetingStatus(int value) { | ||
this.value = value; | ||
} | ||
|
||
public static EnMeetingStatus ofValue(int dbData) { | ||
return Arrays.stream(EnMeetingStatus.values()).filter(v -> v.getValue() == (dbData)).findFirst() | ||
.orElseThrow(() -> new BadRequestException( | ||
String.format("EnMeetingStatus 클래스에 value = [%s] 값을 가진 enum 객체가 없습니다.", dbData))); | ||
} | ||
|
||
public int getValue() { | ||
return value; | ||
} | ||
} |
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
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
58 changes: 58 additions & 0 deletions
58
...g/sopt/makers/crew/main/meeting/v2/dto/response/MeetingV2GetMeetingBannerResponseDto.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,58 @@ | ||
package org.sopt.makers.crew.main.meeting.v2.dto.response; | ||
|
||
import java.time.LocalDateTime; | ||
import java.util.List; | ||
import java.util.Optional; | ||
import org.sopt.makers.crew.main.entity.meeting.enums.MeetingCategory; | ||
import org.sopt.makers.crew.main.entity.meeting.enums.MeetingJoinablePart; | ||
import org.sopt.makers.crew.main.entity.meeting.vo.ImageUrlVO; | ||
import lombok.AllArgsConstructor; | ||
import lombok.Getter; | ||
|
||
@Getter | ||
@AllArgsConstructor(staticName = "of") | ||
public class MeetingV2GetMeetingBannerResponseDto { | ||
|
||
/** 모임 ID */ | ||
private Integer id; | ||
/** 유저 Crew ID */ | ||
private Integer userId; | ||
/** 모임 제목 */ | ||
private String title; | ||
/** | ||
* 모임 카테고리 | ||
* | ||
* @apiNote '스터디', '행사' | ||
*/ | ||
private MeetingCategory category; | ||
/** | ||
* 썸네일 이미지 | ||
* | ||
* @apiNote 여러개여도 첫번째 이미지만 사용 | ||
*/ | ||
private List<ImageUrlVO> imageURL; | ||
/** 모임 지원 시작일 */ | ||
private LocalDateTime startDate; | ||
/** 모임 지원 종료일 */ | ||
private LocalDateTime endDate; | ||
/** 모임 활동 시작일 */ | ||
private LocalDateTime mStartDate; | ||
/** 모임 활동 종료일 */ | ||
private LocalDateTime mEndDate; | ||
/** 모임 인원 */ | ||
private Integer capacity; | ||
/** 최근 활동 일자 */ | ||
private Optional<LocalDateTime> recentActivityDate; | ||
/** 모임 타겟 기수 */ | ||
private Integer targetActiveGeneration; | ||
/** 모임 타겟 파트 */ | ||
private MeetingJoinablePart[] joinableParts; | ||
/** 지원자 수 */ | ||
private Integer applicantCount; | ||
/** 가입된 지원자 수 */ | ||
private Integer approvedUserCount; | ||
/** 개설자 정보 */ | ||
private Optional<MeetingV2GetMeetingBannerResponseUserDto> user; | ||
/** 미팅 상태 */ | ||
private Integer status; | ||
} |
17 changes: 17 additions & 0 deletions
17
...pt/makers/crew/main/meeting/v2/dto/response/MeetingV2GetMeetingBannerResponseUserDto.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,17 @@ | ||
package org.sopt.makers.crew.main.meeting.v2.dto.response; | ||
|
||
import lombok.AllArgsConstructor; | ||
import lombok.Getter; | ||
|
||
@Getter | ||
@AllArgsConstructor(staticName = "of") | ||
public class MeetingV2GetMeetingBannerResponseUserDto { | ||
/** 개설자 crew ID */ | ||
private Integer id; | ||
/** 개설자 */ | ||
private String name; | ||
/** 개설자 playground ID */ | ||
private Integer orgId; | ||
/** 프로필 사진 */ | ||
private String profileImage; | ||
} |
3 changes: 3 additions & 0 deletions
3
main/src/main/java/org/sopt/makers/crew/main/meeting/v2/service/MeetingV2Service.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 |
---|---|---|
@@ -1,11 +1,14 @@ | ||
package org.sopt.makers.crew.main.meeting.v2.service; | ||
|
||
import java.util.List; | ||
import org.sopt.makers.crew.main.meeting.v2.dto.query.MeetingV2GetAllMeetingByOrgUserQueryDto; | ||
import org.sopt.makers.crew.main.meeting.v2.dto.response.MeetingV2GetAllMeetingByOrgUserDto; | ||
import org.sopt.makers.crew.main.meeting.v2.dto.response.MeetingV2GetMeetingBannerResponseDto; | ||
|
||
public interface MeetingV2Service { | ||
|
||
MeetingV2GetAllMeetingByOrgUserDto getAllMeetingByOrgUser( | ||
MeetingV2GetAllMeetingByOrgUserQueryDto queryDto); | ||
|
||
List<MeetingV2GetMeetingBannerResponseDto> getMeetingBanner(); | ||
} |
Oops, something went wrong.