This commit is contained in:
paoloar77
2024-06-15 17:32:36 +02:00
parent 0382fd15ab
commit 1824f30a94

View File

@@ -26,9 +26,9 @@ class TestPaoController extends Controller
public function getProductBySku($sku)
{
echo "getProductBySku:" . $sku;
$product = Product::where('sku', $sku)->first();
/*
// Estrai il prodotto utilizzando il codice SKU
$product = Product::where('sku', $sku)->first();
if ($product) {
// Ritorna il prodotto trovato come JSON