diff options
Diffstat (limited to 'db/migrate/20100606031333_create_agenda_items.rb')
-rw-r--r-- | db/migrate/20100606031333_create_agenda_items.rb | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/db/migrate/20100606031333_create_agenda_items.rb b/db/migrate/20100606031333_create_agenda_items.rb new file mode 100644 index 0000000..f40ff76 --- /dev/null +++ b/db/migrate/20100606031333_create_agenda_items.rb @@ -0,0 +1,23 @@ +class CreateAgendaItems < ActiveRecord::Migration + def self.up + create_table :agenda_items do |t| + t.string :name, :null => false + t.text :description, :null => false + t.text :reason_of_rejection + t.datetime :created_at + t.datetime :updated_at + t.string :state, :default => 'pending' + t.datetime :key_timestamp + t.integer :owner_id + t.integer :approved_by_id + t.integer :agenda_id + end + add_index :agenda_items, [:owner_id] + add_index :agenda_items, [:approved_by_id] + add_index :agenda_items, [:agenda_id] + end + + def self.down + drop_table :agenda_items + end +end |