@extends('layouts.front-end.app') @section('title', translate('Restock_Requests')) @section('content')
@include('web-views.partials._profile-aside')
@if($restockProducts->count() > 0)
{{translate('Restock_Requests')}}
@endif @if(count($restockProducts) > 0)
@foreach($restockProducts as $key => $restockProduct)
Wishlist @if(getProductPriceByType(product: $restockProduct?->product, type: 'discount', result: 'value') > 0) -{{ getProductPriceByType(product: $restockProduct?->product, type: 'discount', result: 'string') }} @endif
@php $overallRating = $restockProduct?->product?->reviews ? getOverallRating($restockProduct?->product?->reviews) : 0; @endphp
@for($inc=1;$inc<=5;$inc++) @if ($inc <= (int)$overallRating[0]) @elseif ($overallRating[0] != 0 && $inc <= (int)$overallRating[0] + 1.1 && $overallRating[0] > ((int)$overallRating[0])) @else @endif @endfor ({{count($restockProduct?->product?->reviews)}})

@if($restockProduct['variant']) {{ translate('Variant :') }} {{$restockProduct['variant'] }} @else {{ translate('Brand :') }} @if(getWebConfig(name: 'product_brand')) {{ $restockProduct?->product?->brand?->name ?? '' }} @endif @endif
@php $productPrices = $restockProduct?->product?->unit_price; $restockProductsList = json_decode($restockProduct?->product?->variation, true); if(!empty($restockProductsList) && count($restockProductsList) > 0) { foreach ($restockProductsList as $item) { if ($item['type'] === $restockProduct->variant) { $productPrices = $item['price']; } } } @endphp @if(getProductPriceByType(product: $restockProduct?->product, type: 'discount', result: 'value') > 0) {{ getProductPriceByType(product: $restockProduct?->product, type: 'discounted_unit_price', result: 'string', price: $productPrices) }} {{ webCurrencyConverter(amount: $productPrices) }} @else {{ webCurrencyConverter(amount: $productPrices) }} @endif
@endforeach
@else
@endif @if (count($restockProducts) > 0)
{!! $restockProducts->links() !!}
@endif
@endsection