Tutorials > Program model > Web services > Customize Web services and WebSphere Portal to support a new search

< Previous | Next >


Add an expression-builder for the new search expression

This section refers to adding an expression-builder for the new search expression.

In the Enterprise Explorer view of the WebSphere Portal development environment:


Procedure

  1. Expand WebContent/WEB-INF/config/com.ibm.commerce.catalog

  2. Open get-data-config.xml under WEB-INF/config/ext/com.mycompany.commerce.catalog folder.

  3. Insert the following XML before the closing </_config:get-data-config> tag:

    <expression-builder>              
                   
    <name>findCatalogEntriesDetailsByPriceRange</name>
                   
    <data-type-name>CatalogEntry</data-type-name>
           
    <expression-template>
                   
    {_wcf.ap=$accessProfile$}/CatalogEntry[Description[Attributes[published=1]] and [Price[StandardPrice[Price[(Price[@criteria='$name$']
    and Price &gt;= '$minPrice$') and (Price[@criteria='$name$']
    and Price
    <= '$maxPrice$') ]]]]</expression-template>
                   
    <param>
                           
    <name>accessProfile</name>
                           
    <value>WC_CatalogEntryDetailsProfile</value>
                   
    </param>
                   
    <param>
                           
    <name>currency</name>
                           
    <value>USD</value>
                   
    </param>
    </expression-builder>
    

< Previous | Next >


+

Search Tips   |   Advanced Search