- Each RemoteTranslation is associated with a resource (through polymorphic) and has the locale to we want translate. - After create a RemoteTranslation we create a enqueue_remote_translation method that will be send remote translation instance to remote translation client
13 lines
303 B
Ruby
13 lines
303 B
Ruby
class CreateRemoteTranslations < ActiveRecord::Migration[4.2]
|
|
def change
|
|
create_table :remote_translations do |t|
|
|
t.string :locale
|
|
t.integer :remote_translatable_id
|
|
t.string :remote_translatable_type
|
|
t.text :error_message
|
|
|
|
t.timestamps null: false
|
|
end
|
|
end
|
|
end
|