@extends('layouts.admin') @section('title', '題庫管理') @section('content') {{-- Tab 切換:公用 / 私有 --}}
{{-- 篩選 --}}| 序號 {{ $sortIcon('id') }} | 年份 | 考試分類 | 考試科目 | 題目 | 題型 {{ $sortIcon('question_type') }} | 提供者 | AI | 更新 {{ $sortIcon('updated_at') }} | 操作 | ||
|---|---|---|---|---|---|---|---|---|---|---|---|
| id }})" :checked="selected.includes({{ $q->id }})" class="w-4 h-4 rounded text-blue-600"> | {{ $q->id }} | @if($q->exam && $q->exam->year) {{ $q->exam->year - 1911 }} @else - @endif | @if($q->exam) @php $titleParts = explode(' - ', $q->exam->title); $examName = count($titleParts) >= 2 ? $titleParts[1] : $q->exam->examCategory?->name; $nameParts = $examName ? explode('_', $examName, 2) : []; @endphp @if(count($nameParts) >= 2) {{ $nameParts[0] }} {{ $nameParts[1] }} @elseif($examName) {{ Str::limit($examName, 18) }} @else - @endif @else - @endif | @if($q->subject) {{ Str::limit($q->subject->name, 10) }} @else - @endif |
@if($q->image_path)@endif{{ Str::limit($q->question_text, 55) }}
@if($q->correct_answer)
答:{{ Str::limit($q->correct_answer, 20) }} @endif |
{{ $typeLabel($q->question_type) }} | {{ $q->creator->name ?? '-' }} | @if($q->ai_explanation) @else @endif | {{ $q->updated_at->format('m/d H:i') }} | ||
|
@if($tab === 'public')
公用題庫尚無題目 將私有題目設為公開,或在匯入時將考試設為公開 @else私有題庫尚無題目 建立考試並新增題目,題目預設為私有 @endif | |||||||||||