feat: mostra marca, scadenza e posizione negli ingredienti ricetta
- Backend: aggiunge brand e expiry_date all'arricchimento ingredienti - Frontend: sotto ogni ingrediente dalla dispensa mostra: - Marca in corsivo (se presente) - Icona posizione (🧊 Frigo/Freezer, 🗄️ Dispensa) - Scadenza con colore urgenza (⛔ scaduto, 🔴 <3gg, 🟡 <7gg, 📅 data) - Nuovo stile CSS per riga dettaglio ingrediente
This commit is contained in:
@@ -857,6 +857,12 @@ PROMPT;
|
||||
$ing['product_id'] = (int)$bestMatch['product_id'];
|
||||
$ing['location'] = $bestMatch['location'];
|
||||
$ing['available_qty'] = $bestMatch['quantity'] . ' ' . $bestMatch['unit'];
|
||||
if (!empty($bestMatch['brand'])) {
|
||||
$ing['brand'] = $bestMatch['brand'];
|
||||
}
|
||||
if (!empty($bestMatch['expiry_date'])) {
|
||||
$ing['expiry_date'] = $bestMatch['expiry_date'];
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user