@extends('layouts.app') @section('title', 'Stock Movements Report') @section('breadcrumb')
{{ \Carbon\Carbon::parse($startDate)->format('M d, Y') }} - {{ \Carbon\Carbon::parse($endDate)->format('M d, Y') }}
| Image | Product | Type | Qty Before | Change | Qty After | Unit Cost | Total | By | Date | Notes |
|---|---|---|---|---|---|---|---|---|---|---|
|
@if($movement->product && $movement->product->image)
|
{{ $movement->product?->name ?? 'Deleted Product' }}
{{ $movement->product?->sku ?? '-' }}
|
@php $typeColors = [ 'sale' => 'danger', 'purchase' => 'success', 'opening' => 'primary', 'adjustment' => 'warning', 'damage' => 'danger', 'expired' => 'danger', 'return' => 'info', ]; $color = $typeColors[$movement->type] ?? 'secondary'; @endphp {{ ucfirst($movement->type) }} | {{ number_format($movement->quantity_before, 2) }} | {{ $movement->quantity >= 0 ? '+' : '' }}{{ number_format($movement->quantity, 2) }} | {{ number_format($movement->quantity_after, 2) }} | Rs. {{ number_format($movement->unit_cost ?? 0, 2) }} | Rs. {{ number_format($movement->total_cost ?? 0, 2) }} | {{ $movement->user?->name ?? '-' }} |
{{ $movement->created_at->format('M d, Y') }}
{{ $movement->created_at->format('h:i A') }}
|
@if($movement->notes) {{ Str::limit($movement->notes, 20) }} @else - @endif |
| No stock movements found for this period | ||||||||||