Wednesday, September 9, 2015

Business/IT features ATG/Endeca 11

1) Personalization enhancements:
  • Endeca experience manager can now refer user segments created in BCC.
  • Business users working with experience manager can now create page experiences that are specific to user segments             created with in BCC to give personalized experience to different customers. As new segments are created within the BCC, these segments are updated and available to business users in experience manager to use as trigger condition for specific experience (landing page, targeted content etc).
    Benefits:
  • Customers can take advantage of integrated segments management capabilities to simplify creation of targeted experiences.
  • Business users can work efficiently because segments are managed at one place but can be utilized in experience manager also.
2)  Experience Manager Preview enhancements:
  • Experience manager allows business users to make edits and preview changes without needing to mark their changes as live for production.
Benefits:
Business users can work more effectively by previewing inactive content items. This is major feature which is not available in previous version of experience manager.
3) Experience Manager content organization:
  • Endeca experience manager provides more flexible content organization.
  • Content can be managed in hierarchical folder structures that may be organized by brand or category. Permission can be assigned to any folder and folders can be restricted to specific content types.
Benefits:
  • Easy to understand Experience manager UI.
  • Business user teams have flexibility and control over how to organize and manage content to reflect their needs.
  • Folder structures and permissions allow teams to work on project together in a way that supports more decentralized work.
4)  Single signon:
  • Single signon functionality is added between ATG BCC and Endeca experience manager.
  • Endeca workbench is accessible from BCC homepage and BCC is accessible from Endeca workbench so business users can navigate between these 2 business applications.
Benefits:
Business users gets access of both tools by logging into one tool. Similarly logout from one tools logs out user from other tool also.
5) Environment management enhancements:
  • Improved import and export capabilities added in experience manager
Benefits.
  • This enables easier environment migration of experience manager data from one environment to other.
6) Automatic phrasing tool in Experience manager:
  • Endeca workbench includes automatic phrasing tool. Business users can manage multi word search terms that will then be treated as phrase in customer search queries. When site visitor enters search terms in query, the phrasing feature groups these individual terms as single search phrase and results are returned for phrase. Ex: “Red Dress”, “Summer Collection” can be entered in via tool and will be considered as phrase during customer search.
Benefits:
This feature generates specific targeted results for site visitor by eliminating unnecessary results also phrase search results in better conversions.
7) Relevance ranking evaluator:
  • Relevance ranking evaluator tool is included by default in workbench. Business users can run multiple search simultaneously, using different relevance ranking modules and other search parameters.
Benefits:
  • Business users can test different relevancy strategies without requiring extra steps for IT to install the tool.

Triggering Auto Indexing with BCC Project Deployment in Stage Site

Environment Type(ATG 11): This solution is applicable only if Staging/Production both sites are configured in BCC for project deployment. This is not applicable if your BCC workflow does not include Stage Site Target. This is applicable if ATG Stage and ATG production application connects to different Endeca applications.

Problem Statement: OOTB ATG integration with Endeca provides components to trigger Partial Index on Production site target with BCC project deployment but it does not provide components to start Index for project deployment to Stage site.
Solution: Below components can be configured in BCC/ATG Stage servers for triggering index with project deployment to Stage Site. This configuration assumes that indexing will not run on BCC server rather remote index will be triggered on ATG Stage Server.

