Page tree
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 10 Next »


To be able to implement a great shopping experience modern front-end technology should be supported, e.g. AngularJS or similar. This is best achieved if the main shop functionality is provided by a REST API. The API should support the following methods

  • get products
    • standard Magnolia /nodes rest call?
    • or do we need a "nodeByIdentifier" call?
    • where and how should the image links be created?
  • get shopping cart of current user
    • Attention: currently the shop name is ignored! See "Fix for multiple shops" below.
  • create new shopping cart for current user
    • should an error be returned when a cart for the current user and shop already exists?
  • update shopping cart of current user
  • process shopping cart (save data in JCR, notification mails etc.)
    • standard Magnolia /commands rest call
  • create new cart items
  • update a cart item
  • delete a cart item

Most of the functionality needed to implement this REST API already exists in ShopUtil. Some functionality however is placed in model classes. The shop module should now be refactored so that all of the functionality is placed in a service class and both the model classes and the REST API make use of this functionality. See  MSHOP-187 - Getting issue details... STATUS

Support for multiple languages

The dialogs (e.g. shopProduct) do not reflect the i18n settings. Adding a i18n:true to the title field and adding a mapping for the workspace and path did not have an effect. See  MSHOP-190 - Getting issue details... STATUS .

According to Antti Hietala's comments on i18n support in content apps seems to be a generic issue. Therefore it is out of the scope of a shop module upgrade.

Configuration improvements

There is a whole series of problems with the shop setup:

  • MSHOP-183 - Getting issue details... STATUS
  • MSHOP-184 - Getting issue details... STATUS
  • MSHOP-189 - Getting issue details... STATUS
  • MSHOP-185 - Getting issue details... STATUS
    • Is the selection of a default price category really necessary? Wouldn't it be easier to simply use the first price category in none other has been selected for the cart? Setup currently is awkward as you create a shop where you should select a default price category which does not exist at that point yet.
    • However: Getting rid of the default price category selection in the shop config and instead simply selecting the first price category in the list might break the update path for some installations!

Fix support for multiple shops

Although multiple shops could theoretically be set up (especially once the config bugs above are fixed), the shop name is completely ignored when the carts are accessed. This means that when you run multiple shops in one Magnolia the carts will get mixed up. See  MSHOP-188 - Getting issue details... STATUS

This should be rather easy to fix. When accessing a shopping cart the shop name needs to be placed as prefix in front of the "shoppingCart" session variable name. That should do the trick. At the same time the shopping cart variable name which is configurable in the shop setup (but ignored at runtime) can be removed. This should not have any negative effects on existing installations as it only affects runtime data.

Other bugfixes

  • MSHOP-44 - Getting issue details... STATUS
    • Upgrade path: requires proper version handler task!
  • MSHOP-48 - Getting issue details... STATUS
    • test - does this bug really affect 2.x versions?
  • MSHOP-52 - Getting issue details... STATUS

Other improvements

  • No labels