From e4df1117250f55bda318f60fe531722a3889126e Mon Sep 17 00:00:00 2001 From: kimdaae328 Date: Fri, 24 Jan 2025 15:39:30 +0900 Subject: [PATCH] =?UTF-8?q?=EC=8D=B8=EB=84=A4=EC=9D=BC=20=EC=9D=B4?= =?UTF-8?q?=EB=AF=B8=EC=A7=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/list/BoardCard.vue | 8 ++++---- src/views/board/BoardList.vue | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/components/list/BoardCard.vue b/src/components/list/BoardCard.vue index e7468f0..1ddac0f 100644 --- a/src/components/list/BoardCard.vue +++ b/src/components/list/BoardCard.vue @@ -2,7 +2,7 @@
-
+
이미지
{{ content }}
-
+
{{ formattedDate }} -
+
{{ views || 0 }} @@ -94,7 +94,7 @@ const props = defineProps({ // computed 속성 const contentColClass = computed(() => { - return props.img ? 'col-md-10 col-12' : 'col-md-12'; + return props.img ? 'col-sm-10 col-12' : 'col-sm-12'; }); // formattedDate을 computed로 정의 diff --git a/src/views/board/BoardList.vue b/src/views/board/BoardList.vue index a56cc80..3b173dc 100644 --- a/src/views/board/BoardList.vue +++ b/src/views/board/BoardList.vue @@ -131,7 +131,7 @@ const fetchGeneralPosts = async (page = 1) => { generalList.value = data.list.map((post, index) => ({ ...post, id: post.id || index, - img: post.img || null, + img: post.firstImageUrl || null, views: post.cnt || 0, likes: post.likeCount != null ? post.likeCount : null, comments: post.commentCount != null ? post.commentCount : null, @@ -171,7 +171,7 @@ const fetchNoticePosts = async () => { noticeList.value = response.data.data.map((post, index) => ({ ...post, id: post.id || index, - img: post.img || null, + img: post.firstImageUrl || null, views: post.cnt || 0, attachment: post.hasAttachment || false, content: post.plainContent || '',