|
- class CreateClas < ActiveRecord::Migration[5.2]
- def change
- create_table :clas do |t|
- t.string :name, null:false
- t.string :key, null:false
- t.text :content
- t.integer :organization_id, null:false
- t.boolean :pr_need, default: false
- t.integer :count, default: 0
- t.timestamps
- end
- add_index :clas, :key, :length =>190
- add_index :clas, :organization_id
- end
- end
|