add covenant
This commit is contained in:
14
db/migrate/20210530135118_create_wow_covenants.rb
Normal file
14
db/migrate/20210530135118_create_wow_covenants.rb
Normal file
@@ -0,0 +1,14 @@
|
||||
class CreateWowCovenants < ActiveRecord::Migration[6.1]
|
||||
def change
|
||||
create_table :wow_covenants do |t|
|
||||
t.integer :covenant_id
|
||||
t.jsonb :name
|
||||
t.jsonb :description
|
||||
t.integer :media_id
|
||||
|
||||
t.timestamps
|
||||
end
|
||||
|
||||
add_index :wow_covenants, :covenant_id, unique: true
|
||||
end
|
||||
end
|
||||
11
db/migrate/20210530135651_create_wow_covenant_progresses.rb
Normal file
11
db/migrate/20210530135651_create_wow_covenant_progresses.rb
Normal file
@@ -0,0 +1,11 @@
|
||||
class CreateWowCovenantProgresses < ActiveRecord::Migration[6.1]
|
||||
def change
|
||||
create_table :wow_covenant_progresses do |t|
|
||||
t.integer :renown_level
|
||||
t.belongs_to :wow_characters
|
||||
t.belongs_to :wow_covenant
|
||||
|
||||
t.timestamps
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,5 @@
|
||||
class RenameCovenantProgressBelongToWowCharacter < ActiveRecord::Migration[6.1]
|
||||
def change
|
||||
rename_column :wow_covenant_progresses, :wow_characters_id, :wow_character_id
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user