Sha256: 52b6d9a2e6c6fe1abacefa5829fc16218a2bbed468cf0ce887d973e364a745ff

Contents?: true

Size: 469 Bytes

Versions: 125

Compression:

Stored size: 469 Bytes

Contents

Spree::Sample.load_sample("products")

size = Spree::OptionType.find_by_presentation!("Size")
color = Spree::OptionType.find_by_presentation!("Color")

ror_baseball_jersey = Spree::Product.find_by_name!("Ruby on Rails Baseball Jersey")
ror_baseball_jersey.option_types = [size, color]
ror_baseball_jersey.save!

spree_baseball_jersey = Spree::Product.find_by_name!("Spree Baseball Jersey")
spree_baseball_jersey.option_types = [size, color]
spree_baseball_jersey.save!

Version data entries

125 entries across 125 versions & 2 rubygems

Version Path
spree_sample-3.2.9 db/samples/product_option_types.rb
spree_sample-3.1.14 db/samples/product_option_types.rb
spree_sample-3.2.8 db/samples/product_option_types.rb
spree_sample-3.1.13 db/samples/product_option_types.rb
spree_sample-3.2.7 db/samples/product_option_types.rb
spree_sample-3.1.12 db/samples/product_option_types.rb
spree_sample-3.2.6 db/samples/product_option_types.rb
spree_sample-3.1.11 db/samples/product_option_types.rb
spree_sample-3.1.10 db/samples/product_option_types.rb
spree_sample-3.2.5 db/samples/product_option_types.rb
spree_sample-3.1.9 db/samples/product_option_types.rb
spree_sample-3.2.4 db/samples/product_option_types.rb
spree_sample-3.1.8 db/samples/product_option_types.rb
spree_sample-3.1.7 db/samples/product_option_types.rb
spree_sample-3.2.3 db/samples/product_option_types.rb
spree_sample-3.2.2 db/samples/product_option_types.rb
spree_sample-3.3.0.rc2 db/samples/product_option_types.rb
spree_sample-3.1.6 db/samples/product_option_types.rb
spree_sample-3.3.0.rc1 db/samples/product_option_types.rb
spree_sample-3.1.5 db/samples/product_option_types.rb