super-graph/examples/rails-app/db/migrate/20190322181710_create_produ...

13 lines
275 B
Ruby
Raw Normal View History

2019-03-24 14:57:29 +01:00
class CreateProducts < ActiveRecord::Migration[5.2]
def change
create_table :products do |t|
t.string :name
t.text :description
t.decimal :price, precision: 7, scale: 2
t.belongs_to :user, foreign_key: true
t.timestamps
end
end
end