raven/db/migrations/0001_add_items_table.rb

23 lines
453 B
Ruby
Raw Normal View History

2022-12-07 17:52:27 -05:00
Sequel.migration do
up do
create_table(:items) do
primary_key :id
String :name, null: false
String :manufacturer
String :serial_number
String :sku_number
String :type
String :purchased_from
DateTime :purchased_at
DateTime :created_at, default: Sequel::CURRENT_TIMESTAMP
DateTime :updated_at, default: Sequel::CURRENT_TIMESTAMP
2022-12-07 17:52:27 -05:00
end
end
down do
drop_table(:items)
end
end