Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # remove first seeded data with wrong collar option
- p=Spree::Product.find_by(slug: "body_satchel")
- variant_ids=p.variants.select{|v| v.option_value_ids.count == 1}.map(&:id)
- Spree::Variant.where(id: variant_ids).each do |variant|
- variant.really_destroy!
- end
- # reupload broken body pov image
- pov=p.master.point_of_views.where(seen_from: "angled").first
- asset=p.master.original_assets.where(point_of_view_id: pov.id).first
- pov.image.update_attribute(:attachment, URI.parse(asset.attachment.url(:size1800)))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement