|
I'm doing some changes on the searching of products to avoid that one user are in ecommerce site to see products that doesn't belong to the categories/catalogs of the selected Store/Website.
Because in the frontend this is possibile from the advanced search button.
To avoid this I'm trying to change the code that in case one user search products without inserting a category it will use all the categories inside the selected catalog so it will not more possible to see products outside the current catalog.
I have same problem to transfer the context from the advancedsearch.ftl to the method ProductSearchSession.checkDoKeywordOverride into the parameters of the request.
I have try to insert the following row into advancedsearch.ftl but the above method don't receive this parameter.
(in advancedsearch.ftl)
<input type="hidden" name="context" value="${context}">
(in checkDoKeywordOverride method)
Map requestParams = UtilHttp.getParameterMap(request);
Map context = (Map)requestParams.get("context");
context will be null.
Can someone help me to solve this issue ?
Thanks a lot
Marco Risaliti
|