Files
ofbiz-framework/applications/content/widget/cms/advancedsearchprep.bsh
T
Jacopo Cappellato d4d3f3d355 License change from MIT to ASL2.0 for the files of the content component.
Thanks to Scott Gray for the patch (Apache OFBIZ-87).

git-svn-id: https://svn.apache.org/repos/asf/incubator/ofbiz/trunk@422872 13f79535-47bb-0310-9956-ffa450edef68
2006-07-17 21:12:16 +00:00

40 lines
1.6 KiB
Plaintext

/*
* Copyright 2001-2006 The Apache Software Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations
* under the License.
*/
import org.ofbiz.base.util.*;
import org.ofbiz.product.catalog.*;
import org.ofbiz.product.feature.*;
import org.ofbiz.product.product.*;
delegator = request.getAttribute("delegator");
productFeaturesByTypeMap = ParametricSearch.getAllFeaturesByType(delegator, 2000);
productFeatureTypeIdsOrdered = new ArrayList(new TreeSet(productFeaturesByTypeMap.keySet()));
searchOperator = request.getParameter("SEARCH_OPERATOR");
if (!"AND".equals(searchOperator) && !"OR".equals(searchOperator)) {
searchOperator = "OR";
}
searchConstraintStrings = ProductSearchSession.searchGetConstraintStrings(false, session, delegator);
searchSortOrderString = ProductSearchSession.searchGetSortOrderString(false, session);
context.put("productFeaturesByTypeMap", productFeaturesByTypeMap);
context.put("productFeatureTypeIdsOrdered", productFeatureTypeIdsOrdered);
context.put("searchOperator", searchOperator);
context.put("searchConstraintStrings", searchConstraintStrings);
context.put("searchSortOrderString", searchSortOrderString);