Files
ladill-queue/resources/views/qms/admin/branches/index.blade.php
T
isaaccladandCursor 89300fc6d6
Deploy Ladill Queue / deploy (push) Successful in 43s
Drop heroes from analytics pages and remove bordered show cards.
Analytics, Reports, Feedback, and Branches use simple headers again;
report and related show views use shadow panels instead of card borders.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-06 08:21:35 +00:00

41 lines
1.9 KiB
PHP

@php
$canManageBranches = app(\App\Services\Qms\QmsPermissions::class)->can(
app(\App\Services\Qms\OrganizationResolver::class)->memberFor(auth()->user()),
'admin.branches.manage'
);
@endphp
<x-app-layout title="Branches">
<div class="mb-6 flex items-center justify-between">
<h1 class="text-2xl font-semibold text-slate-900">Branches</h1>
@if ($canManageBranches)
<a href="{{ route('qms.branches.create') }}" class="btn-primary">New branch</a>
@endif
</div>
@include('partials.flash')
<div class="overflow-hidden rounded-2xl bg-white shadow-sm">
<table class="min-w-full divide-y divide-slate-200">
<thead class="bg-slate-50"><tr>
<th class="px-4 py-3 text-left text-xs font-semibold uppercase text-slate-500">Name</th>
<th class="px-4 py-3 text-left text-xs font-semibold uppercase text-slate-500">Code</th>
<th class="px-4 py-3 text-left text-xs font-semibold uppercase text-slate-500">Departments</th>
<th class="px-4 py-3 text-left text-xs font-semibold uppercase text-slate-500">Status</th>
<th></th>
</tr></thead>
<tbody class="divide-y divide-slate-200">
@foreach ($branches as $branch)
<tr>
<td class="px-4 py-3 text-sm font-medium">{{ $branch->name }}</td>
<td class="px-4 py-3 text-sm">{{ $branch->code ?? '—' }}</td>
<td class="px-4 py-3 text-sm">{{ $branch->departments_count }}</td>
<td class="px-4 py-3 text-sm">{{ $branch->is_active ? 'Active' : 'Inactive' }}</td>
<td class="px-4 py-3 text-right"><a href="{{ route('qms.branches.edit', $branch) }}" class="text-sm text-indigo-600">Edit</a></td>
</tr>
@endforeach
</tbody>
</table>
</div>
</x-app-layout>