Initial commit
This commit is contained in:
14
db/migrate/20210420111629_create_cities.rb
Normal file
14
db/migrate/20210420111629_create_cities.rb
Normal file
@@ -0,0 +1,14 @@
|
||||
class CreateCities < ActiveRecord::Migration[5.2]
|
||||
def down
|
||||
drop_table :cities
|
||||
end
|
||||
def up
|
||||
create_table :cities do |t|
|
||||
t.string :name
|
||||
t.references :province, foreign_key: true
|
||||
t.timestamps
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user