diff options
Diffstat (limited to 'db')
-rw-r--r-- | db/migrate/20090403001910_add_project_to_enumerations.rb | 11 | ||||
-rw-r--r-- | db/migrate/20090406161854_add_parent_id_to_enumerations.rb | 9 |
2 files changed, 20 insertions, 0 deletions
diff --git a/db/migrate/20090403001910_add_project_to_enumerations.rb b/db/migrate/20090403001910_add_project_to_enumerations.rb new file mode 100644 index 000000000..a3db6d51e --- /dev/null +++ b/db/migrate/20090403001910_add_project_to_enumerations.rb @@ -0,0 +1,11 @@ +class AddProjectToEnumerations < ActiveRecord::Migration + def self.up + add_column :enumerations, :project_id, :integer, :null => true, :default => nil + add_index :enumerations, :project_id + end + + def self.down + remove_index :enumerations, :project_id + remove_column :enumerations, :project_id + end +end diff --git a/db/migrate/20090406161854_add_parent_id_to_enumerations.rb b/db/migrate/20090406161854_add_parent_id_to_enumerations.rb new file mode 100644 index 000000000..2c1b1780d --- /dev/null +++ b/db/migrate/20090406161854_add_parent_id_to_enumerations.rb @@ -0,0 +1,9 @@ +class AddParentIdToEnumerations < ActiveRecord::Migration + def self.up + add_column :enumerations, :parent_id, :integer, :null => true, :default => nil + end + + def self.down + remove_column :enumerations, :parent_id + end +end |