feat: Listen-Dialog mit Mengen/Einheiten, Mitai ohne Kochrezepte
Roh-Kombinationen statt Rezept-Sprache; Zutaten suchen, EL/TL/Prise auf Gramm. Gekochte Gerichte und Ausbeute bleiben Tandoor. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
a7e5511039
commit
fa542e0fb9
17 files changed
+776
-203
No files matched your search
@@ -0,0 +1,18 @@
|
||||
-- Menge + Einheit an Rezeptzutaten; quantity_g bleibt die Standardeinheit (Gramm).
|
||||
|
||||
ALTER TABLE food_recipe_ingredients
|
||||
ADD COLUMN IF NOT EXISTS quantity_amount NUMERIC(10,3),
|
||||
ADD COLUMN IF NOT EXISTS source_unit VARCHAR(20);
|
||||
|
||||
COMMENT ON COLUMN food_recipe_ingredients.quantity_amount IS 'Menge in source_unit (z. B. 2 TL)';
|
||||
COMMENT ON COLUMN food_recipe_ingredients.source_unit IS 'Kanonische Einheit: g, ml, el, tl, prise, stück, …';
|
||||
COMMENT ON COLUMN food_recipe_ingredients.quantity_g IS 'Umrechnung auf Gramm, wenn Faktor bekannt';
|
||||
|
||||
UPDATE food_recipe_ingredients
|
||||
SET quantity_amount = quantity_g, source_unit = 'g'
|
||||
WHERE quantity_g IS NOT NULL AND quantity_amount IS NULL AND source_unit IS NULL;
|
||||
|
||||
DO $$
|
||||
BEGIN
|
||||
RAISE NOTICE 'Migration 066: recipe ingredient amount + unit';
|
||||
END $$;
|
||||
Reference in new issue
Block a user