Sha256: b51b0f7588658474c1a2c3fc30d605bc5f75677b1ce1c32c851cf884dd1f23a2
Contents?: true
Size: 804 Bytes
Versions: 7
Compression:
Stored size: 804 Bytes
Contents
# This migration comes from tb_cms (originally 20140110041105) class DropSpudPageLiquidTags < ActiveRecord::Migration class SpudPageLiquidTag < ActiveRecord::Base end def up SpudPageLiquidTag.all.each do |tag| SpudLiquidTag.create({ :attachment_id => tag.attachment_id, :attachment_type => tag.attachment_type, :tag_name => tag.tag_name, :value => tag.value }) end drop_table :spud_page_liquid_tags end def down create_table :spud_page_liquid_tags do |t| t.integer :attachment_id t.string :attachment_type t.string :tag_name t.string :value t.timestamps end add_index :spud_page_liquid_tags, [:tag_name,:value] add_index :spud_page_liquid_tags, [:attachment_type,:attachment_id] end end
Version data entries
7 entries across 7 versions & 1 rubygems