app/assets/javascripts/rightnow_oms/app/models/cart.js.coffee in rightnow_oms-0.0.4 vs app/assets/javascripts/rightnow_oms/app/models/cart.js.coffee in rightnow_oms-0.1.1

- old
+ new

@@ -18,11 +18,11 @@ round(total, 2) ).property("cartableCount") addCartItem: (item) -> - cartItem = RightnowOms.CartItem.findByName(item.name) + cartItem = RightnowOms.CartItem.findByCartableAndParentId(item.cartable_id, item.cartable_type, item.parent_id) if cartItem? cartItem.increase() unless cartItem.get('parent')? else cartItem = RightnowOms.store.createRecord(RightnowOms.CartItem, item) @@ -44,10 +44,9 @@ decreaseCartItem: (id) -> cartItem = RightnowOms.CartItem.findById(id) cartItem.decrease() - #removeCartItem(id) if cartItem.get('quantity') <= 0 cartItem RightnowOms.Cart.reopenClass isSingleton: true