diff --git a/applications/ecommerce/widget/CartScreens.xml b/applications/ecommerce/widget/CartScreens.xml
index 0d00abcf36..a3e7ec80df 100644
--- a/applications/ecommerce/widget/CartScreens.xml
+++ b/applications/ecommerce/widget/CartScreens.xml
@@ -110,7 +110,7 @@ under the License.
-
+
diff --git a/applications/ecommerce/widget/CatalogScreens.xml b/applications/ecommerce/widget/CatalogScreens.xml
index 43aabfdd7e..415762c10f 100644
--- a/applications/ecommerce/widget/CatalogScreens.xml
+++ b/applications/ecommerce/widget/CatalogScreens.xml
@@ -410,7 +410,7 @@ under the License.
-
+
diff --git a/applications/order/webapp/ordermgr/WEB-INF/actions/entry/cart/showPromotionDetails.bsh b/applications/order/webapp/ordermgr/WEB-INF/actions/entry/cart/showPromotionDetails.groovy
similarity index 51%
rename from applications/order/webapp/ordermgr/WEB-INF/actions/entry/cart/showPromotionDetails.bsh
rename to applications/order/webapp/ordermgr/WEB-INF/actions/entry/cart/showPromotionDetails.groovy
index 82de8b660b..8588131108 100644
--- a/applications/order/webapp/ordermgr/WEB-INF/actions/entry/cart/showPromotionDetails.bsh
+++ b/applications/order/webapp/ordermgr/WEB-INF/actions/entry/cart/showPromotionDetails.groovy
@@ -22,67 +22,62 @@ import org.ofbiz.entity.util.EntityUtil;
import org.ofbiz.order.shoppingcart.product.ProductPromoWorker;
productPromoId = request.getParameter("productPromoId");
-productPromo = delegator.findByPrimaryKey("ProductPromo", UtilMisc.toMap("productPromoId", productPromoId));
+productPromo = delegator.findByPrimaryKey("ProductPromo", [productPromoId : productPromoId]);
promoAutoDescription = ProductPromoWorker.makeAutoDescription(productPromo, delegator, locale);
-List productPromoCategoryList = delegator.findByAndCache("ProductPromoCategory", UtilMisc.toMap("productPromoId", productPromoId));
-productPromoCategoryIncludeList = EntityUtil.filterByAnd(productPromoCategoryList, UtilMisc.toMap("productPromoApplEnumId", "PPPA_INCLUDE"));
-productPromoCategoryExcludeList = EntityUtil.filterByAnd(productPromoCategoryList, UtilMisc.toMap("productPromoApplEnumId", "PPPA_EXCLUDE"));
-productPromoCategoryAlwaysList = EntityUtil.filterByAnd(productPromoCategoryList, UtilMisc.toMap("productPromoApplEnumId", "PPPA_ALWAYS"));
+productPromoCategoryList = delegator.findByAndCache("ProductPromoCategory", [productPromoId : productPromoId]);
+productPromoCategoryIncludeList = EntityUtil.filterByAnd(productPromoCategoryList, [productPromoApplEnumId : "PPPA_INCLUDE"]);
+productPromoCategoryExcludeList = EntityUtil.filterByAnd(productPromoCategoryList, [productPromoApplEnumId : "PPPA_EXCLUDE"]);
+productPromoCategoryAlwaysList = EntityUtil.filterByAnd(productPromoCategoryList, [productPromoApplEnumId : "PPPA_ALWAYS"]);
-Set productIdsCond = new HashSet();
-Set productIdsAction = new HashSet();
+productIdsCond = [] as Set;
+productIdsAction = [] as Set;
ProductPromoWorker.makeProductPromoCondActionIdSets(productPromoId, productIdsCond, productIdsAction, delegator, null);
// Debug.logInfo("productIdsCond=" + productIdsCond.toString(), "showProductPromoDetails.bsh");
// Debug.logInfo("productIdsAction=" + productIdsAction.toString(), "showProductPromoDetails.bsh");
-Set productIdSet = new TreeSet(productIdsCond);
-productIdSet.addAll(productIdsAction);
-List productIds = new ArrayList(productIdSet);
+productIds = new TreeSet(productIdsCond);
+productIds.addAll(productIdsAction);
-context.put("productPromoId", productPromoId);
-context.put("productPromo", productPromo);
-context.put("promoAutoDescription", promoAutoDescription);
+context.productPromoId = productPromoId;
+context.productPromo = productPromo;
+context.promoAutoDescription = promoAutoDescription;
-context.put("productPromoCategoryIncludeList", productPromoCategoryIncludeList);
-context.put("productPromoCategoryExcludeList", productPromoCategoryExcludeList);
-context.put("productPromoCategoryAlwaysList", productPromoCategoryAlwaysList);
+context.productPromoCategoryIncludeList = productPromoCategoryIncludeList;
+context.productPromoCategoryExcludeList = productPromoCategoryExcludeList;
+context.productPromoCategoryAlwaysList = productPromoCategoryAlwaysList;
-context.put("productIdsCond", productIdsCond);
-context.put("productIdsAction", productIdsAction);
-context.put("productIds", productIds);
+context.productIdsCond = productIdsCond;
+context.productIdsAction = productIdsAction;
+context.productIds = productIds as List;
-int viewIndex = 0;
-int viewSize = 10;
-int highIndex = 0;
-int lowIndex = 0;
-int listSize = 0;
+viewIndex = 0;
+viewSize = 10;
+highIndex = 0;
+lowIndex = 0;
+listSize = productIds.size();
try {
- viewIndex = Integer.valueOf((String) request.getParameter("VIEW_INDEX")).intValue();
+ viewIndex = Integer.valueOf(request.getParameter("VIEW_INDEX"));
} catch (Exception e) {
viewIndex = 0;
}
try {
- viewSize = Integer.valueOf((String) request.getParameter("VIEW_SIZE")).intValue();
+ viewSize = Integer.valueOf(request.getParameter("VIEW_SIZE"));
} catch (Exception e) {
viewSize = 10;
}
-if (productIds != null) {
- listSize = productIds.size();
-}
-
lowIndex = viewIndex * viewSize;
highIndex = (viewIndex + 1) * viewSize;
if (listSize < highIndex) {
highIndex = listSize;
}
-context.put("viewIndex", viewIndex);
-context.put("viewSize", viewSize);
-context.put("listSize", listSize);
-context.put("lowIndex", lowIndex);
-context.put("highIndex", highIndex);
+context.viewIndex = viewIndex;
+context.viewSize = viewSize;
+context.listSize = listSize;
+context.lowIndex = lowIndex;
+context.highIndex = highIndex;
diff --git a/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/advancedsearchoptions.bsh b/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/advancedsearchoptions.groovy
similarity index 66%
rename from applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/advancedsearchoptions.bsh
rename to applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/advancedsearchoptions.groovy
index f2e2ab2a2c..ea2bd97647 100644
--- a/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/advancedsearchoptions.bsh
+++ b/applications/order/webapp/ordermgr/WEB-INF/actions/entry/catalog/advancedsearchoptions.groovy
@@ -27,17 +27,17 @@ import org.ofbiz.product.catalog.*;
import org.ofbiz.product.feature.*;
import org.ofbiz.product.product.*;
-searchCategoryId = parameters.get("SEARCH_CATEGORY_ID");
-if (searchCategoryId == null || searchCategoryId.length() == 0) {
+searchCategoryId = parameters.SEARCH_CATEGORY_ID;
+if (!searchCategoryId) {
currentCatalogId = CatalogWorker.getCurrentCatalogId(request);
searchCategoryId = CatalogWorker.getCatalogSearchCategoryId(request, currentCatalogId);
}
-searchCategory = delegator.findByPrimaryKey("ProductCategory", UtilMisc.toMap("productCategoryId", searchCategoryId));
+searchCategory = delegator.findByPrimaryKey("ProductCategory", [productCategoryId : searchCategoryId]);
productFeaturesByTypeMap = ParametricSearch.makeCategoryFeatureLists(searchCategoryId, delegator);
-productFeatureTypeIdsOrdered = new ArrayList(new TreeSet(productFeaturesByTypeMap.keySet()));
+productFeatureTypeIdsOrdered = new TreeSet(productFeaturesByTypeMap.keySet()) as List;
-searchOperator = parameters.get("SEARCH_OPERATOR");
+searchOperator = parameters.SEARCH_OPERATOR;
if (!"AND".equals(searchOperator) && !"OR".equals(searchOperator)) {
searchOperator = "OR";
}
@@ -45,10 +45,10 @@ if (!"AND".equals(searchOperator) && !"OR".equals(searchOperator)) {
searchConstraintStrings = ProductSearchSession.searchGetConstraintStrings(false, session, delegator);
searchSortOrderString = ProductSearchSession.searchGetSortOrderString(false, request);
-context.put("searchCategoryId", searchCategoryId);
-context.put("searchCategory", searchCategory);
-context.put("productFeaturesByTypeMap", productFeaturesByTypeMap);
-context.put("productFeatureTypeIdsOrdered", productFeatureTypeIdsOrdered);
-context.put("searchOperator", searchOperator);
-context.put("searchConstraintStrings", searchConstraintStrings);
-context.put("searchSortOrderString", searchSortOrderString);
+context.searchCategoryId = searchCategoryId;
+context.searchCategory = searchCategory;
+context.productFeaturesByTypeMap = productFeaturesByTypeMap;
+context.productFeatureTypeIdsOrdered = productFeatureTypeIdsOrdered;
+context.searchOperator = searchOperator;
+context.searchConstraintStrings = searchConstraintStrings;
+context.searchSortOrderString = searchSortOrderString;
diff --git a/applications/order/widget/ordermgr/OrderEntryCartScreens.xml b/applications/order/widget/ordermgr/OrderEntryCartScreens.xml
index f81bda757a..f5c75bf3e1 100644
--- a/applications/order/widget/ordermgr/OrderEntryCartScreens.xml
+++ b/applications/order/widget/ordermgr/OrderEntryCartScreens.xml
@@ -138,7 +138,7 @@ under the License.
-
+
diff --git a/applications/order/widget/ordermgr/OrderEntryCatalogScreens.xml b/applications/order/widget/ordermgr/OrderEntryCatalogScreens.xml
index bbc18fe528..6a7adab651 100644
--- a/applications/order/widget/ordermgr/OrderEntryCatalogScreens.xml
+++ b/applications/order/widget/ordermgr/OrderEntryCatalogScreens.xml
@@ -216,7 +216,7 @@ under the License.
-
+