-
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
Upload meme #51
Upload meme #51
Conversation
pjw5521
commented
Sep 25, 2024
•
edited
Loading
edited
- s3 업로드
- createMeme api 수정
- deviceId 필드 추가
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.
LGTM
src/model/meme.ts
Outdated
@@ -55,6 +60,7 @@ export interface IMemeDocument extends Document { | |||
|
|||
const MemeSchema: Schema = new Schema( | |||
{ | |||
deviceId: { type: String, default: '' }, |
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.
여기도
deviceId: { type: String, required: true }
로 변경하고
배포전에 deviceId: 'ADMIN'
으로 일괄 업데이트 해야할 것 같아
deviceId가 ADMIN인 user도 하나 생성하고...
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.
내가 같이 수정함
DB 마이그레이션은 배포 직전에 다시 한 번 이야기 해봅시다
src/routes/meme.ts
Outdated
* keywordIds: | ||
* type: array | ||
* items: | ||
* type: string | ||
* example: "667fee6dc58681a42d57dc37" | ||
* description: 밈의 키워드 id 목록 | ||
* description: "키워드의 ObjectId 배열" | ||
* description: "등록할 키워드의 ObjectId 목록" |
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.
swagger에서 테스트해봤는데 keywordIds가 string[]가 아니고 계속 string 형태로 가서 밈 등록이 안되는데 확인 부탁해 swagger 설정 문제인 것 같은데... 좀 찾아봤는데 어떻게 고쳐야할지 모르겠음
[22:42:31.361] INFO (13453): 667fa549239eeaf786f9aa75,667fa3c824fc9c25eaf3b911
keywordIds: req.body.keywordIds.map((id: string) => new Types.ObjectId(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.
이거 찾아봐도 안나오네... postman에서는 동작하는 거 확인했으니깐 클라쪽에 말해주고 반영할까 ??
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.
굳!