summaryrefslogtreecommitdiff
path: root/db/migrate
diff options
context:
space:
mode:
authorHombreLaser <sebastian-440@live.com>2023-03-25 00:15:52 -0600
committerHombreLaser <sebastian-440@live.com>2023-03-25 00:15:52 -0600
commit7b5d00f1bf262cc40b6b9dc21bb42e2dc7c80afe (patch)
tree0995c27ab14d62171bb4372e83b71400187b72b1 /db/migrate
parent7265af094ed16c36632128bccdcf84a3796c2359 (diff)
Añade modelo Card
Diffstat (limited to 'db/migrate')
-rw-r--r--db/migrate/20230325061452_create_cards.rb14
1 files changed, 14 insertions, 0 deletions
diff --git a/db/migrate/20230325061452_create_cards.rb b/db/migrate/20230325061452_create_cards.rb
new file mode 100644
index 0000000..6e06e36
--- /dev/null
+++ b/db/migrate/20230325061452_create_cards.rb
@@ -0,0 +1,14 @@
+class CreateCards < ActiveRecord::Migration[7.0]
+ def change
+ create_table :cards do |t|
+ t.string :number
+ t.integer :expiration_month
+ t.integer :expiration_year
+ t.integer :expiration_day
+ t.integer :security_code
+ t.references :user_account, null: false, foreign_key: true
+
+ t.timestamps
+ end
+ end
+end