BCC server components configuration:
1) /atg/commerce/search/ProductCatalogOutputConfig_staging.properties
repositoryItemGroup=/atg/commerce/search/IndexedItemsGroup_staging
repository^=/atg/commerce/search/IndexedItemsGroup_staging.repository
incrementalLoader=/atg/search/repository/IncrementalLoader_staging
targetName=Staging
2) /atg/search/SynchronizationInvoker_staging.properties
localSynchronizationInvoker=null
host=<remote server host>
port=<remote server port>
3) /atg/search/repository/ConfigAndRepositoryPersister_staging.properties
$class=atg.repository.search.indexing.ConfigAndRepositoryPersister
repository=/atg/search/repository/IncrementalItemQueueRepository_staging
transactionManager=/atg/dynamo/transaction/TransactionManager
configAndRepositorySearchStatement=configPath = ?0 AND contentId = ?1 AND repositoryPath = ?2
configAndContentIdSearchStatement=configPath = ?0 AND contentId = ?1
4) /atg/search/repository/ConfigStatePersister_staging.properties
$class=atg.repository.search.indexing.ConfigStatePersister
repository=/atg/search/repository/IncrementalItemQueueRepository_staging
clientLockManager=/atg/dynamo/service/ClientLockManager_staging
itemDescriptorName=searchConfig
sessionIdAddress^=/atg/dynamo/Configuration.drpHostAddr
sessionIdPort^=/atg/dynamo/Configuration.drpPort
alwaysAcquireWriteLock=false
transactionManager=/atg/dynamo/transaction/TransactionManager
5) /atg/search/repository/IncrementalItemQueueRepository_staging.properties
$class=atg.adapter.gsa.GSARepository
dataSource=/atg/dynamo/service/jdbc/DirectJTDataSource_staging
XMLToolsFactory=/atg/dynamo/service/xml/XMLToolsFactory
definitionFiles=/atg/search/repository/IncrementalItemQueue.xml,/atg/endeca/index/endecaIndexing.xml
transactionManager=/atg/dynamo/transaction/TransactionManager
idGenerator=/atg/dynamo/service/IdGenerator_staging
lockManager=/atg/search/service/SearchClientLockManager
eventServer=/atg/search/service/SearchSQLRepositoryEventServer
6) /atg/search/repository/IncrementalItemQueue_staging.properties
$class=atg.repository.search.indexing.IncrementalItemQueue
configAndRepositoryPersister=/atg/search/repository/ConfigAndRepositoryPersister_staging
configStatePersister=/atg/search/repository/ConfigStatePersister_staging
repository=/atg/search/repository/IncrementalItemQueueRepository_staging
transactionManager=/atg/dynamo/transaction/TransactionManager
invalidatorService=/atg/dynamo/service/GSAInvalidatorService
itemDescriptorName=item
7) /atg/search/repository/IncrementalLoader_staging.properties
$class=atg.endeca.index.RecordStoreIncrementalLoaderImpl
configStatePersister=/atg/search/repository/ConfigStatePersister_staging
incrementalItemQueue=/atg/search/repository/IncrementalItemQueue_staging
indexingPeriodicService=/atg/search/repository/IndexingPeriodicService_staging
8) /atg/search/repository/IndexingDeploymentListener.properties
indexingOutputConfigs+=/atg/commerce/search/ProductCatalogOutputConfig_staging
9) /atg/search/repository/IndexingPeriodicService_staging.properties
$class=atg.repository.search.indexing.IndexingPeriodicService
configStatePersister=/atg/search/repository/ConfigStatePersister_staging
incrementalLoader=/atg/search/repository/IncrementalLoader_staging
ATG Stage server components configurations:
1) /atg/commerce/endeca/index/CategoryTreeService.properties
indexingOutputConfig=/atg/commerce/search/ProductCatalogOutputConfig_staging
2) /atg/commerce/endeca/ProductCatalogSimpleIndexingAdmin.properties
$class=atg.endeca.index.admin.SimpleIndexingAdmin
phaseToPrioritiesAndTasks=\
PreIndexing=5:CategoryTreeService,\
RepositoryExport=10:\
SchemaExporter;\
CategoryToDimensionOutputConfig_staging;\
RepositoryTypeDimensionExporter;\
/atg/commerce/search/ProductCatalogOutputConfig_staging,\
EndecaIndexing=15:EndecaScriptService
3) /atg/commerce/endeca/RepositoryTypeDimensionExporter.properties
indexingOutputConfig=/atg/commerce/search/ProductCatalogOutputConfig_staging
4) /atg/commerce/endeca/SchemaExporter.properties
indexingOutputConfig=/atg/commerce/search/ProductCatalogOutputConfig_staging
5) /atg/endeca/ApplicationConfiguration.properties
workbenchPort=<Workbench Port>
workbenchHostName=<Workbench Host>
baseApplicationName=<STAGE APP Name>
keyToApplicationName= default=<STAGE APP Name>
6) /atg/endeca/assembler/AssemblerApplicationConfiguration.properties
defaultMdexPort=<STAGE APP MDEX PORT>
defaultMdexHostName=<STAGE APP MDEX HOST>

