Browse Source

migration: Cheat and rename the tables in the migration...

This needs to be done to work with newer spree that do not have
the upgrade path from 0.6 to 1.3... in the production environment
this was not noticed as the rename_table was doing this migration
for us..
1-2-stable-sysmocom
Holger Hans Peter Freyther 8 years ago
parent
commit
fd646a090c
  1. 4
      db/migrate/20120801104503_dhl_shipping_details.rb
  2. 4
      db/migrate/20120804143723_dhl_shipping_migration.rb

4
db/migrate/20120801104503_dhl_shipping_details.rb

@ -1,9 +1,9 @@
class DhlShippingDetails < ActiveRecord::Migration
def self.up
add_column :shipping_methods, :method_details, :string
add_column :spree_shipping_methods, :method_details, :string
end
def self.down
remove_column :shipping_methods, :method_details
remove_column :spree_shipping_methods, :method_details
end
end

4
db/migrate/20120804143723_dhl_shipping_migration.rb

@ -1,9 +1,9 @@
class DhlShippingMigration < ActiveRecord::Migration
def self.up
change_column :shipping_methods, :method_details, :text
change_column :spree_shipping_methods, :method_details, :text
end
def self.down
change_column :shipping_methods, :method_details, :string
change_column :spree_shipping_methods, :method_details, :string
end
end
Loading…
Cancel
Save