Solidus Auction

Build Status

This extension adds auction items, bidding, views, and admin pages to an existing Solidus store. Namely, it allows the creation of auctions for specific store items. It retains the existing fulfillment flow.

Its bidding mechanism is similar to eBay's in that it allows bidders to submit very high bids that "autobid" for them, up to that original bid's price in increments set by the auction (or their opponents). See eBay's explanation for more details.

More specifically, when an auction completes, a Spree::Variant with the Auction.current_price and tied to the auction's Spree::Product gets created. This Spree::Variant differs from the normal kind because typically it needs an option_value (such as a size, small, medium, or large, in the bootstrap examples). However, Solidus still allows you to check out with a variant, regardless of whether or not it has option_values. Because of this, none of the typical checkout/fulfillment flow is effected by the auction.

Preview Images


Index index Show show Cart. Notice that for auction items, the delete button is nonexistent and the quantity button is disabled. cart Admin Index admin_index Admin Edit edit

Installation


Add solidus_auction to your Gemfile:

  gem 'solidus_auction'

Bundle your dependencies and run the installation generator:

  bundle
  bundle exec rails g solidus_auction:install

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, and Rubocop static code analysis. 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 'solidus_auction/factories'

Copyright (c) 2018 [Jeffrey Gu], released under the New BSD License