APIDeveloperUserReleasesDemoContact
  • Release Notes

    • Spree 4.2.0
    • Spree 4.1.0
    • Spree 4.0.0
    • Spree 3.7.0
    • Spree 3.6.0
    • Spree 3.5.0
    • Spree 3.4.0
    • Spree 3.3.0
    • Spree 3.2.0
    • Spree 3.1.0
    • Spree 3.0.0
    • Spree 2.4.0
    • Spree 2.3.0
    • Spree 2.2.0
    • Spree 2.1.0
    • Spree 2.0.0
    • Spree 1.3.0
    • Spree 1.2.0
    • Spree 1.1.0
    • Spree 1.0.0

Table Of Contents

OverviewMajor/New FeaturesRuby 3.0 and Rails 6.1 supportNew responsive Admin Panel UIBuilt-in Multi-Currency and Multi-LanguageImproved MultiStore supportNew modern mobile first Email templatesWCAG 2.1 AA compatible StorefrontInstallationUpgradeNoteworthy changesStorefrontAPIAdmin PanelCoreFull Changelog

Spree 4.2.0

Overview

Spree 4.2 is a collaborative work of 34 amazing individuals from around the globe who contributed over 1500 commits since Spree 4.1.

This release was intended to make Spree accessible to anyone in every place of our planet in every country and every major language. Besides new features, this release includes hundreds of bug fixes and improvements.

Major/New Features

Ruby 3.0 and Rails 6.1 support

Spree 4.2 can be run on Ruby 2.5, 2.6, 2.7 and recently released 3.0. Spree 4.2 supports both Rails 6.0 and 6.1 out of the box, so you don’t need to upgrade to Rails 6.1 straight away, you can first move to Spree 4.2 and later perform the Rails upgrade minimizing the risk of any issues. Please see Rails 6.1 announcement to check out the new amazing features that are packed in that release.

New responsive Admin Panel UI

Thanks to the awesome work of Matthew Kennedy supported by Spark team we were able to deliver a brand new and modern Admin UI which works great on mobile and tablet devices.

This was done in a gradual enhancement process of the current codebase so all of the existing Extensions and customizations will still work as it’s fully backward compatible.

The next releases will bring more Admin UI improvements such as a new Reporting dashboard.

Built-in Multi-Currency and Multi-Language

We’ve pulled the best parts of Spree Multi-Currency gem of Spree I18n into Spree itself and improved upon it combined with new multi Store support.

  • each Store can have a default currency and a list of other supported currencies - this will affect products shown in each Store (only Products with prices in those currencies)
  • each Store can have default locale (language) and a list of other supported locales
  • each Product can have different prices in each currency for different Variants
  • you can have multiple Stores with different default locales/currencies or a single Store with multiple locales / languages which you can switch between in the Storefront UI
  • this is also supported by API v1 and v2 by passing simply ?locale=fr and/or ?currency=EUR in the URL
  • Locale and Currency settings will be also respected in all Spree extensions
  • Additional language packs are available via Spree I18n gem

Improved MultiStore support

Besides currency and language, we’ve greatly improved the Multi-Store support in Spree.

There are new additional settings and features for Store management available in the Admin UI:

  • Logo - you can now upload logo, through Admin Panel for each Store :) (Spark Solutions)
  • Mailer Logo - same as above but will be displayed in the email notifications (Spark Solutions)
  • Checkout Zone - which Zone record is used for Checkout, which in fact limits the Checkout for selected Countries or States (Spark Solutions)
  • Default Country - which country should be pre-selected on Checkout Address (Spark Solutions)
  • Order Notification Email for Store Owners (Derek Johnson)
  • Checkout Payment Methods - which Payment Methods should be available in each Store. Each payment method can be now assigned to multiple stores instead of one (Spark Solutions and Matthew Kennedy)
  • Store Contact info that appears in the Storefront footer can be set now in the UI Spark Solutions

New modern mobile first Email templates

