Files
nairobi/db/migrate/20180801114529_add_poll_question_answer_translations.rb
Javi Martín be25e5fc45 Use migrate_data option for globalize
This way the task to migrate the data doesn't have to be run manually if
these migrations weren't already executed.
2018-10-23 16:29:13 +02:00

18 lines
329 B
Ruby

class AddPollQuestionAnswerTranslations < ActiveRecord::Migration
def self.up
Poll::Question::Answer.create_translation_table!(
{
title: :string,
description: :text
},
{ migrate_data: true }
)
end
def self.down
Poll::Question::Answer.drop_translation_table!
end
end