Add stock items, groups and movements at a moving average cost

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
This commit is contained in:
2026-11-26 16:18:59 +02:00
co-authored by Claude Sonnet 5.5
parent 361a2974cf
commit 30132deb0e
81 changed files with 4968 additions and 115 deletions
@@ -0,0 +1,31 @@
{{--
A stock item's state as text with an icon, not colour alone: negative
balance, to order (at or below the reorder level), out of use or enough.
--}}
@props(['item'])
<span {{ $attributes->class('inline-flex flex-wrap items-center gap-x-2 gap-y-1') }}>
@if ($item->isNegative())
<span class="inline-flex items-center gap-1 font-medium text-red-700 dark:text-red-400">
<x-icon name="exclamation-triangle" class="size-4" aria-hidden="true" />
{{ __('inventory.status.negative') }}
</span>
@elseif ($item->needsReorder())
<span class="inline-flex items-center gap-1 font-medium text-amber-800 dark:text-amber-300">
<x-icon name="shopping-cart" class="size-4" aria-hidden="true" />
{{ __('inventory.status.reorder') }}
</span>
@else
<span class="inline-flex items-center gap-1">
<x-icon name="check-circle" class="size-4" aria-hidden="true" />
{{ __('inventory.status.ok') }}
</span>
@endif
@unless ($item->isActive)
<span class="inline-flex items-center gap-1">
<x-icon name="archive-box-x-mark" class="size-4" aria-hidden="true" />
{{ __('inventory.status.inactive') }}
</span>
@endunless
</span>