Sha256: d4b8b77b474369bbb4c0ed31129caf399f1d4b6970dda227ed7d5bbb3f20a2cc

Contents?: true

Size: 250 Bytes

Versions: 9

Compression:

Stored size: 250 Bytes

Contents

class AddLocaleToAlchemyLanguages < ActiveRecord::Migration[4.2]
  def change
    add_column :alchemy_languages, :locale, :string
    execute \
      "UPDATE #{Alchemy::Language.table_name} SET locale = language_code WHERE locale IS NULL;"
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
alchemy_cms-4.0.6 db/migrate/20150906195818_add_locale_to_alchemy_languages.rb
alchemy_cms-4.0.5 db/migrate/20150906195818_add_locale_to_alchemy_languages.rb
alchemy_cms-4.0.4 db/migrate/20150906195818_add_locale_to_alchemy_languages.rb
alchemy_cms-4.0.3 db/migrate/20150906195818_add_locale_to_alchemy_languages.rb
alchemy_cms-4.0.2 db/migrate/20150906195818_add_locale_to_alchemy_languages.rb
alchemy_cms-4.0.1 db/migrate/20150906195818_add_locale_to_alchemy_languages.rb
alchemy_cms-4.0.0 db/migrate/20150906195818_add_locale_to_alchemy_languages.rb
alchemy_cms-4.0.0.rc2 db/migrate/20150906195818_add_locale_to_alchemy_languages.rb
alchemy_cms-4.0.0.rc1 db/migrate/20150906195818_add_locale_to_alchemy_languages.rb