updated manufacturer.index

This commit is contained in:
2025-03-10 23:06:06 +01:00
parent 91629594cf
commit be19ec16d3
3 changed files with 27 additions and 14 deletions
+24 -11
View File
@@ -12,17 +12,30 @@
<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">
<ul class="">
<li class="flex gap-6 bg-zinc-50 dark:bg-zinc-900 p-2 px-4"><div class="">Name</div><div class="">Options</div></li>
@foreach ($manufacturers as $manufacturer)
<li class="flex gap-6 py-3 px-4 items-center">
<div class="p-2"><a href="/manufacturers/{{ $manufacturer->id }}">{{ $manufacturer->name }}</a></div>
<div class="p-2"><a href="/manufacturers/{{ $manufacturer->id }}" class="bg-accent px-2 py-1 rounded">{{ $filamentcount }}</a></div>
<div class="p-2"><a class="flex gap-2" target="_blank" href="{{ $manufacturer->website }}">{{ $manufacturer->website }}<flux:icon.arrow-top-right-on-square /></a></div>
<div class="px-2"><a href="{{ route('manufacturers.edit', $manufacturer->id) }}"><flux:icon.ellipsis class="hover:text-zinc-50 hover:bg-zinc-500 stroke-3 rounded "/></a></div>
</li>
@endforeach
</ul>
<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">Count</th>
<th class="py-6">Website</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-accent px-2 py-1 rounded">{{ $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 }}<flux:icon.arrow-top-right-on-square /></a></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>