Merhabalar,
Product adlı bir ürün tablom var. Ürünler tablosuna bağlı image ve price tablolarım var. Yapmaya çalıştığım şudur;
Eğer price tablo değeri null değil ise product ile beraber listelenmesini istiyorum.
Yorumlarınız için şimdi den, teşekkür ederim.
{
"id": 340,
"product_order": 3523145814,
"product_id": 31,
"product_seo": "vestel-55-ekran-full-hd",
"product_title": "Vestel 22F8500L 22'' 55 Ekran Full HD TV",
"product_desc": "Vestel 22F8500L 22'' 55 Ekran Full HD TV",
"product_key": null,
"product_code": "<p></p>",
"product_image": "YxfQVU2R-554806638.jpg",
"contact_detail": 1,
"is_active": 1,
"created_at": "2021-12-13T10:03:13.000000Z",
"updated_at": "2021-12-13T10:03:13.000000Z",
"category": {},
"image": [{}],
"price": null
},
product = Product::orderByDesc('id')->with('category')->with('image')->width('price')->get();