Advertisement
Guest User

Untitled

a guest
Oct 13th, 2015
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.07 KB | None | 0 0
  1. puts "Updating community products text_help"
  2. text = "License this video for community, corporate, and non-profit viewing"
  3. community_products = Spree::Product.for_distribution_channel(DistributionChannel.find_by(name: 'Community').id)
  4. community_products.update_all(help_text: text)
  5.  
  6. puts "Updating shipping methods"
  7. shipping_method = Spree::ShippingMethod.find_by(name: 'Ground One Way')
  8. shipping_method.update_attributes(name: 'Ground')
  9.  
  10. shipping_method = Spree::ShippingMethod.find_by(name: '2 Day Shipping One Way')
  11. shipping_method.update_attributes(name: 'Two-Day Shipping')
  12.  
  13. shipping_method = Spree::ShippingMethod.find_by(name: 'International One Way')
  14. shipping_method.update_attributes(name: 'International')
  15.  
  16. puts "Updating distribtion channels"
  17. distribution_channel = DistributionChannel.find_by(name: 'Edu')
  18. distribution_channel.update_attributes(name: 'Educational')
  19.  
  20. distribution_channel = DistributionChannel.find_by(name: 'Community')
  21. distribution_channel.update_attributes(name: 'Business / Non-Profit Purchases')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement