-
Notifications
You must be signed in to change notification settings - Fork 2
[Plan] CRUD를 위한 전체적인 구조 추가 및 변경 #76
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
f39e7e3
refactor: DTO 응답 파일 이름 & 구조 변경
kms152000 1ac01cb
refactor: Entity 파일 이름 & 구조 변경
kms152000 ca7d330
refactor: Repository 파일 이름 & 구조 변경
kms152000 e4b948b
feat: 에러 코드 정의
kms152000 971a8f0
feat: Plan & Schedule CRUD 작업
kms152000 9795644
Merge branch 'main' into feat/#44
kms152000 7be9721
Merge branch 'main' into feat/#44
kms152000 e1b322e
refactor: RsData.success 통일 작업
kms152000 878a9b5
feat: LocalDate 검증 추가
kms152000 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
15 changes: 11 additions & 4 deletions
15
src/main/java/com/back/web7_9_codecrete_be/domain/plans/dto/request/PlanAddRequest.java
This file contains hidden or 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,19 +1,26 @@ | ||
| package com.back.web7_9_codecrete_be.domain.plans.dto.request; | ||
|
|
||
| import jakarta.validation.constraints.FutureOrPresent; | ||
| import jakarta.validation.constraints.NotBlank; | ||
| import jakarta.validation.constraints.NotNull; | ||
| import jakarta.validation.constraints.Size; | ||
| import lombok.Getter; | ||
| import lombok.NoArgsConstructor; | ||
|
|
||
| import java.time.LocalDate; | ||
|
|
||
|
|
||
| @Getter | ||
| @NoArgsConstructor | ||
| public class PlanAddRequest { | ||
| @NotNull(message = "콘서트 ID는 필수입니다.") | ||
| private Long concertId; | ||
|
|
||
| @NotBlank(message = "제목은 필수입니다.") | ||
| @Size(max = 30, message = "제목은 30자 이하여야 합니다.") | ||
| @Size(max = 100, message = "제목은 100자 이하여야 합니다.") | ||
| private String title; | ||
|
|
||
| @NotBlank(message = "날짜는 필수입니다.") | ||
| @Size(max = 30, message = "날짜는 30자 이하여야 합니다.") | ||
| private String date; | ||
| @NotNull(message = "날짜는 필수입니다.") | ||
| @FutureOrPresent(message = "날짜는 현재 또는 미래 날짜여야 합니다.") | ||
| private LocalDate planDate; | ||
| } | ||
This file contains hidden or 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 hidden or 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
14 changes: 14 additions & 0 deletions
14
...m/back/web7_9_codecrete_be/domain/plans/dto/request/PlanParticipantRoleUpdateRequest.java
This file contains hidden or 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,14 @@ | ||
| package com.back.web7_9_codecrete_be.domain.plans.dto.request; | ||
|
|
||
| import com.back.web7_9_codecrete_be.domain.plans.entity.PlanParticipant; | ||
| import jakarta.validation.constraints.NotNull; | ||
| import lombok.Getter; | ||
| import lombok.NoArgsConstructor; | ||
|
|
||
| @Getter | ||
| @NoArgsConstructor | ||
| public class PlanParticipantRoleUpdateRequest { | ||
|
|
||
| @NotNull(message = "역할은 필수입니다.") | ||
| private PlanParticipant.ParticipantRole role; | ||
| } |
12 changes: 6 additions & 6 deletions
12
src/main/java/com/back/web7_9_codecrete_be/domain/plans/dto/request/PlanUpdateRequest.java
This file contains hidden or 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,19 +1,19 @@ | ||
| package com.back.web7_9_codecrete_be.domain.plans.dto.request; | ||
|
|
||
| import jakarta.validation.constraints.NotBlank; | ||
| import jakarta.validation.constraints.FutureOrPresent; | ||
| import jakarta.validation.constraints.Size; | ||
| import lombok.Getter; | ||
| import lombok.NoArgsConstructor; | ||
|
|
||
| import java.time.LocalDate; | ||
|
|
||
|
|
||
| @Getter | ||
| @NoArgsConstructor | ||
| public class PlanUpdateRequest { | ||
| @NotBlank(message = "제목은 필수입니다.") | ||
| @Size(max = 30, message = "제목은 30자 이하여야 합니다.") | ||
| @Size(max = 100, message = "제목은 100자 이하여야 합니다.") | ||
| private String title; | ||
|
|
||
| @NotBlank(message = "날짜는 필수입니다.") | ||
| @Size(max = 30, message = "날짜는 30자 이하여야 합니다.") | ||
| private String date; | ||
| @FutureOrPresent(message = "날짜는 현재 또는 미래 날짜여야 합니다.") | ||
| private LocalDate planDate; | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LocalDate 부분도 데이터 검증이 가능합니다. 해당 부분 찾아보시고 추가해주시면 좋을 것 같습니다.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
확인 감사합니다! 바로 수정해보겠습니다.