첨부파일 수정
This commit is contained in:
parent
0274183e2e
commit
ec6a3c6dc9
@ -18,7 +18,12 @@
|
|||||||
{{ category }}
|
{{ category }}
|
||||||
</h6>
|
</h6>
|
||||||
<!-- 제목 -->
|
<!-- 제목 -->
|
||||||
<h5 class="card-title">{{ title }}</h5>
|
<h5 class="card-title">
|
||||||
|
{{ title }}
|
||||||
|
<span class="text-muted me-3" v-if="attachment">
|
||||||
|
<i class="fa-solid fa-paperclip"></i>
|
||||||
|
</span>
|
||||||
|
</h5>
|
||||||
<!-- 본문 -->
|
<!-- 본문 -->
|
||||||
<p class="card-text str_wrap">{{ content }}</p>
|
<p class="card-text str_wrap">{{ content }}</p>
|
||||||
<!-- 날짜 -->
|
<!-- 날짜 -->
|
||||||
@ -81,6 +86,10 @@ const props = defineProps({
|
|||||||
type: Number,
|
type: Number,
|
||||||
default: 0,
|
default: 0,
|
||||||
},
|
},
|
||||||
|
attachment: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// computed 속성
|
// computed 속성
|
||||||
|
|||||||
@ -13,6 +13,7 @@
|
|||||||
:views="post.views"
|
:views="post.views"
|
||||||
:likes="post.likes"
|
:likes="post.likes"
|
||||||
:comments="post.comments"
|
:comments="post.comments"
|
||||||
|
:attachment="post.attachment"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -127,6 +127,7 @@ const fetchGeneralPosts = async (page = 1) => {
|
|||||||
views: post.cnt || 0,
|
views: post.cnt || 0,
|
||||||
likes: post.likeCount || 0,
|
likes: post.likeCount || 0,
|
||||||
comments: post.commentCount || 0,
|
comments: post.commentCount || 0,
|
||||||
|
attachment: post.hasAttachment || false,
|
||||||
}));
|
}));
|
||||||
|
|
||||||
// 페이지네이션 정보 업데이트
|
// 페이지네이션 정보 업데이트
|
||||||
@ -165,6 +166,7 @@ const fetchNoticePosts = async () => {
|
|||||||
views: post.cnt || 0,
|
views: post.cnt || 0,
|
||||||
likes: post.likeCount || 0,
|
likes: post.likeCount || 0,
|
||||||
comments: post.commentCount || 0,
|
comments: post.commentCount || 0,
|
||||||
|
attachment: post.hasAttachment || false,
|
||||||
}));
|
}));
|
||||||
} else {
|
} else {
|
||||||
console.error("데이터 오류:", response.data);
|
console.error("데이터 오류:", response.data);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user