Mercurial > hg > soundsoftware-site
comparison db/migrate/20100819172912_enable_calendar_and_gantt_modules_where_appropriate.rb @ 1295:622f24f53b42 redmine-2.3
Update to Redmine SVN revision 11972 on 2.3-stable branch
author | Chris Cannam |
---|---|
date | Fri, 14 Jun 2013 09:02:21 +0100 |
parents | 1d32c0a0efbf |
children |
comparison
equal
deleted
inserted
replaced
1294:3e4c3460b6ca | 1295:622f24f53b42 |
---|---|
1 class EnableCalendarAndGanttModulesWhereAppropriate < ActiveRecord::Migration | 1 class EnableCalendarAndGanttModulesWhereAppropriate < ActiveRecord::Migration |
2 def self.up | 2 def self.up |
3 EnabledModule.find(:all, :conditions => ["name = ?", 'issue_tracking']).each do |e| | 3 EnabledModule.where(:name => 'issue_tracking').all.each do |e| |
4 EnabledModule.create(:name => 'calendar', :project_id => e.project_id) | 4 EnabledModule.create(:name => 'calendar', :project_id => e.project_id) |
5 EnabledModule.create(:name => 'gantt', :project_id => e.project_id) | 5 EnabledModule.create(:name => 'gantt', :project_id => e.project_id) |
6 end | 6 end |
7 end | 7 end |
8 | 8 |