SoftSlate Commerce
Home » Documentation » HTML Documentation

Incorporating 1.x Customizations into 2.x

Following is a list of the common ways to customize SoftSlate Commerce, and suggestions for how to proceed with incorporating each type of customization from 1.x to 2.x.

  1. Custom Java Classes. 

    A number of interface changes were made in the API from 1.x to 2.x. You will need to be aware of these changes, and may need to update your custom Java classes to conform to the new API. For a list of these interface changes, visit the following section of the Migration Guide.

    Another important change from 1.x to 2.x is that the custom implementations of the various interfaces are no longer stored as settings in the npcSetting database table. They are now stored in the /WEB-INF/classes/ file. When you are ready to test your custom classes, you must either update this file manually, or you may use the Store Settings -> Components screen to modify the file through the 2.x Administrator.


    To identify a custom implementation of a Java class in 2.x, you must either update the /WEB-INF/classes/ file manually, or you may use the Settings -> Components screen to modify the file through the 2.x Administrator.

  2. Custom SQL Queries. 

    If you created custom SQL queries for 1.x in one of more of the files found under the subdirectories of the /WEB-INF/classes/resources directory, you may create analogous queries in the queries-custom.hbm.xml files in the same directories in 2.x.

    Please be aware, however, that the queries-custom.hbm.xml files are used by Hibernate, and consist of queries written in the Hibernate Query Language (HQL). A working knowledge of Hibernate and HQL is essential to writing custom queries.


    Because SoftSlate Commerce 2.x employs Hibernate, custom queries are written in the Hibernate Query Language (HQL), rather than SQL.

  3. Custom JSP Templates. 

    In a few cases, the default JSP templates have changed dramatically. Pay special note to the list of JSP template changes in the following section of the Migration Guide. If you created custom JSP template in the /WEB-INF/layouts/custom directory, they may need to be updated to interact correctly with the default 2.x templates. A good way to go about incorporating the customizations is to copy each custom JSP template over to the 2.x installation one at time, and testing each one for errors or other issues.

  4. Custom Struts Configurations. 

    Any custom Struts configurations you made in /WEB-INF/conf/core/struts-config-custom.xml should translate directly to 2.x. Simply copy the file over to 2.x, and test the custom form beans and actions to make sure there are no complications.


    Because of the interface changes from 1.x to 2.x, your custom Struts action classes may need to be modified to conform to the new API.

  5. Custom Tiles Definitions. 

    Custom Tiles definitions you made in /WEB-INF/conf/core/tiles-defs-custom.xml . should translate directly from 1.x to 2.x. Be sure to test them after copying the file from the 1.x to 2.x installation.

Numerous interface changes were made to simplify the API and adapt it for use with the Hibernate persistance framework. Keep the following changes in mind as you incorporate any Java class customizations from 1.x into 2.x.

  1. All objects implementing BusinessProcessor must now implement getSettings() and setSettings(Settings settings) rather than getSettingsBean() and setSettingsBean().
  2. UpgradesProcessor, etc. that refer to SettingsBean must now refer to the Settings interface.
  3. Custom objects subclassing BaseForm and BaseDynaForm must refer to getSettings() rather than getSettingsBean().
  4. load*FromID() changed in all Processor classes to return a bean object rather than a Map.
  5. Changed many property types in bean objects to wrapper classes for better integration with Hibernate. If the field was an int or double but nullable, it's now Integer or Double.
  6. All the main Struts action forms in the Administrator for each of the administrator control screen have a new property: a String[] of "searchFields" containing the field names that are searchable.
  7. Attribute property attributeOrder now an int.
  8. Category getParentCollection is now a collection of parent Category objects, not the Integer Ids
  9. Category must implement getParent, setParent, getProductCategories, setProductCategories
  10. Product must implement getProductCategories, setProductCategories, getPrimaryCategory, setPrimaryCategory
  11. processOrder() method of OrderGatewayDAO interface no longer part of the interface.
  12. ProductGatewayDAO implementers now must implement Collection loadAttributeSKUs()
  13. Category implementers must implement products property, for products with the category as a primary category.
  14. Country must implement getStates(), and States must implement getCountry().
  15. Administrator must implement decryptedPassword property.
  16. Administrator now implements getRoleCodes() instead of getRoles()
  17. AdministratorDAO no longer must implement updateAdministratorNoPassword().
  18. AttributeDAO.loadAttributeOptions() removed.
  19. ProductGatewayDAO.loadAllProductNamesCodesIDs()
  20. Customer must implement decryptedPassword property.
  21. CustomerDAO no longer must implement updateCustomerNoPassword()
  22. Payment must implement decryptedNumber property.
  23. Payment DAO no longer must implement updatePaymentNoNumber()
  24. vvCustomerGatewayDAO.processLogin() now returns a Map not a Collection.
  25. CustomerGatewayDAO.updateCustomer() now returns a Map not a Collection.
  26. CustomerProcessor.loadCustomerLostPassword() now returns a Map not void
  27. CustomerGatewayDAO.updateAddresses() now returns a Map not void.
  28. CustomerGatewayDAO.processRegister() takes one argument - User.
  29. CustomerProcessor no longer must implement the customer property.
  30. ShipingProcessor.loadShippingOptions() can accept a Map as an argument.
  31. ProductAttribute must implement new property productAttributeOrder

In a few cases, the default JSP templates have changed dramatically. Because of this, we recommend installing 2.x from scratch and incorporating any custom JSP templates you created into the corresponding 2.x templates manually. As you do so, keep the following major JSP template changes in mind:

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

Powered by SoftSlate Commerce

Foraker Design