diff options
author | David Gay <david@davidgay.org> | 2021-05-02 22:38:32 -0400 |
---|---|---|
committer | David Gay <david@davidgay.org> | 2021-05-02 22:38:32 -0400 |
commit | 1b2de86007508ba86c6c9cb99fbdcac178045131 (patch) | |
tree | a007fc55acd2b54b5db108e3580928a9a006d71e /db/migrate | |
parent | 1d5083ddf7f2b285e63bb8019d38199e862fa1d8 (diff) |
Character items and inventory, with ability to add and remove items
Diffstat (limited to 'db/migrate')
-rw-r--r-- | db/migrate/20210503005919_create_character_items.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/db/migrate/20210503005919_create_character_items.rb b/db/migrate/20210503005919_create_character_items.rb new file mode 100644 index 0000000..50e926a --- /dev/null +++ b/db/migrate/20210503005919_create_character_items.rb @@ -0,0 +1,11 @@ +class CreateCharacterItems < ActiveRecord::Migration[6.1] + def change + create_table :character_items do |t| + t.references :character, null: false, foreign_key: true + t.references :item, null: false, foreign_key: true + t.integer :quantity + + t.timestamps + end + end +end |