콘솔 삭제

This commit is contained in:
kimdaae328 2025-02-03 14:02:50 +09:00
parent fbf13fda33
commit 2e013a54be

View File

@ -116,9 +116,7 @@ const goToEditPage = () => {
const fetchBoardDetails = async () => { const fetchBoardDetails = async () => {
try { try {
const response = await axios.get(`board/${currentBoardId.value}`); const response = await axios.get(`board/${currentBoardId.value}`);
console.log('전체 응답 데이터:', response.data);
const data = response.data.data; const data = response.data.data;
console.log('data 내부 데이터:', data);
// API // API
const boardDetail = data.boardDetail || {}; const boardDetail = data.boardDetail || {};
@ -135,7 +133,6 @@ const fetchBoardDetails = async () => {
attachments.value = data.attachments || []; attachments.value = data.attachments || [];
comments.value = data.comments || []; comments.value = data.comments || [];
} catch (error) { } catch (error) {
console.error('게시물 가져오기 오류:', error);
alert('게시물 데이터를 불러오는 중 오류가 발생했습니다.'); alert('게시물 데이터를 불러오는 중 오류가 발생했습니다.');
} }
}; };
@ -147,12 +144,9 @@ const currentDislikeCount = ref(2);
const handleUpdateReaction = async ({ type, boardId, commentId }) => { const handleUpdateReaction = async ({ type, boardId, commentId }) => {
try { try {
const cmtId = commentId !== null ? commentId : 0; const cmtId = commentId !== null ? commentId : 0;
console.log(`Sending reaction: type=${type}, boardId=${boardId}, commentId=${cmtId}`);
const response = await axios.post(`/board/${boardId}/${cmtId}/reaction`, { type }); const response = await axios.post(`/board/${boardId}/${cmtId}/reaction`, { type });
console.log('API Response:', response.data);
} catch (error) { } catch (error) {
console.error('반응 업데이트 오류:', error.response ? error.response.data : error);
alert('반응을 업데이트하는 중 오류 발생'); alert('반응을 업데이트하는 중 오류 발생');
} }
}; };