add migration
This commit is contained in:
parent
c90d4b2f8e
commit
d09f654b3e
|
@ -2,16 +2,10 @@
|
||||||
|
|
||||||
class CreatePaymentsTable < ActiveRecord::Migration[5.2]
|
class CreatePaymentsTable < ActiveRecord::Migration[5.2]
|
||||||
def change
|
def change
|
||||||
def change
|
create_table :payments do |t|
|
||||||
create_table :payments do |t|
|
t.timestamps
|
||||||
t.integer :payment_intent_id, null: false
|
|
||||||
t.string :receipt_email, null: false
|
|
||||||
t.string :url, null: false
|
|
||||||
t.integer :amount, null: false
|
|
||||||
t.timestamps
|
|
||||||
end
|
|
||||||
|
|
||||||
add_index :payments, [:payment_intent_id], unique: true
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
add_index :payments, [:payment_intent_id], unique: true
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue