Class: RadminCreateRoles
- Inherits:
-
ActiveRecord::Migration
- Object
- ActiveRecord::Migration
- RadminCreateRoles
- Defined in:
- lib/generators/radmin/templates/migrations/02_radmin_create_roles.rb
Class Method Summary collapse
Class Method Details
.down ⇒ Object
10 11 12 |
# File 'lib/generators/radmin/templates/migrations/02_radmin_create_roles.rb', line 10 def self.down drop_table :radmin_roles end |
.up ⇒ Object
2 3 4 5 6 7 8 |
# File 'lib/generators/radmin/templates/migrations/02_radmin_create_roles.rb', line 2 def self.up create_table :radmin_roles do |t| t.string :name, :limit => 20, :null => false t. end add_index :radmin_roles, :name, :unique => true end |