diff options
-rw-r--r-- | db/migrate/20151210191646_move_posts_to_proper_locale.rb | 9 | ||||
-rw-r--r-- | db/schema.rb | 2 |
2 files changed, 10 insertions, 1 deletions
diff --git a/db/migrate/20151210191646_move_posts_to_proper_locale.rb b/db/migrate/20151210191646_move_posts_to_proper_locale.rb new file mode 100644 index 0000000..faeaf3c --- /dev/null +++ b/db/migrate/20151210191646_move_posts_to_proper_locale.rb @@ -0,0 +1,9 @@ +class MovePostsToProperLocale < ActiveRecord::Migration + def up + Refinery::Blog::Post::Translation.all.each { |tx| tx.locale = "nb"; tx.save! } + end + + def down + Refinery::Blog::Post::Translation.all.each { |tx| tx.locale = "en"; tx.save! } + end +end diff --git a/db/schema.rb b/db/schema.rb index b853b26..4d3fe93 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -11,7 +11,7 @@ # # It's strongly recommended to check this file into your version control system. -ActiveRecord::Schema.define(:version => 20151114112243) do +ActiveRecord::Schema.define(:version => 20151210191646) do create_table "refinery_banners", :force => true do |t| t.string "name" |