Skip to content

Spree Alternate Prices - Provides alternate variant prices (with multi-currency)

License

Notifications You must be signed in to change notification settings

aegixx/spree_alternate_prices

Repository files navigation

SpreeAlternatePrices

Adds alternate product prices that can be applied via Promotions. Adds a category to the Price model that is ignored until specifically referenced.

Installation

  1. Add spree_alternate_prices to your Gemfile:
gem 'spree_alternate_prices', github: 'aegixx/spree_alternate_prices', branch: '2-4-stable'
  1. Bundle your dependencies:
bundle
  1. (OPTIONAL) This is built on top of spree_multi_currency, so run that installation generator first (if you haven't already):
bundle && bundle exec rails g spree_multi_currency:install
  1. Now run this installation generator (you can skip the bundle if you completed Step 3:
bundle && bundle exec rails g spree_alternate_prices:install
  1. (OPTIONAL) Add Calculator to config/initializers/spree.rb configuration:
Rails.application.config.spree.calculators.promotion_actions_create_item_adjustments << Spree::Calculator::AlternatePriceCalculator

Testing

First bundle your dependencies, then run rake. rake will default to building the dummy app if it does not exist, then it will run specs. The dummy app can be regenerated by using rake test_app.

bundle && bundle exec rake

When testing your applications integration with this extension you may use it's factories. Simply add this require statement to your spec_helper:

require 'spree_alternate_prices/factories'

Copyright (c) 2015 Kailos Genetics, Inc., released under the New BSD License

About

Spree Alternate Prices - Provides alternate variant prices (with multi-currency)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published