diff options
author | HombreLaser <sebastian-440@live.com> | 2023-04-04 19:54:00 -0600 |
---|---|---|
committer | HombreLaser <sebastian-440@live.com> | 2023-04-04 19:54:00 -0600 |
commit | 18b129f8f6ba8c5c98adaf82ccfc4ba38264a29b (patch) | |
tree | 90b0bb96064198fec5747a55b65e3f419a5cb0e8 /db/migrate | |
parent | 72ccdfdf9bbea6269bc1a28199373abd5e8ce302 (diff) |
Añade modelo Cart
Diffstat (limited to 'db/migrate')
-rw-r--r-- | db/migrate/20230405013826_create_carts.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/db/migrate/20230405013826_create_carts.rb b/db/migrate/20230405013826_create_carts.rb new file mode 100644 index 0000000..8975e61 --- /dev/null +++ b/db/migrate/20230405013826_create_carts.rb @@ -0,0 +1,9 @@ +class CreateCarts < ActiveRecord::Migration[7.0] + def change + create_table :carts do |t| + t.belongs_to :user_account, null: false, index: { unique: true }, foreign_key: true + + t.timestamps + end + end +end |