Sha256: 02eda6c135498253f63a47a442b58c4d828cac13e88c0ccd041f7508d1abe716

Contents?: true

Size: 683 Bytes

Versions: 7

Compression:

Stored size: 683 Bytes

Contents

# This migration comes from spree (originally 20100506180619)
class AddIconToTaxons < ActiveRecord::Migration
  def up
    # skip this migration if the attribute already exists because of advanced taxon extension
    return if column_exists?(:taxons, :icon_file_name)
    add_column :taxons, :icon_file_name,    :string
    add_column :taxons, :icon_content_type, :string
    add_column :taxons, :icon_file_size,    :integer
    add_column :taxons, :icon_updated_at,   :datetime
  end

  def down
    remove_column :taxons, :icon_file_name
    remove_column :taxons, :icon_content_type
    remove_column :taxons, :icon_file_size
    remove_column :taxons, :icon_updated_at
  end
end

Version data entries

7 entries across 7 versions & 2 rubygems

Version Path
spree_mercado_pago_payment_method-0.0.2 spec/dummy/db/migrate/20121121030179_add_icon_to_taxons.spree.rb
spree_mercado_pago_payment_method-0.1.1 spec/dummy/db/migrate/20121121030179_add_icon_to_taxons.spree.rb
spree_mercado_pago_payment_method-0.1.0 spec/dummy/db/migrate/20121121030179_add_icon_to_taxons.spree.rb
datashift_spree-0.3.0 spec/sandbox/db/migrate/20121023154398_add_icon_to_taxons.spree.rb
datashift_spree-0.2.1 spec/sandbox/db/migrate/20121015151191_add_icon_to_taxons.spree.rb
datashift_spree-0.2.0 spec/sandbox/db/migrate/20120925192759_add_icon_to_taxons.spree.rb
datashift_spree-0.1.0 spec/sandbox/db/migrate/20120918081490_add_icon_to_taxons.spree.rb