Sha256: f17e85072760c05b2d36fc4872af301d1fbb31c419430a33755c53a716eb701b

Contents?: true

Size: 455 Bytes

Versions: 6

Compression:

Stored size: 455 Bytes

Contents

class CreateTranslatedWords < ActiveRecord::Migration
  def change
    create_table(:translated_words) do |t|
      t.string  :translatable_type, null: false
      t.integer :translatable_id, null: false
      t.string  :key, null: false
      t.string  :locale, null: false
      t.string  :value, null: false
      t.index [:translatable_type, :translatable_id, :key, :locale], name: 'translated_word', unique: true
      t.timestamps
    end
  end
end

Version data entries

6 entries across 3 versions & 1 rubygems

Version Path
ar-translatable-0.1.0 lib/generators/translatable/templates/migration.rb
ar-translatable-0.1.0 spec/dummy/db/migrate/20140625163354_create_translated_words.rb
ar-translatable-0.0.2 lib/generators/translatable/templates/migration.rb
ar-translatable-0.0.2 spec/dummy/db/migrate/20140625163354_create_translated_words.rb
ar-translatable-0.0.1 lib/generators/translatable/templates/migration.rb
ar-translatable-0.0.1 spec/dummy/db/migrate/20140625163354_create_translated_words.rb