Merge branch '102-brands-filter' into 'develop'

fix: 🐛 hide brands for unpublished products

See merge request ldc-web/projets/boutique-cnc-sable!83
This commit is contained in:
Noix 2026-04-16 13:59:54 +00:00
commit 242eaa60c5

View file

@ -90,7 +90,7 @@ class ProductsController extends Controller
$brands = \collect(\App\Enums\ProductBrand::toArray())->filter(
function (\App\Enums\ProductBrand $case) {
return Product::query()->pluck('brand')->contains($case->value);
return Product::query()->where('status', 1)->pluck('brand')->contains($case->value);
}
)->values();