summaryrefslogtreecommitdiff
path: root/dichroism/src/migrations
diff options
context:
space:
mode:
Diffstat (limited to 'dichroism/src/migrations')
-rw-r--r--dichroism/src/migrations/photo_sets.sql8
-rw-r--r--dichroism/src/migrations/products.sql12
2 files changed, 20 insertions, 0 deletions
diff --git a/dichroism/src/migrations/photo_sets.sql b/dichroism/src/migrations/photo_sets.sql
new file mode 100644
index 0000000..a27c8ab
--- /dev/null
+++ b/dichroism/src/migrations/photo_sets.sql
@@ -0,0 +1,8 @@
+CREATE TABLE IF NOT EXISTS "photo_sets" (
+ "id" INTEGER NOT NULL,
+ "base" TEXT NOT NULL,
+ "fullsize" TEXT NOT NULL,
+ "thumbnail" TEXT NOT NULL,
+ "original" TEXT NOT NULL,
+ PRIMARY KEY("id")
+); \ No newline at end of file
diff --git a/dichroism/src/migrations/products.sql b/dichroism/src/migrations/products.sql
new file mode 100644
index 0000000..0603a5c
--- /dev/null
+++ b/dichroism/src/migrations/products.sql
@@ -0,0 +1,12 @@
+CREATE TABLE IF NOT EXISTS "products" (
+ "id" INTEGER NOT NULL,
+ "photo_set" INTEGER NOT NULL,
+ "cents" INTEGER NOT NULL,
+ "quantity" INTEGER NOT NULL,
+ "name" TEXT NOT NULL,
+ "description" TEXT NOT NULL,
+ "featured" INTEGER NOT NULL,
+ "category" TEXT NOT NULL,
+ PRIMARY KEY("id"),
+ FOREIGN KEY("photo_set") REFERENCES "photo_sets"("id")
+); \ No newline at end of file