메인보드

This commit is contained in:
dyhj625 2025-04-04 16:14:42 +09:00
parent 582030fd5d
commit 080511f428

View File

@ -1,6 +1,15 @@
<template> <template>
<div class="col-md-6 col-lg-4 col-xl-4 order-0 mb-6"> <div class="col-md-6 col-lg-4 col-xl-4 order-0 mb-6">
<div class="card text-center h-100"> <div class="card text-center h-100">
<!-- 더보기 버튼 -->
<div class="modal-foote d-flex">
<router-link
:to="{ name: 'BoardList', query: { type: selectedBoard } }"
class="btn btn-primary mr-1 pe-1 ps-1 ms-auto my-auto h-50"
>
more
</router-link>
</div>
<div class="card-body"> <div class="card-body">
<!-- 모달 본문 --> <!-- 모달 본문 -->
<div class="modal-bod"> <div class="modal-bod">
@ -37,12 +46,10 @@
<tr> <tr>
<!-- 익명게시판은 'nickname', 나머지는 'writer' --> <!-- 익명게시판은 'nickname', 나머지는 'writer' -->
<th class="text-center" style="width: 20%;"> <th class="text-center" style="width: 20%;">
{{ selectedBoard === 'anonymous' ? 'nickname' : 'writer' }} {{ selectedBoard === 'anonymous' ? '닉네임' : '작성자' }}
</th> </th>
<!-- 제목 헤더는 왼쪽 정렬 --> <th class="text-center" style="width: 65%;">제목</th>
<th class="text-start" style="width: 65%;">title</th> </tr>
<th class="text-center" style="width: 15%;">views</th>
</tr>
</thead> </thead>
<tbody> <tbody>
<tr <tr
@ -55,7 +62,7 @@
{{ selectedBoard === 'anonymous' ? post.nickname : post.author }} {{ selectedBoard === 'anonymous' ? post.nickname : post.author }}
</td> </td>
<td class="text-start fs-6"> <td class="text-start fs-6">
<div> <div class="ms-2">
{{ truncateTitle(post.title) }} {{ truncateTitle(post.title) }}
<span v-if="post.commentCount" class="text-danger ml-1 small"> <span v-if="post.commentCount" class="text-danger ml-1 small">
[{{ post.commentCount }}] [{{ post.commentCount }}]
@ -65,12 +72,15 @@
v-if="post.hasAttachment.length > 0" v-if="post.hasAttachment.length > 0"
class="bi bi-paperclip ml-1 small" class="bi bi-paperclip ml-1 small"
></i> ></i>
</div>
<div class="text-muted small small"> <div class="text-muted small small">
{{ post.date }} {{ post.date }}
<span class="ms-1">
<i class="fa-regular fa-eye small me-1"></i>{{post.views}}
</span>
</div> </div>
</div>
</td> </td>
<td class="text-center small">{{ post.views }}</td>
</tr> </tr>
<tr v-if="currentList.length === 0"> <tr v-if="currentList.length === 0">
<td colspan="3" class="text-center text-muted">게시물이 없습니다.</td> <td colspan="3" class="text-center text-muted">게시물이 없습니다.</td>
@ -79,15 +89,6 @@
</table> </table>
</div> </div>
</div> </div>
<!-- 모달 푸터: 더보기 버튼 오른쪽 정렬 -->
<div class="modal-foote d-flex">
<router-link
:to="{ name: 'BoardList', query: { type: selectedBoard } }"
class="btn btn-primary mr-1 pe-1 ps-1 ms-auto my-auto h-50"
>
more
</router-link>
</div>
</div> </div>
</div> </div>
</template> </template>