Wednesday, September 12, 2012

HOW TO OPEN DOCX, XLSX, PPTX IN MS OFFICE 2003


For all those  who have MS Office 2003 or older versions: 


Please follow below mentioned steps to make your current version (e.g. MS Office 2003) to be able to open all Office 2007 as well as 2010 versions with minor formatting and visual inabilities, (follow the Figures in the end for better understanding):

1. Open your Browser (e.g. Internet Explorer, Mozilla)

2. In the Address Bar paste this link:

http://www.microsoft.com/download/en/details.aspx?id=3 , this link to directly go the page.

(All the instructions are given on that page, still for your convenience: )

3. You’ll find a Download button, click on it.

4. A file named “FileFormatConverters.exe” will be downloaded. But before downloading it will take you to another page for confirmation, and there also you will get a link Start download, clicking on it might not be necessary.

5. In the small Download confirmation window click on Save, and the download will start.

6. After completion Double Click the file FileFormatConverters.exe and follow the steps (mostly “I accept”, Next, Yes), and you are done.

7. Now you will see that all the .docx, .xlsx and .pptx files will have an office Icon and double click any of them to open, edit and save. You will have minor problems if the files contain some special formatting, graphics and designs. But that won’t make the file hard to open.

By installing the Compatibility Pack you will be able to open, edit, and save files using the file formats in newer versions of Word, Excel, and PowerPoint.

Tuesday, September 11, 2012

Some Useful Code Snippets 3

Code for Available Shipping methods droplet


<dsp:droplet name="AvailableShippingMethods">
<dsp:param bean="CartModifierFormHandler.shippingGroup" name="shippingGroup"/>

<dsp:oparam name="output">
<dsp:select bean=" CartModifierFormHandler.shippingGroup.shippingMethod">
<dsp:droplet name="ForEach">
 <dsp:param name="array" param="availableShippingMethods"/>
 <dsp:param name="elementName" value="method"/>

 <dsp:oparam name="output">
 <dsp:getvalueof id="option175" param="method"                 idtype="java.lang.String">
 
                        <dsp:option value="<%=option175%>"/>
                  </dsp:getvalueof>
                   

                  <dsp:valueof param="method"/>
 </dsp:oparam>
</dsp:droplet>
</dsp:select>
</dsp:oparam>
</dsp:droplet>



Code for Inventory Look Up Droplet 


<dsp:droplet 
       name="/atg/commerce/inventory/InventoryLookup">
  <dsp:param name="itemId" param="sku.repositoryId"/>
  <dsp:par-am name="useCache" value="true"/>
  <dsp:oparam name="output">
    <dsp:valueof
      param="inventoryInfo.availabilityStatusMsg"/>
    <br><dsp:valueof
      param="inventoryInfo.availabilityDate"/>
  </dsp:oparam>
</dsp:droplet>


Inventory Manager Methods 
1. queryAvailabilityStatus
2. queryAvailabilityDate
3. inventoryWasUpdated






Thursday, September 6, 2012

How to create a form using ATG Framework



A Form is collection of components i.e input controls such as text box, radio button.... Web Applications require forms to get input from the user. For e.g You might need user information to register to your website or credentials to log in to your website... In this article, Let us see how to create a form using ATG(ART TECHNOLOGY GROUP). A Form can be created in ATG as shown below.
<dsp:form action=”simple.jsp” method=”post”>
<dsp:input type=”text” name=”Emp_name” bean=”/com/src/Employee.empname”/>
<dsp:input type=”password” name=”Emp_name” bean=”/com/src/Employee.empname” value=””/>
<dsp:input type=”submit” value=”Submit”/>
</dsp:form>
The tag dsp:form requires a action attribute and method attribute. The action attribute specifies the next action to be carried out on form submission. The method holds the method name that is used to submit the form (Refer HTML FORM METHODS).
Form Elements can be created as shown in the above example dsp:input tag is used to create the form components to get input from the user. dsp:input can create two kinds of controls:
A form field that gets input from the user that is passed to a component.
A submit button or image for the submission of the form.
All dsp:input tags must be embedded between <dsp:form>..</dsp:form> tags.
The syntax of a dsp:input tag is as shown below
<dsp:input [type="input-control"] [name="input-name"] bean="property-spec" ["source-spec"][checked="{true|false}"] [default="value"][priority=integer-value]/>
The attributes of dsp:input are as follows

