@extends('layouts.app') @section('title', 'Books Catalog') @section('styles') @endsection @section('content')
{{-- ===== Page Header ===== --}}

Books Catalog

@if($search !== '')
Showing books matching {{ $search }}. Clear search
@endif {{-- ===== Toast Notifications ===== --}}
{{-- ===== Tabs: Active Books | Backup/History ===== --}}
{{-- ===================================== --}} {{-- TAB 1: ACTIVE BOOKS --}} {{-- ===================================== --}}
@forelse($books as $book) {{-- Thumbnail (50x50) --}} {{-- Title + subtitle --}} {{-- Actions: Edit & Delete --}} @empty @endforelse
Cover Book Title Author Category Qty Available Actions
@if($book->book_cover) Cover @else No Image @endif {{ $book->title }} @if($book->subtitle)
{{ $book->subtitle }} @endif
{{ $book->author }} {{ $book->category }} {{ $book->quantity }} {{ $book->available_copies }}
No books in the catalog. Add your first book!
{{-- ===================================== --}} {{-- TAB 2: BACKUP / HISTORY --}} {{-- ===================================== --}}
Books listed here have been soft-deleted. They are not permanently removed. You can restore them to the active catalog at any time.
@forelse($deletedBooks as $book) {{-- Thumbnail --}} {{-- Date when it was soft-deleted --}} {{-- Restore action --}} @empty @endforelse
Cover Book Title Author Category Date Deleted Actions
@if($book->book_cover) Cover @else No Image @endif {{ $book->title }} @if($book->subtitle)
{{ $book->subtitle }} @endif
{{ $book->author }} {{ $book->category }} {{ \Carbon\Carbon::parse($book->deleted_at)->format('d M Y, h:i A') }}
No deleted books. History is empty.
{{-- /tab-content --}}
{{-- /container --}} {{-- ============================================================ --}} {{-- EDIT BOOK MODAL --}} {{-- ============================================================ --}} {{-- ============================================================ --}} {{-- DELETE CONFIRMATION MODAL --}} {{-- ============================================================ --}} @endsection @section('scripts') @endsection