Hi All,
add all to cart was incorrectly checking for rental items.
Thanx
Fred
Index: applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartHelper.java
===================================================================
--- applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartHelper.java (revision 44)
+++ applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartHelper.java (working copy)
@@ -243,11 +243,16 @@
itemIter = null;
}
+ String orderItemTypeId = null;
if (itemIter != null && itemIter.hasNext()) {
while (itemIter.hasNext()) {
GenericValue orderItem = (GenericValue) itemIter.next();
+ orderItemTypeId = orderItem.getString("orderItemTypeId");
+ // do not store rental items
+ if (orderItemTypeId.equals("RENTAL_ORDER_ITEM"))
+ continue;
// never read: int itemId = -1;
- if (orderItem.get("productId") != null && orderItem.get("quantity") != null && ("RENTAL_ORDER_ITEM").equals(orderItem.getString("orderItemTypeId"))) { // do not store rental items
+ if (orderItem.get("productId") != null && orderItem.get("quantity") != null) {
double amount = 0.00;
if (orderItem.get("selectedAmount") != null) {
amount = orderItem.getDouble("selectedAmount").doubleValue();
_______________________________________________
Dev mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/dev