|
Shopping Cart Item issue with BigDecimal
---------------------------------------- Key: OFBIZ-4026 URL: https://issues.apache.org/jira/browse/OFBIZ-4026 Project: OFBiz Issue Type: Bug Components: order Affects Versions: Release 09.04, Release Branch 09.04, Release Branch 10.04, jQuery, SVN trunk Environment: All Reporter: Patrick Antivackis In applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartItem.java the setQuantity method should use this.quantity.compareTo(quantity) == 0 instead of this.quantity==quantity like depicted below protected void setQuantity(BigDecimal quantity, LocalDispatcher dispatcher, ShoppingCart cart, boolean triggerExternalOps, boolean resetShipGroup, boolean updateProductPrice, boolean skipInventoryChecks) throws CartItemModifyException { if (this.quantity == quantity) { return; } The issue is really visible when the cart is fully loaded (lot of products) as the return will never occur and the store is configurerd in an autosavecart mode. For example a cart with 48 products will take very long time to process for each additem or modifycart event. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
|
[ https://issues.apache.org/jira/browse/OFBIZ-4026?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Jacques Le Roux closed OFBIZ-4026. ---------------------------------- Resolution: Fixed Fix Version/s: SVN trunk Release Branch 10.04 Release Branch 09.04 Assignee: Jacques Le Roux Thanks Patrick, Your suggested change is in trunk at r1042188, R10.04 r1042190, R9.04 at r1042191. > Shopping Cart Item issue with BigDecimal > ---------------------------------------- > > Key: OFBIZ-4026 > URL: https://issues.apache.org/jira/browse/OFBIZ-4026 > Project: OFBiz > Issue Type: Bug > Components: order > Affects Versions: Release Branch 09.04, Release 09.04, Release Branch 10.04, jQuery, SVN trunk > Environment: All > Reporter: Patrick Antivackis > Assignee: Jacques Le Roux > Fix For: Release Branch 09.04, Release Branch 10.04, SVN trunk > > > In applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartItem.java > the setQuantity method should use this.quantity.compareTo(quantity) == 0 instead of this.quantity==quantity like depicted below > protected void setQuantity(BigDecimal quantity, LocalDispatcher dispatcher, ShoppingCart cart, boolean triggerExternalOps, boolean resetShipGroup, boolean updateProductPrice, boolean skipInventoryChecks) throws CartItemModifyException { > if (this.quantity == quantity) { > return; > } > The issue is really visible when the cart is fully loaded (lot of products) as the return will never occur and the store is configurerd in an autosavecart mode. > For example a cart with 48 products will take very long time to process for each additem or modifycart event. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. |
| Free forum by Nabble | Edit this page |
