To check out this repository please hg clone the following URL, or open the URL using EasyMercurial or your preferred Mercurial client.
root / db / migrate / 065_add_settings_updated_on.rb @ 1298:4f746d8966dd
History | View | Annotate | Download (241 Bytes)
| 1 | 0:513646585e45 | Chris | class AddSettingsUpdatedOn < ActiveRecord::Migration |
|---|---|---|---|
| 2 | def self.up |
||
| 3 | add_column :settings, :updated_on, :timestamp |
||
| 4 | # set updated_on
|
||
| 5 | 1295:622f24f53b42 | Chris | Setting.all.each(&:save) |
| 6 | 0:513646585e45 | Chris | end
|
| 7 | |||
| 8 | def self.down |
||
| 9 | remove_column :settings, :updated_on |
||
| 10 | end
|
||
| 11 | end |