-
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
[POM-94] 가게 이미지 업로드 기능 추가 #38
Conversation
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.
🍒
src/main/java/com/ray/pominowner/store/controller/StoreController.java
Outdated
Show resolved
Hide resolved
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.
👍
@Entity | ||
@EqualsAndHashCode(of = "id") |
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.
BaseTimeEntity를 상속하고 있으니 callSuper = false
해당 부분을 추가하면 좋을 것 같습니다!
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.
callsuper = false는 default라 명시 안했어요
src/main/java/com/ray/pominowner/store/service/StoreImageService.java
Outdated
Show resolved
Hide resolved
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.
👍
📌 설명
기능은 MultipartFile로 이미지 리스트를 받으면, 사용자가 전송한 이미지의 이름, 이미지 이름에서 확장자만 떼어
UUID + 확장자이름
으로 application-dev.yml에 설정한 경로에 저장합니다.따라서 StoreImage 엔티티에서는 경로, 원본 이미지 이름, 저장하는 이미지 이름(uuid)로 관리합니다.
참고
지난 pr시 이름 수정, 양방향 매핑, 자잘한 디렉토리 생성 및 application-dev.yml 설정 수정 등으로 file Changed 수가 좀 많습니다.
여러 파일에서 조금씩 수정하였고, 메인은 StoreImage 엔티티와 StoreImageService입니다.
다음부터 좀 더 잘게 PR을 나눠볼게요