Skip to content
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/#54/게시판 게시글 작성 #74

Merged
merged 11 commits into from
Aug 12, 2024

Conversation

arkchive
Copy link
Collaborator

@arkchive arkchive commented Aug 11, 2024

📝 요약

이슈 번호 : #54

🔖 변경 사항

  • PostImage Entity 추가
  • 게시글 작성 api 개발
  • PostImage 객체 생성할 때 Post 객체 생성

✅ 리뷰 요구사항

예외처리 하는 게 감이 잘 잡히지 않아서 조언해주시면 감사하겠습니다!
또한 Post와 PostImage 사이에 매핑도 확인해주시면 감사하겠습니다!

📸 확인 방법 (선택)

image
image
이미지를 넣었는데 리스트가 비어있는 것을 확인했습니다 확인 후 수정하겠습니다

++ 추가 (이미지 테스트 성공)
image
PostImage와 Post 엔티티와 연결이 제대로 안된 듯 싶습니다! 수정하였습니다.


📌 PR 진행 시 이러한 점들을 참고해 주세요

* P1 : 꼭 반영해 주세요 (Request Changes) - 이슈가 발생하거나 취약점이 발견되는 케이스 등
* P2 : 반영을 적극적으로 고려해 주시면 좋을 것 같아요 (Comment)
* P3 : 이런 방법도 있을 것 같아요~ 등의 사소한 의견입니다 (Chore)

@arkchive arkchive self-assigned this Aug 11, 2024
@arkchive arkchive linked an issue Aug 11, 2024 that may be closed by this pull request
Copy link
Member

@hyunn522 hyunn522 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

private String type; // "notice" or "general"
private List<MultipartFile> postImages;

public Post toEntity(User user, Space space, List<PostImage> postImages){
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

p3: 정적 팩토리 메소드 of를 사용하셔도 좋을 것 같아요

public class CreatePostRequest {
private String title;
private String content;
private String type; // "notice" or "general"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

추후에 Enum으로 관리하면 좋을 것 같습니다.

@arkchive arkchive merged commit 6d51fa9 into develop Aug 12, 2024
3 checks passed
@hyunn522 hyunn522 deleted the feat/#54/게시판-게시글-작성 branch August 12, 2024 08:08
seongjunnoh pushed a commit that referenced this pull request Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat: 게시판 게시글 작성
3 participants