{{ $category->nom }}
Les offres qui valent le coup
@foreach($offresReductions as $annonce)
@php
$oldPrice = $annonce->produit->prix_moyen_marche ?? ($annonce->prix * 1.15);
$discount = 0;
if ($oldPrice > $annonce->prix) {
$discount = round((($oldPrice - $annonce->prix) / $oldPrice) * 100);
}
$itemN2Id = ($annonce->category->parent && $annonce->category->parent->parent_id === null) ? $annonce->categorie_id : $annonce->category->parent_id;
@endphp
@if($annonce->photoPrincipale())
@else
Pas de photo
@endif
{{ \Illuminate\Support\Str::limit($annonce->titre, 55) }}
@endforeach
Nos produits phares de nos marchands pro
@foreach($annonces as $annonce)
@php
$itemN2Id = ($annonce->category->parent && $annonce->category->parent->parent_id === null) ? $annonce->categorie_id : $annonce->category->parent_id;
@endphp
@include('partials.product-card-premium', [
'annonce' => $annonce,
'class' => 'global-filter-item',
'attributes' => 'data-n2="' . $itemN2Id . '"'
])
@endforeach
Nos deals marchands du moment
@foreach($dealsMarchands as $index => $annonce)
@php
$itemN2Id = ($annonce->category->parent && $annonce->category->parent->parent_id === null) ? $annonce->categorie_id : $annonce->category->parent_id;
@endphp
@endforeach
Notre sélection {{ $category->nom }}
@foreach($selectionAnnonces as $index => $annonce)
@php
$n2Id = null;
$n3Id = null;
$cat = $annonce->category;
if ($cat) {
if ($cat->parent_id == $category->id) {
$n2Id = $cat->id;
} elseif ($cat->parent && $cat->parent->parent_id == $category->id) {
$n2Id = $cat->parent_id;
$n3Id = $cat->id;
}
}
$normEtat = 'neuf';
$rawEtat = strtolower($annonce->produit->etat ?? 'neuf');
if (strpos($rawEtat, 'occasion') !== false) $normEtat = 'occasion';
elseif (strpos($rawEtat, 'reconditionne') !== false) $normEtat = 'reconditionne';
@endphp
@endforeach
@forelse($annonces as $annonce)
@empty
@endforelse
@endif
@if($category->parent_id !== null)
Aucun produit trouvé dans cette catégorie.
Retour à l'accueil
{{ $annonces->links() }}
@endif