@php use App\Models\Setting; @endphp @if (Auth::user()->allProducts->isNotEmpty())
@if (Auth::user()->allProducts->count() > Auth::user()->products->count())
A pirossal jelölt termékek csere vagy visszaküldési folyamat alatt állnak
@endif
Terméknév
Csere érték
@foreach (Auth::user()->allProducts as $product) @php $images = []; $imagesDb = 0; for ($i = 0; $i < 4; $i++) { $ext = $product->pivot->{'image_' . $i . '_extension'}; if ($ext) { $images[] = '/storage/product_user_images/' . $product->pivot->id . '_' . $i . '.' . $ext; $imagesDb++; } else { $images[] = null; } } $imagesStr = collect($images)->map(fn($img) => "'{$img}'")->implode(','); @endphp
pivot->is_active ? 'disabled' : '' }} type="checkbox" name="select_game" value="{{ $product->id }}" data-name="{{ $product->name }}" data-price="{{ $product->price }}" data-pivotid="{{ $product->pivot->id }}" data-id="{{ $product->id }}" data-imageextension="{{ $product->image_extension }}" data-canswap="{{ $imagesDb >= 3 ? 'true' : 'false' }}" data-isfree="{{ $product->pivot->is_free ? 'true' : 'false' }}">
{{ $product->name }}
@if ($imagesDb < 1) @else @foreach ($images as $image) @if ($image) @endif @endforeach @endif
{{ number_format($product->price, 0, ',', ' ') }} Ft
@endforeach
@if (Auth::user()->allProducts->count() > Auth::user()->products->count())
A pirossal jelölt termékek csere vagy visszaküldési folyamat alatt állnak
@endif @foreach (Auth::user()->allProducts as $product) @php $images = []; $imagesDb = 0; for ($i = 0; $i < 4; $i++) { $ext = $product->pivot->{'image_' . $i . '_extension'}; if ($ext) { $images[] = '/storage/product_user_images/' . $product->pivot->id . '_' . $i . '.' . $ext; $imagesDb++; } else { $images[] = null; } } $imagesStr = collect($images)->map(fn($img) => "'{$img}'")->implode(','); @endphp
Terméknév
{{ $product->name }}
pivot->is_active ? 'disabled' : '' }} type="checkbox" name="select_game" value="{{ $product->id }}" data-canswap="{{ $imagesDb >= 3 ? 'true' : 'false' }}" data-pivotid="{{ $product->pivot->id }}" data-name="{{ $product->name }}" data-price="{{ $product->price }}" data-id="{{ $product->id }}" data-imageextension="{{ $product->image_extension }}" data-isfree="{{ $product->pivot->is_free ? 'true' : 'false' }}">
Csere érték: {{ number_format($product->price, 0, ',', ' ') }} Ft
@if ($imagesDb < 3) @else
@foreach ($images as $image) @if ($image) @endif @endforeach
@endif
@endforeach
Össz. csere érték: {{ number_format(Auth::user()->products->sum('price'), 0, ',', ' ') }} Ft
@endif