Files
FilamentLaravel/resources/views/manufacturers/index.blade.php
T

46 lines
2.4 KiB
PHP

<x-app-layout>
<x-slot name="header">
{{ __('Manufacturers') }}
</x-slot>
<x-slot name="headeraction">
<div class="flex gap-4 justify-end">
<a href="{{ route('manufacturers.create') }}" class="bg-zinc-500 hover:bg-green-500 text-zinc-50 hover:text-zinc-700 font-bold text-base py-2 px-4 rounded cursor-pointer">Create</a>
</div>
</x-slot>
<div class="py-12">
<div class="max-w-7xl mx-auto sm:px-6 lg:px-8">
<div class="bg-white dark:bg-zinc-700 overflow-hidden shadow-xl sm:rounded-lg">
<table class="table-auto w-full">
<thead class="bg-zinc-900 border-b border-rose-500">
<tr>
<th class="py-6">Name</th>
<th class="py-6">Filaments</th>
<th class="py-6">Website</th>
<th class="py-6">Stock</th>
<th class="py-6">Edit</th>
<th class="py-6">Delete</th>
</tr>
</thead>
<tbody>
@foreach ($manufacturers as $manufacturer)
<tr class="border-b border-zinc-600">
<td class="text-center py-4"><a href="/manufacturers/{{ $manufacturer->id }}" class="flex justify-center">{{ $manufacturer->name }}</a></td>
<td class="text-center py-4"><a href="/manufacturers/{{ $manufacturer->id }}" class="bg-etheral-300 px-2 py-1 rounded text-blackout-950">{{ $manufacturer->filament_count }}</a></td>
<td class="text-center py-4"><a class="flex gap-2 justify-center" target="_blank" href="{{ $manufacturer->website }}">{{ $manufacturer->website }} @isset($manufacturer->website) <flux:icon.arrow-top-right-on-square /> @endisset</a></td>
<td class="text-center py-4"></td>
<td class="text-center py-4"><a href="{{ route('manufacturers.edit', $manufacturer->id) }}" class="flex justify-center"><flux:icon.ellipsis class="hover:text-zinc-50 hover:bg-zinc-500 stroke-3 rounded "/></a></td>
<td class="text-center py-4"><a href="{{ route('manufacturers.edit', $manufacturer->id) }}" class="flex justify-center"><flux:icon.x-mark class="hover:text-zinc-50 hover:bg-zinc-500 stroke-3 rounded "/></a></td>
</tr>
@endforeach
</tbody>
</table>
</div>
</div>
</div>
</x-app-layout>