This discussion is archived
3 Replies Latest reply: Nov 15, 2013 6:45 AM by Jitendra Vishnoi RSS

Which component should use to compare SKUs

Jitendra Vishnoi Newbie
Currently Being Moderated

Hi All,

 

I am trying to compare between SKUs and I checked with CompareSkusFormHandler but it seems that all methods are deprecated, which component should I use.

Thanks in advance.

  • 1. Re: Which component should use to compare SKUs
    David_DE Journeyer
    Currently Being Moderated

    you can try the atg.commerce.catalog.comparison.ProductComparisonList class, this is the recommended class. This is described in section "Understanding the Product Comparison System" of the Commerce Programming Guide. It is also described in the ATG API.

  • 2. Re: Which component should use to compare SKUs
    Nitin Dubey Pro
    Currently Being Moderated

    If u want to do Generic Comparision:

    There are three componetns:

    1. ProductList: It will store ur products to be compared.
    2. ProductListContains: it is used to check whether ProductList contains passed productId or not.it will be used mostly on listing page/details page to disable add to compare button once the product is added to list,
    3. ProductListHandler: it is used to add or remove products from list.

     

    Approach:

    1. On Listing/Details page, Create on button to add product to comparison list.Use ProductListHandler and pass productid to it and on success( if ProductList count is more than one) move to compare page.
    2. On Comapre Page, Iterate ProductList and display individual details.
  • 3. Re: Which component should use to compare SKUs
    Jitendra Vishnoi Newbie
    Currently Being Moderated

    Thanks David and Nitin, Actually I checked with DCSSampleCatalog and In this they are comparing between two product and using ProductList for comparison, It seems like ProductList, ProductListContains, ProductListHandler( because of their names) are being used to compare between two products.

    I checked for SKU comparison Selecting two SKUs to Compare and they are using CompareSkusFormHandler for comparing between two SKUs, but the problem is CompareSkusFormHandler is deprecated now.

     

    I am looking for alternative of CompareSkusFormHandler which can used to compare to SKU(same product).

     

    Appreciate all your support.

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points