Files
sam-manage/resources/views/customer-center/partials/table.blade.php
kent b992886fca feat(mng): 고객센터 게시판 목록 페이지 추가
- /customer-center 라우트 신규 생성
- 활성화된 시스템 게시판만 표시
- 테이블 컬럼: ID, 유형, 코드, 게시판명, 게시글 수, 생성일
- 관리 기능(구분, 필드, 상태, 액션) 제외한 읽기 전용 뷰

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 20:50:58 +09:00

72 lines
3.5 KiB
PHP

<!-- 고객센터 게시판 테이블 -->
<div class="bg-white rounded-lg shadow-sm overflow-hidden">
<x-table-swipe>
<table class="min-w-full divide-y divide-gray-200">
<thead class="bg-gray-50">
<tr>
<th class="px-3 py-2 text-center text-sm font-semibold text-gray-700 uppercase tracking-wider whitespace-nowrap">ID</th>
<th class="px-3 py-2 text-center text-sm font-semibold text-gray-700 uppercase tracking-wider whitespace-nowrap">유형</th>
<th class="px-3 py-2 text-center text-sm font-semibold text-gray-700 uppercase tracking-wider whitespace-nowrap">코드</th>
<th class="px-3 py-2 text-center text-sm font-semibold text-gray-700 uppercase tracking-wider whitespace-nowrap">게시판명</th>
<th class="px-3 py-2 text-center text-sm font-semibold text-gray-700 uppercase tracking-wider whitespace-nowrap">게시글 </th>
<th class="px-3 py-2 text-center text-sm font-semibold text-gray-700 uppercase tracking-wider whitespace-nowrap">생성일</th>
</tr>
</thead>
<tbody class="bg-white divide-y divide-gray-200">
@forelse($boards as $board)
<tr class="hover:bg-gray-50 cursor-pointer" onclick="window.location='{{ route('boards.posts.index', $board->id) }}'">
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-900">
{{ $board->id }}
</td>
<td class="px-6 py-4 whitespace-nowrap">
@if($board->board_type)
<span class="px-2 inline-flex text-xs leading-5 font-semibold rounded-full
@switch($board->board_type)
@case('notice') bg-purple-100 text-purple-800 @break
@case('qna') bg-blue-100 text-blue-800 @break
@case('faq') bg-green-100 text-green-800 @break
@case('free') bg-gray-100 text-gray-800 @break
@default bg-yellow-100 text-yellow-800
@endswitch
">
{{ $board->board_type }}
</span>
@else
<span class="text-gray-400">-</span>
@endif
</td>
<td class="px-6 py-4 whitespace-nowrap text-sm">
<span class="font-mono text-blue-600">{{ $board->board_code }}</span>
</td>
<td class="px-6 py-4 whitespace-nowrap">
<div class="text-sm font-medium text-gray-900">{{ $board->name }}</div>
@if($board->description)
<div class="text-sm text-gray-500 truncate max-w-xs">{{ $board->description }}</div>
@endif
</td>
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-500 text-center">
<span class="px-2 py-1 bg-blue-50 text-blue-700 rounded-full">{{ $board->posts_count }}</span>
</td>
<td class="px-6 py-4 whitespace-nowrap text-sm text-gray-500">
{{ $board->created_at->format('Y-m-d') }}
</td>
</tr>
@empty
<tr>
<td colspan="6" class="px-6 py-12 text-center text-gray-500">
등록된 게시판이 없습니다.
</td>
</tr>
@endforelse
</tbody>
</table>
</x-table-swipe>
</div>
<!-- 페이지네이션 -->
@if($boards->hasPages())
<div class="px-6 py-4 border-t border-gray-200">
{{ $boards->withQueryString()->links() }}
</div>
@endif