Type
The Type attribute specifies the HTML input type such as a checkbox, radio button, or text box, if type is specified, the default type “Text” is considered as the input type. The attribute type can hold the below values.
Text – used to create a text box.
Checkbox- used to create a check box.
Radio- used to create a radio button.
Submit- specifies to display a submit button.
Image - specifies a submit control that uses the image specified by the src or pageattribute.
Password - To create text box for pasword .
Based on the type of input the other attributes of a dsp:input tag varies, For Example a check box control has an attribute checked (to check or uncheck) which is not applicable for a input of type Text i.e. text box.

Name
The Name attribute assigns a name to the input field, which enables access to it during form processing. The name must be unique for all input types other than radio and checkbox.
Bean
The Bean attribute specifies the property that this input field updates on form submission.
For Example in the below code the control emp_name refers to bean Component Employee and property empname. On Submission of the form the value specified in the text box is set to the bean component’s property which can stored for future use.
<dsp:input type=”text” name=”Emp_name” bean=”/com/src/Employee.empname”/>
Checked
The checked attribute is applicable only if the type is set to a checkbox or radio. The checked attribute is used to check or uncheck a radio button or checkbox.
Default
The default attribute specifies the default value of the component. If no input is specified the default value is set to the component’s property.
Priority
The priority attribute specifies the priority of this input field during form processing, relative to other input fields.
Value
The attribute value id valid only if the type attribute is set to submit. Value is the value set for submit button’slabel.
Embedding custom attributes
A dsp:input tag can embed one or more custom attributes by using the dsp:tagAttributetag. The syntax of a dsp:attribute tag is as follows.
<dsp:input ...>
dsp:tagAttribute name="attr-name" value="value"/>
<dsp:input/>
The tag dsp:tagAttributetags is specifically used to add attributes to the generated HTML beyond the fixed set of attributes supported by the DSP tag library.

! make money !

ATG Useful Code Snippets

Code snippet to display items in ShoppingCart 


<dsp:droplet name="ForEach">
 <dsp:param name="array" 
      bean="CartModifierFormHandler.order.commerceItems"/>
 <dsp:oparam name="output">
 <dsp:param name="Ci" param="element"/>
 <input type="text" size="4"
        value='<dsp:valueof param="Ci.quantity"/>'>
 <dsp:valueof param="Ci.catalogRefId"/>
 <dsp:valueof converter="currency" 
      param="Ci.priceInfo.listPrice">no price</dsp:valueof>
 <dsp:valueof converter="currency" 
      param="Ci.priceInfo.amount">no price</dsp:valueof>
 </dsp:oparam>
</dsp:droplet> 


Code snippet to add item to order 


<dsp:form action="genericproduct.jsp" method="post">
 <input name="id" type="hidden" 
  value='<dsp:valueof param="product.repositoryId"/>'>
 <dsp:input type="hidden" value="shoppingcart.jsp"
  bean="CartModifierFormHandler.
                       addItemToOrderSuccessURL"/>
 <dsp:input type="hidden" value="session_expired.jsp"
  bean="CartModifierFormHandler.
                       sessionExpirationURL" />
 <dsp:input type="hidden" 
  paramvalue="product.repositoryId" 
      bean="CartModifierFormHandler.productId"/>

<dsp:select 
     bean="CartModifierFormHandler.catalogRefIds">
 <dsp:droplet name="/atg/dynamo/droplet/ForEach">
   <dsp:param name="array" param="product.childSKUs"/>
   <dsp:param name="indexName" value="skuIndex"/>
   <dsp:oparam name="output">
     <dsp:param name="sku" param="element"/>
     <option value='<dsp:valueof
          param="sku.repositoryId"/>'/>
     <dsp:valueof param="sku.displayName"/>
   </dsp:oparam>
 </dsp:droplet>
