summaryrefslogtreecommitdiff
path: root/model/sql/migrate.sql
diff options
context:
space:
mode:
authorxengineering <me@xengineering.eu>2024-04-04 14:54:21 +0200
committerxengineering <me@xengineering.eu>2024-05-12 20:52:25 +0200
commit87ae71413e47ef34da57bc1e0b8dddbf84b0c66a (patch)
treef8711576d7098d21e48eafd9df3ab6f3ed679b88 /model/sql/migrate.sql
parentfec2fea87615e6ee3a6e73f7f98e021eee1b7098 (diff)
downloadceres-87ae71413e47ef34da57bc1e0b8dddbf84b0c66a.tar
ceres-87ae71413e47ef34da57bc1e0b8dddbf84b0c66a.tar.zst
ceres-87ae71413e47ef34da57bc1e0b8dddbf84b0c66a.zip
model: Add per-step ingredients
Diffstat (limited to 'model/sql/migrate.sql')
-rw-r--r--model/sql/migrate.sql10
1 files changed, 10 insertions, 0 deletions
diff --git a/model/sql/migrate.sql b/model/sql/migrate.sql
index f931af6..46f9fc6 100644
--- a/model/sql/migrate.sql
+++ b/model/sql/migrate.sql
@@ -17,3 +17,13 @@ CREATE TABLE steps (
recipe INTEGER NOT NULL,
FOREIGN KEY(recipe) REFERENCES recipes(id)
);
+
+CREATE TABLE ingredients (
+ id INTEGER PRIMARY KEY,
+ 'index' INTEGER NOT NULL,
+ amount REAL NOT NULL,
+ unit TEXT NOT NULL,
+ 'type' TEXT NOT NULL,
+ step INTEGER NOT NULL,
+ FOREIGN KEY(step) REFERENCES steps(id)
+);