Module for Stripe payment functionality in the Trado Ecommerce platform. If you would like to get started using the Trado Ecommerce platform, head on over to the Official site!
Add module to your Gemfile:
Then run bundle to install the Gem:
Set up an initializer file with your Stripe API keys: (You can sign up for a Stripe account here)
Rails.application.config.stripe.secret_key = "stripe_secret_key" Rails.application.config.stripe.publishable_key = "stripe_public_key"
e.g. config/initializers/stripe.rb. It would be a good idea to store sensitive data in config/secrets.yml.
Now generate migrations, copy controllers and assign model concerns:
rails generate trado_stripe_module:install bundle exec rake db:migrate
Add the Stripe JS files to the theme application.js:
//= require trado-stripe
You can also customise the HTML for your credit card form and data in checkout:
rails generate trado_stripe_module:views
Restart the main application server:
foreman start -f Procfile.dev
You can then modify the Stripe Statement Descriptor in store settings to customise your customers credit card statement information.
Trado Stripe module follows Semantic Versioning 2.0 as defined at http://semver.org.
How to contribute
- Fork the project
- Create your feature or bug fix
- Add the requried tests for it.
- Commit (do not change version or history)
- Send a pull request against the development branch