Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 13 additions & 12 deletions src/pages/homecheck/HomeWrite.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -104,25 +104,26 @@ const HomeWrite = () => {

// βœ… 리뷰 정보 μΆ”κ°€
formData.append(
'createReviewRequest',
new Blob(
[JSON.stringify({
experienceId: 1, // κ²½ν—˜ ID
score: score,
endDate: endDate,
content: feelingText,
})],
{ type: 'application/json' } // λͺ…μ‹œμ μœΌλ‘œ JSON으둜 μ„€μ •
)
);
'createReviewRequest',
JSON.stringify({
experienceId: 1, // κ²½ν—˜ ID (ν•„μš” μ‹œ λ™μ μœΌλ‘œ μ„€μ •)
score: score,
endDate: endDate,
content: feelingText,
})
);

// βœ… 이미지 파일 μΆ”κ°€
uploadedImages.forEach((img) => {
formData.append('images', img.file);
});

try {
const response = await instance.post('/reviews', formData);
const response = await instance.post('/reviews', formData, {
headers: {
'Content-Type': 'application/json',
},
});

if (response.status === 200) {
alert('리뷰가 μ„±κ³΅μ μœΌλ‘œ λ“±λ‘λ˜μ—ˆμŠ΅λ‹ˆλ‹€.');
Expand Down
2 changes: 1 addition & 1 deletion src/pages/onboarding/Onboarding.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const Onboarding = () => {
};

const GotoStart = () => {
navigate('/login');
navigate('/signup');
}
return (
<div className='onboarding_container'>
Expand Down