Sha256: c90cc818d55e644f714f34725287df1fdb6e3e5254f476877d59cc882a5d18f5
Contents?: true
Size: 475 Bytes
Versions: 3
Compression:
Stored size: 475 Bytes
Contents
class Create<%= class_name %>Translations < ActiveRecord::Migration def change create_table :<%= singular_table_name %>_translations do |t| t.integer :<%= singular_table_name %>_id t.string :locale <%- @attributes.each do |attribute| -%> t.string :<%= attribute %> <%- end -%> t.timestamps null: false end add_index :<%= singular_table_name %>_translations, [:<%= singular_table_name %>_id, :locale], unique: true end end
Version data entries
3 entries across 3 versions & 1 rubygems