</dsp:select>

Quantity: <dsp:input type="text" value="1" size="4" 
     bean="CartModifierFormHandler.quantity"/> <BR>

<dsp:input type="submit" value="Add To Cart" 
     bean="CartModifierFormHandler.addItemToOrder" />

</dsp:form>

Code to display Shopping cart Summary on Top of the Page 


<dsp:setvalue param="NumItems" 
   beanvalue="/atg/commerce/ShoppingCart.current.
                                TotalCommerceItemCount"/>
 <dsp:droplet name="/atg/dynamo/droplet/Switch">
  <dsp:param name="value" param="NumItems"/>
  <dsp:oparam name="1">
    1 item (<dsp:valueof converter="currency"
    bean="/atg/commerce/ShoppingCart.
                            current.priceInfo.amount"/>)
  </dsp:oparam>
  <dsp:oparam name="default">
    <dsp:valueof param="NumItems"/> items (<dsp:valueof 
     converter="currency" bean="/atg/commerce/ShoppingCart.
                              current.priceInfo.amount"/>)


ATG Useful Code Snippets

  1)     Write a XML code for Property having Enumerated Data-Type 


    <property category-resource="categoryPioneerCycling" name="size" data-type="enumerated"
               column-name="clothing_size" display-name-resource="clothingSize">
      
        <attribute name="useCodeForValue" value="false"/>
        <option resource="clothingSizeUnknown" code="0"/>
        <option resource="clothingSizeExtraSmall" code="1"/>
        <option resource="clothingSizeSmall" code="2"/>
        <option resource="clothingSizeMedium" code="3"/>
        
      </property>  


Remember : 
1. Here mentoning the Data-type in important.
2. the attribute useCodeForValue tells whether the code given to options must be used or not.
3. If this attribute is true then options will be stored as integers in the database.


  2)     JSP Code  Error message for each droplet 



   <dsp:droplet name="/atg/dynamo/droplet/ErrorMessageForEach">
      <dsp:param bean="CouponFormHandler.formExceptions" name="exceptions"/>
      <dsp:oparam name="output">
        <dsp:valueof param="message"/>
      </dsp:oparam>
    </dsp:droplet>




3) Write a code to display breadcrumbs i.e nav history on the page.

Step 1 :
     Put the below code in the category or product page in order to get the item id , navAction and nav Count
   
       <dsp:droplet name="/atg/commerce/catalog/CatalogNavHistoryCollector">
         <dsp:param name="item" param="element"/>
         <dsp:param name="navAction" param="navAction"/>
         <dsp:param param="navCount" name="navCount"/>
       </dsp:droplet> 

    Step 2 : Create JSP to dsiplay the breadcrumbs and include it in all pages where you need to display it.
    
   <dsp:importbean bean="/atg/commerce/catalog/CatalogNavHistory"/>
     <dsp:droplet name="/atg/dynamo/droplet/ForEach">
   <dsp:param bean="CatalogNavHistory.navHistory" name="array"/>
   <dsp:param name="elementName" value="historyElement"/>
   <dsp:oparam name="outputStart">
      Navigation History: 
   </dsp:oparam>
   <dsp:oparam name="output">
      <dsp:getvalueof id="templateURL" param="historyElement.template.url" idtype="java.lang.String">
       <dsp:a href="genericcategory.jsp">
         <dsp:param name="id" param="historyElement.repositoryId"/>
         <dsp:param name="navAction" value="pop"/>
         <dsp:param bean="CatalogNavHistory.navCount" name="navCount"/>
       <b>  <dsp:valueof param="historyElement.displayName"/>
       </dsp:a> >></b>
      </dsp:getvalueof>
   </dsp:oparam>
   <dsp:oparam name="empty">
       No navigation history.
   </dsp:oparam>
</dsp:droplet>


  Remember : 1. CatalogNavHistory.navHistory is the component which stores the navigation history
    2. navAction specifies the action to be performed which is of 3 types 
     push --> inorder to push the item used in catgeory/product page
   pop --> used in the breadcrumbs page when used user clicks any of the                                                        item in the breadcrumb   
     jump --> used in search