-
Notifications
You must be signed in to change notification settings - Fork 1
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
[feat] 모델프로필 단건조회 및 생성 api 완성 #21
Conversation
@Override | ||
public ModelResponse getModel(Long modelId) { | ||
Model model = modelRepository.findById(modelId) | ||
.orElseThrow(() -> new RuntimeException("존재하지 않는 아이디")); |
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.
customexcetpion 으로 해주세요!
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.
NotFoundExceoptioan 적용완뇨
|
||
public record ModelRequest( | ||
@NotNull String modelName, | ||
@NotNull LocalDateTime birth, |
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.
대박
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.
수고하셧슴돠!
import java.time.LocalDate; | ||
|
||
public record ModelRequest( | ||
@NotNull String modelName, |
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.
@NotNull 인자 값으로 message 추가하면 좋을 것 같아요
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.
프론트 입장에서 어떤 필드를 null 값으로 요청해서 에러가 났는지 알아야 하니깐요
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.
네ㅔㅇ베ㅔㅂㅇ
🗃 Issue
🔥 Task
📄 Reference
위의 데이터로 postman 테스트 했습ㄴ다.