add management of items !

This commit is contained in:
2021-05-29 00:10:32 +02:00
parent f8c539bb87
commit f4f3862c74
24 changed files with 373 additions and 7 deletions

View File

@@ -0,0 +1,24 @@
class CreateWowItems < ActiveRecord::Migration[6.1]
def change
create_table :wow_items do |t|
t.jsonb :name
t.integer :level
t.integer :required_level
t.integer :sell_price
t.boolean :is_equippable
t.integer :media_id
t.integer :max_count
t.integer :purchase_price
t.integer :item_id
t.boolean :is_stackable
t.belongs_to :wow_item_class
t.belongs_to :wow_item_sub_class
t.belongs_to :wow_item_quality
t.belongs_to :wow_item_inventory_type
t.timestamps
end
add_index :wow_items, :item_id, unique: true
end
end