@forelse ($lots as $index => $lot) @php $isExpired = $lot->expiration_date ? \Carbon\Carbon::parse($lot->expiration_date)->isPast() : false; $isZero = $lot->amount == 0; $rowStyle = $isZero || $isExpired ? 'background-color:rgba(255,0,0,.2)' : ''; @endphp @if (auth()->user()->work_department_id == 1) @endif @empty @endforelse
# No. Lote Producto Almacen Cantidad de ingreso Restante Fecha de caducidad Periodo Acciones
{{ ++$index }} {{ $lot->registration_number }} {{ $lot->product->name ?? '-' }} {{ $lot->warehouse->name ?? '-' }} {{ number_format($lot->amount, 2) }} {{ $lot->product->metric->value }} {{ $lot->remainingAmount() }} {{ $lot->product->metric->value }} @if ($lot->expiration_date) @if ($isExpired) {{ date('d/m/Y', strtotime($lot->expiration_date)) }} (CADUCADO) @else {{ date('d/m/Y', strtotime($lot->expiration_date)) }} @endif @else - @endif {{ date('d/m/Y', strtotime($lot->start_date)) . ' - ' . date('d/m/Y', strtotime($lot->end_date)) }} Editar Eliminar
No hay lotes para mostrar.
{{ $lots->links('pagination::bootstrap-5') }} @if($lots->isEmpty() && request()->has('search'))
No se encontraron lotes con el término de búsqueda: "{{ request('search') }}"
@endif