Skip to content

shubham-kaushal/spree_fixed_amount_discount

 
 

Repository files navigation

Spree Fixed Amount Discount

Installation

  1. Add this extension to your Gemfile with this line:
gem 'spree_fixed_amount_discount', github: 'matthewkennedy/spree_fixed_amount_discount'
  1. Install the gem using Bundler:
bundle install
  1. Restart your server

If your server was running, restart it so that it can find the assets properly.

Using

Under the Promotion Actions panel select Create per-line-item adjustment and click Add. In the drop-down menu you should see Fixed Amount (Items total), select this, click update and then enter a fixed amount and currency that you want to deduct from the order.

You should now have a whole order style discount that takes into account each line items tax.

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_fixed_amount_discount/factories'

Contributing

If you'd like to contribute, please take a look at the instructions for installing dependencies and crafting a good pull request.

Copyright (c) 2019 [name of extension creator], released under the New BSD License

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Ruby 100.0%