Assets in Commerce Catalog UI do not sort by SortOrder

Fixed in

EPiServer.Commerce 13.28.0

Created

Oct 12, 2020

Updated

Jul 09, 2021

State

Closed, Fixed and tested


Description

Fixed issue where assets in the Commerce catalog are incorrectly sorted.

Preconditions: There are 4 images uploaded to a folder in the Media pane in the Commerce Catalog UI: 1.0.jpg, 1.1.jpg, 1.2.jpg and 2.0.jpg.

Steps to reproduce:

  1. Create a new product "TestProduct", then open Assets tab to add following images to the product: 1.0.jpg, 1.1.jpg and1.2.jpg.
  2. Open another product/category/catalog, or publish the current "TestProduct" product.
  3. Add 2.0.jpg to "TestProduct".
  4. Repeat the 2nd step.

Expected: The images in the Assets tab folder for "TestProduct" should display with the correct sort order.
(1.0.jpg, 1.1.jpg, 1.2.jpg and 2.0.jpg.)

Actual: Incorrect sort order for added images (1.0.jpg, 2.0.jpg, 1.1.jpg, 1.2.jpg).