{{-- frontpage filter item --}} @foreach ($products as $item) @php $campaign_product = getCampaignProductById($item->id); $sale_price = $campaign_product ? $campaign_product->campaign_price : $item->sale_price; $campaign_percentage = $campaign_product ? getPercentage($item->sale_price, $sale_price) : false; @endphp
@if(!empty($item->badge)) {{$item->badge}} @endif @if($campaign_percentage) -{{ round($campaign_percentage, 2) }}% @endif {!! render_image_markup_by_attachment_id($item->image, '', 'grid') !!}
@php $attributes = $item->attributes ? json_decode($item->attributes, true) : null; @endphp
  • @if (is_array($attributes) && count($attributes)) @else @endif @php $quick_view_data = getQuickViewDataMarkup($item); @endphp

{{ $item->title }}

  • {{ float_amount_with_currency_symbol($sale_price) }}
  • @if(!empty($item->price) && $item->price != 0)
  • {{ float_amount_with_currency_symbol($item->price) }}
  • @endif
@endforeach