Skip to content

Spree extension, provides various ways to select products to highlight -- WORK IN PROGRESS

Notifications You must be signed in to change notification settings

rgagnon/spree-highlight_products

 
 

Repository files navigation

Highlight Products

This is an extension for Spree, put together by jomz

This extension makes it possible to 'highlight' certain products that you can then easily show on the homepage for example. Highlighting a product updates a newly added timestamp on the Product model. There is also a named scope Product.highlighted, which selects all products that have been highlighted, and orders them so that the first in the result is the last one highlighted. There is no 'unhighlight' button.

I started off with paulcc's promotions extension, but the only thing left of it is the best_sellers method, which I moved to the Product model.. There is an other extension also called promotions, which better deserves the name, as it's about actual promotions (lowered prices), and not about promoting something to the home page.

Installation

Copy to your project's vendor/extensions dir, and make sure the naming is right (remove the 'spree-' prefix). Run rake db:migrate. Reboot the server.

Usage

Highlight products from the admin/products index page. Then you can use Product.highlighted(:limit => 3) anywhere to get the last 3 highlighted products.

About

Spree extension, provides various ways to select products to highlight -- WORK IN PROGRESS

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published