@php if(empty($listItems)) { $listItems = []; } @endphp @php if(empty($products)) { $products = []; } @endphp @php if(empty($quantityunits)) { $quantityunits = []; } @endphp @php if(empty($missingProducts)) { $missingProducts = []; } @endphp @php if(empty($productGroups)) { $productGroups = []; } @endphp @php if(!isset($selectedShoppingListId)) { $selectedShoppingListId = 1; } @endphp @php if(empty($quantityUnitConversionsResolved)) { $quantityUnitConversionsResolved = []; } @endphp @php if(empty($productUserfields)) { $productUserfields = []; } @endphp @php if(empty($productUserfieldValues)) { $productUserfieldValues = []; } @endphp @php if(empty($userfields)) { $userfields = []; } @endphp @php if(empty($userfieldValues)) { $userfieldValues = []; } @endphp @php if(!isset($isPrint)) { $isPrint = false; } @endphp @php $tableId = ($isPrint ? "shoppinglist-table-print" : "shoppinglist-table"); @endphp @push('componentStyles') @endpush @push('componentScripts') @endpush
| Hidden product group | Hidden status | {{ $__t('Product') }} / {{ $__t('Note') }} | {{ $__t('Amount') }} | @include('components.userfields_thead', array( 'userfields' => $userfields )) @include('components.userfields_thead', array( 'userfields' => $productUserfields ))|
|---|---|---|---|---|
| @if(!$isPrint) product_id)) data-toggle="tooltip" title="{{ $__t('Add %1$s of %2$s to stock', $listItem->amount . ' ' . $__n($listItem->amount, FindObjectInArrayByPropertyValue($quantityunits, 'id', $listItem->qu_id)->name, FindObjectInArrayByPropertyValue($quantityunits, 'id', $listItem->qu_id)->name_plural), FindObjectInArrayByPropertyValue($products, 'id', $listItem->product_id)->name, $listItem->amount) }}" @endif> @endif | @if(!empty(FindObjectInArrayByPropertyValue($products, 'id', $listItem->product_id)->product_group_id)) {{ FindObjectInArrayByPropertyValue($productGroups, 'id', FindObjectInArrayByPropertyValue($products, 'id', $listItem->product_id)->product_group_id)->name }} @else {{ $__t('Ungrouped') }} @endif | @if(FindObjectInArrayByPropertyValue($missingProducts, 'id', $listItem->product_id) !== null) belowminstockamount @endif @if($listItem->done != 1) xxUNDONExx @endif |
@if(!empty($listItem->product_id)) {{ FindObjectInArrayByPropertyValue($products, 'id', $listItem->product_id)->name }} @endif{!! nl2br($listItem->note) !!} |
@if(!empty($listItem->product_id)) @php $listItem->amount_origin_qu = $listItem->amount; $product = FindObjectInArrayByPropertyValue($products, 'id', $listItem->product_id); $productQuConversions = FindAllObjectsInArrayByPropertyValue($quantityUnitConversionsResolved, 'product_id', $product->id); $productQuConversions = FindAllObjectsInArrayByPropertyValue($productQuConversions, 'from_qu_id', $product->qu_id_stock); $productQuConversion = FindObjectInArrayByPropertyValue($productQuConversions, 'to_qu_id', $listItem->qu_id); if ($productQuConversion) { $listItem->amount = $listItem->amount * $productQuConversion->factor; } @endphp @endif {{ $listItem->amount }} @if(!empty($listItem->product_id)){{ $__n($listItem->amount, FindObjectInArrayByPropertyValue($quantityunits, 'id', $listItem->qu_id)->name, FindObjectInArrayByPropertyValue($quantityunits, 'id', $listItem->qu_id)->name_plural) }}@endif | @include('components.userfields_tbody', array( 'userfields' => $userfields, 'userfieldValues' => FindAllObjectsInArrayByPropertyValue($userfieldValues, 'object_id', $listItem->id) )) @include('components.userfields_tbody', array( 'userfields' => $productUserfields, 'userfieldValues' => FindAllObjectsInArrayByPropertyValue($userfieldValues, 'object_id', $listItem->product_id) ))