Sha256: 824ac25a1b6a2cc4023d9722b29fa7a192aeb44a618df617cec287e4992d9644
Contents?: true
Size: 541 Bytes
Versions: 7
Compression:
Stored size: 541 Bytes
Contents
class RenameAttachableToAttachedTo < ActiveRecord::Migration[5.0] def change remove_index :decidim_attachments, name: "index_decidim_attachments_on_attachable_id_and_attachable_type" remove_foreign_key :decidim_attachments, column: :attachable_id rename_column :decidim_attachments, :attachable_id, :attached_to_id rename_column :decidim_attachments, :attachable_type, :attached_to_type add_index :decidim_attachments, [:attached_to_id, :attached_to_type], name: "index_decidim_attachments_on_attached_to" end end
Version data entries
7 entries across 7 versions & 1 rubygems