Use the atg.commerce.catalog.custom.CatalogItemLookupDroplet class, which a subclass of atg.repository.servlet.ItemLookupDroplet, to locate and display items in a catalog-related repository. This servlet bean takes input parameters specifying the repository, repository ID, site ID, site scope, catalog, and item type, and renders the specified item on the page.

Rather than specifying the repository and item type through input parameters, you can set these through the servlet bean’s properties file. Core Commerce includes several lookup components that are configured to use the product catalog as the default repository and find a specific item type. The following components are all based on the CatalogItemLookupDroplet:

If your sites include more than one catalog, or if your catalog uses item types not found in the catalog, you may want to create additional CatalogItemLookupDroplet components. For more information about the CatalogItemLookupDroplet servlet bean, see CatalogItemLookupDroplet in Appendix A: Core Commerce Servlet Beans.

The following additional catalog-related lookup components are based directly on the atg.repository.servlet.ItemLookupDroplet class, which does not include catalog filtering capabilities.

See the Page Developer's Guide for information on the ItemLookupDroplet. This droplet is also used by the gift list feature; see the Core Commerce Programming Guide.

The following example shows a portion of a JSP that uses the ProductLookup component to display the current product. The product’s repository ID is passed to this page (via the itemId parameter) from the page that links to it:

<dsp:droplet name="/atg/commerce/catalog/ProductLookup">
<dsp:param param="itemId" name="id"/>

<dsp:oparam name="output">
<p><b><dsp:valueof param="element.displayName"/></b>
<p><dsp:getvalueof id="img13" param="element.largeImage.url"
<dsp:img src="<%=img13%>"/>
<dsp:valueof param="element.longDescription"/>

Copyright © 1997, 2015 Oracle and/or its affiliates. All rights reserved. Legal Notices