spree-contrib / spree_related_products

Related products extension for Spree Commerce.
http://guides.spreecommerce.org
BSD 3-Clause "New" or "Revised" License
149 stars 241 forks source link

1 1 stable #53

Closed svegaca closed 10 years ago

svegaca commented 11 years ago

Hello, I am using branch 1-1-stable of your gem, spree_related products. I added some fixes: 1- I added some translations from the master branch. 2- Since Rails 3.2 version, you have to add attr_accesible to your desired attributes. I set attr_accessible to the preferred_item_total_threshold method in Calculator::RelatedProductDiscount. So the error "Can't mass-assign protected attributes: preferred_item_total_threshold" is fixed. 3- Finally, I commented two lines in Calculator::RelatedProductDiscount:

preference :item_total_threshold, :decimal, :default => 5

# attr_accessible :preferred_item_total_threshold

Because this preference of the calculator is not being used anywhere. I think this changes will work in other branches too.

radar commented 11 years ago

Please show us steps to reproduce the issue that the attr_accessible call fixes.

peterberkenbosch commented 10 years ago

Is this still current? 1-1-stable is old and no longer actively supported anymore. @innovega //cc @radar

radar commented 10 years ago

No, I don't think it is current any more. @innovega, if this is still a problem for a more recent Spree release, then please re-submit. Thanks!