Sha256: 02996a802b8e76ca4839e1d6a84a356d9b952c795ccadafc4ab911f006a59143

Contents?: true

Size: 286 Bytes

Versions: 42

Compression:

Stored size: 286 Bytes

Contents

class RenameVariantsToSellables < ActiveRecord::Migration
  def up
    rename_table :variants, :sellables
    rename_column :line_items, :variant_id, :sellable_id
  end

  def down
    rename_table :sellables, :variants
    rename_column :line_items, :sellable_id, :variant_id
  end
end

Version data entries

42 entries across 42 versions & 1 rubygems

Version Path
piggybak-0.6.1 db/migrate/20121008160425_rename_variants_to_sellables.rb
piggybak-0.6.0 db/migrate/20121008160425_rename_variants_to_sellables.rb