This commit is contained in:
dyhj625 2025-04-01 11:44:45 +09:00
parent 5cb43eac9f
commit c6f2743d82

View File

@ -80,7 +80,7 @@
></div>
<!-- 좋아요 버튼 -->
<div v-if="unknown" class="row justify-content-center my-10">
<div v-if="!type" class="row justify-content-center my-10">
<BoardRecommendBtn
:bigBtn="true"
:boardId="currentBoardId"
@ -92,7 +92,7 @@
@updateReaction="handleUpdateReaction"
/>
</div>
<div v-if="unknown" >
<div v-if="!type" >
<!-- 댓글 입력 영역 -->
<BoardCommentArea
:profileName="profileName"
@ -106,7 +106,7 @@
</div>
<!-- 댓글 목록 -->
<div v-if="unknown" class="card-footer">
<div v-if="!type" class="card-footer">
<BoardCommentList
:unknown="unknown"
:comments="commentsWithAuthStatus"
@ -230,6 +230,7 @@
const isDeleted = ref(true);
const commentAlert = ref('');
const boardPasswordAlert = ref('');
const type = ref('');
const updatePassword = newPassword => {
password.value = newPassword;
@ -257,10 +258,13 @@
//
const fetchBoardDetails = async () => {
const { data } = await axios.get(`board/${currentBoardId.value}`);
console.log(data)
if (data?.data) {
const boardData = data.data;
profileName.value = boardData.author || '익명';
authorId.value = boardData.authorId;
type.value = boardData.type === '300103';
console.log('type 값은 →', type.value, ' / 타입은 →', typeof type.value);
boardTitle.value = boardData.title || '제목 없음';
boardContent.value = boardData.content || '';
profileImg.value = boardData.profileImg || '';