Feature #14688 » 20130814110000_change_issue_categories_name_limit.rb
| 1 |
class ChangeIssueCategoriesNameLimit < ActiveRecord::Migration |
|---|---|
| 2 |
def self.up |
| 3 |
change_table :issue_categories do |t| |
| 4 |
t.change :name, :string, :limit => 60 # Old : 30 |
| 5 |
end
|
| 6 |
end
|
| 7 |
|
| 8 |
def self.down |
| 9 |
raise ActiveRecord::IrreversibleMigration, "La taille du champ name de la table ne peut repasser de 60 à 30, on perdrait des données!" |
| 10 |
end
|
| 11 |
end
|