Sha256: 17f28a5c5ad15533b4a732d14748b7ceb4d7e41daeea1e80dea4f662a2812d67
Contents?: true
Size: 894 Bytes
Versions: 14
Compression:
Stored size: 894 Bytes
Contents
# This migration comes from inkwell (originally 20130202130040) class AddOwnerTypeToLines < ActiveRecord::Migration def change add_column :inkwell_blog_items, :owner_type, :string ::Inkwell::BlogItem.where(:is_owner_user => true).update_all(:owner_type => 'u') ::Inkwell::BlogItem.where(:is_owner_user => false).update_all(:owner_type => 'c') remove_column :inkwell_blog_items, :is_owner_user add_column :inkwell_favorite_items, :owner_type, :string ::Inkwell::FavoriteItem.update_all(:owner_type => 'u') rename_column :inkwell_favorite_items, "#{::Inkwell::Engine::config.user_table.to_s.singularize}_id", :owner_id add_column :inkwell_timeline_items, :owner_type, :string ::Inkwell::TimelineItem.update_all(:owner_type => 'u') rename_column :inkwell_timeline_items, "#{::Inkwell::Engine::config.user_table.to_s.singularize}_id", :owner_id end end
Version data entries
14 entries across 7 versions & 1 rubygems