[ 
https://issues.apache.org/jira/browse/OFBIZ-4755?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14281329#comment-14281329
 ] 

Divesh Dutta commented on OFBIZ-4755:
-------------------------------------

Jeremy, 

Product search engine doest not take parameters.SEARCH_CATALOG_ID  into 
consideration. Product search engine takes search category into the 
consideration. I have given the example to show how to set up search category. 

After researching, It seems that data of search category for some of the 
catalogs is not present in the Demo data. If  you select  the catalog which 
does not have search category and then you try to search products in that 
catalog, product search engine does not get any products because search 
category is not available, so system will try to find the products in other 
catalogs. 

Lets take an example of product 'pizza' which is associated with DemoCatalog. 
We can search it in this catalog as this particular catalog is having its 
search category. Now if we try to search this product in TestCatalog, we can 
find it there also. The reason behind this is TestCatalog is not having any 
specific search category and system will try to find product in all the 
catalogs and it found it in DemoCatalog.

Here is the example data for creating search category and product in 
TestCatalog :

{code}
<ProductCategory categoryName="Test Default Search" longDescription="Test 
Catalog Search Products - only products in this category will show up in a 
search in test catalog" productCategoryId="TEST_CATALOG_SEARCH" 
productCategoryTypeId="SEARCH_CATEGORY"/>

<ProdCatalogCategory fromDate="2015-01-17 00:00:00.0" 
prodCatalogCategoryTypeId="PCCT_SEARCH" prodCatalogId="TestCatalog" 
productCategoryId="TEST_CATALOG_SEARCH" sequenceNum="3"/>

<ProductCategoryMember fromDate="2015-01-17 00:00:00.0" 
productCategoryId="TEST_CATALOG_SEARCH" productId="PIZZA"/>

{code}

Also expire relation of PIZZA with DemoCatalog in ProductCateogryMember record. 
Now 'PIZZA' will be available only in TestCatalog and not in DemoCatalog. 

So this is more of data specific issue. So all the points mentioned in 
description of this task are not actually bug. If you set up the data 
correctly, every things works as per the expectation. 



> E-commerce search does not always functioning correctly
> -------------------------------------------------------
>
>                 Key: OFBIZ-4755
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-4755
>             Project: OFBiz
>          Issue Type: Bug
>          Components: specialpurpose/ecommerce
>            Reporter: Jeremy Olmstead
>            Priority: Minor
>         Attachments: ecommerceSearch1.patch, ecommerceSearch2.patch
>
>
> There seems to be a number of problems with the way e-commerce search works.  
> I'll just a name a few examples of things I have tried that don't seem to 
> work the way I think they should.  I can delete a catalog from a store and 
> the catalog still shows up and is completely searchable.  I can delete a part 
> from a catalog, then search the catalog and it still shows up, if you click 
> the part from the search results you get a NullPointerException error.  To 
> take things a step further, after deleting the main catalog from the web 
> store, I changed it to View Allow instead of Browse Root, then I even changed 
> every category within the catalog to internal and search still finds parts 
> from that catalog.  Then I created a new catalog and category and put a 
> product within.  From here I can drill down to the part from the newly 
> created catalog, but when I click on the part for details, it still directs 
> me to the other catalog!



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to