added item route details (#6)

Reviewed-on: #6
Co-authored-by: Joseph Nelson <joseph.nelson4456@gmail.com>
Co-committed-by: Joseph Nelson <joseph.nelson4456@gmail.com>
This commit was merged in pull request #6.
This commit is contained in:
2026-05-16 23:42:41 -07:00
committed by joseph.nelson4456
parent 4f73991360
commit 96b06cf92d
7 changed files with 163 additions and 7 deletions
@@ -0,0 +1,16 @@
export const up = (pgm) => {
pgm.sql(`
ALTER TABLE "items"
ADD CONSTRAINT "set_id"
FOREIGN KEY ("set_id")
REFERENCES "sets" ("id")
ON DELETE CASCADE;
`)
}
export const down = (pgm) => {
pgm.sql(`
ALTER TABLE "items"
DROP CONSTRAINT "fk_name";
`)
}