SoftSlate Commerce
Home » Documentation » HTML Documentation

Version 2.2.1

JSP Changes. 

One key JSP change and some additions were made to the way the shipping options are displayed, in order to accomodate the new shipping rules functionality. If you have created a custom version of /WEB-INF/layouts/default/order/shippingFormGuts.jsp, you must update it so it submits the shipping option in the new format.

  1. In the JSP template that produces the shipping options displayed to the user, /WEB-INF/layouts/default/order/shippingFormGuts.jsp, the format of the form parameter for the shipping option that is submitted has changed. Where it used to submit simply the "code" of the shipping option, it now submits the processor class name and the code, in a pipe-delimited string: <processorclassname>|<code>. Refer to /WEB-INF/layouts/default/order/shippingFormGuts.jsp in the new upgrade for an example.
  2. Additional map elements for each option are returned now with the built in shipping processors, which you can now use to display in the shipping selection form. These new map elements include: processorClass, processorName, originalPriceDouble, originalPrice, and discounts, which is a Collection of discounts applicable to the shipping cost.

Shipping Processor Changes. 

Although no formal interface changes were made, the contract between the com.softslate.commerce.businessobjects.shipping.ShippingProcessor interface, the com.softslate.commerce.businessobjects.shipping.BaseShippingProcessor abstract class, and all of their implementations has changed. If you have created your own custom Java shipping processor class, please review your implementations as you upgrade your application to 2.2.

  1. New elements are required to be present in the Map objects returned by the Map loadShippingOptions(Map parameters) method, which represent each shipping option:

    priceDouble: The raw price for the shipping option represented as a Double. This object is used to set the shipping amount in the order by com.softslate.commerce.businessobjects.shipping.BaseShippingProcessor. It is now required to be present in the Map objects returned by Map loadShippingOptions(Map parameters).

    processorClass: The name of the class handling this option. If your implementation subclasses com.softslate.commerce.businessobjects.shipping.BaseShippingProcessor, this element will be inserted for you, with the class name of your processor. This is element is now used as part of the form parameter submitted with the value of the shipping option so the system can identify both the processor class and the option that was selected.

    processorName: The name displayed to users in front of each of the options, identifying the carrier or shipper for each option. If your implementation subclasses com.softslate.commerce.businessobjects.shipping.BaseShippingProcessor, this element will be inserted for you, with a string that is derived by taking the class name and eliminating the string "ShippingProcessor" from it. For example, the options for the UPSShippingProcessor will be displayed with "UPS" in front of each.

  2. Whereas previously it was up to each shipping processor to ensure that the shipping option selected by the user was its own, now only the processor corresponding to the selected option is invoked.

    In addition to passing in the shippingOption selected by the user, a new map element, availableOptions is passed in to the Map processShipping(Map parameters) method. This Collection contains a filtered list of options that are available, according to any shipping rules that may be in effect. The processor's own loadShippingOptions() is called to produce the list, and then the applicable shipping rules are applied to the options.

    com.softslate.commerce.businessobjects.shipping.BaseShippingProcessor calls new helper methods within its implementation of Map processShipping(Map parameters). The new methods verify that the shipping selection is in the allowed list of availableOptions, and also set the shipping cost in the order. In many cases, the Map processShipping(Map parameters) of BaseShippingProcessor is all that is needed to process shipping for most processors. The abstract method int processShipping() is still available as a hook for custom shipping processors but in many cases it need only return a 0, for a successful processing.

Interface Additions. 

Several interface additions were made to support new features. At the next restart, the system will attempt to add the following lines to your /WEB-INF/classes/appComponents.properties file to support the new interface implementations. If the server does not have writable permissions for that file, or if you are maintaining that file manually, you will want to add these configurations manually as you perform the upgrade.

					
googleNewOrderNotificationProcessor=com.softslate.commerce.businessobjects.payment.google.notification.NewOrderNotificationProcessorImpl
importDAOImplementer=com.softslate.commerce.daos.importexport.ImportDAOHibernate
importProcessorImplementer=com.softslate.commerce.businessobjects.importexport.BasicImportProcessor
exportProcessorImplementer=com.softslate.commerce.businessobjects.importexport.BasicExportProcessor
				

Interface Change. 

One interface change was made to support the new image upload feature. Please take note of the following change snd update your custom implementation if necessary, as you upgrade your application to 2.2.1.

  1. Implementations of com.softslate.commerce.customer.core.ActionUtils must now implement Integer saveFile() and Integer makeFileNameNice()

Key Settings Added. 

Two new system settings controlling the location of uploaded images have been added, and these should be set manually before the new image upload feature is used. Go to the Settings -> System screen to define the URL path and the system path to the directory where uploaded images are placed.

Copyright © 2009-2017 SoftSlate, LLC. All Rights Reserved.

Powered by SoftSlate Commerce

Foraker Design