Thanks to El Passion team we have now brand new and mobile-first email templates for notifications such as Order Confirmation, Shipment notification and so on. All emails were rebuilt with Postmark Email Templates to meet current needs and standards.

To improve developer happiness our friends at El Passion prepared email previews for all email types to make it more convenient to work with emails in a development environment.

As part of these improvements, more of the email layouts can be managed via Admin UI, this includes:

  • setting different logo for each Store
  • setting locale (language) of Store will be reflected in emails which will be translated automatically, based on Spree I18n
  • setting Store name will automatically change copy in emails
  • all URLs in emails will point to the selected Store, this is also supported by Spree Auth Devise emails as well

WCAG 2.1 AA compatible Storefront

We’ve invested a lot of time to make the default Storefront accessible for everyone. We’ve enhanced Storefront to be compatible with all Web Content Accessibility Guidelines version 2.1.

Installation

  1. Install Docker
  2. Download Spree Starter
  3. Unzip it
  4. Run bin/setup in spree_starter-main directory

Upgrade

Follow 4.1 to 4.2 upgrade guide

Noteworthy changes

Please review each of the noteworthy changes to ensure your customizations or extensions are not affected. If you are affected by a change, and have any suggestions please submit a PR to help the next person!

Storefront

  • Admin users able to set which Option Types should be shown as a filter option in Storefront Spark Solutions
  • Added Compare At price to Products Spark Solutions
  • Added support of OpenGraph meta tags in Storefront Spark Solutions
  • Allow user to add names to addresses Matthew Kennedy
  • Set Product Variant Via URL Query Parameter Matthew Kennedy
  • Adds The Ability To Show / Not Show Specific Product Properties Matthew Kennedy
  • Add ship-to address on Checkout “Choose Delivery Method” page Matthew Kennedy
  • Added support for multiple Relation Types via Related Products gem on product page Spark Solutions
  • Added last_modified and etag helper methods for Spree::ProductsController Spark Solutions
  • Replace jquery.payment with cleave Matthew Kennedy
  • Make config show_raw_product_description usable in new storefront Matthew Kennedy
  • Adds product_add_to_cart event triggering Spark Solutions
  • use Spree.ready instead of document ready on checkout address book Chien-Fu
  • Shows my account store credits in current currency Spark Solutions
  • Improved Performance and caching Spark Solutions

API

  • Added API v2 Stores endpoints Prabin Poudel
  • Added concat_taxons filter to API v2 Products endpoint Florian Bergmann
  • Moved from fast_jsonapi to jsonapi-serializer Spark Solutions
  • Fixed N+1 queries on /api/v2/storefront/taxons Yann Petitjean
  • API v1 controllers now inherit from ActionController::API rather than ActionController::Base

Admin Panel

  • Replace jquery.ui calendar with mobile friendly Flatpickr Cal Matthew Kennedy
  • Refactored splitting order products into shipments by stock location Spark Solutions
  • Add random string instead of ‘new’ in duplicated promotions Spark Solutions
  • Add timezone to dates across entire app Spark Solutions
  • Improve customer attribute editor Gary Lai
  • includes translations to avoid n + 1 query Gary Lai
  • Upgraded Select2 to 4.x Spark Solutions and Matthew Kennedy

Core

  • Added Store#unique_name method Mathew Kennedy
  • Added Product#default_variant_cache_key method Spark solutions
  • Improve Carmen Data Import Matthew Kennedy
  • Normalize promotion code before validation Maksim Shylau
  • Outstanding balance uses reimbursement Chris Hummel
  • Added unique index on taxon_id and product_id in spree_products_taxons Spark Solutions
  • Added active_storage_validations gem to dependencies Spark Solutions
  • Use Spree Dev Tools in extension generator Spark Solutions
  • Updated migrations with column_exists checks to avoid upgrade issues Spark Solutions

Full Changelog

You can view the full changes using Github Compare.

Propose changes to this page
Maintained bySpree Commerce & Ruby on Rails developers© Spree Commerce. 2021 All Rights Reserved.