Skip to content
Snippets Groups Projects
Commit e4e1e571 authored by Damien Bouvy's avatar Damien Bouvy
Browse files

[FIX] website_sale_delivery: unset delivery line before update

When removing the last line (apart from the delivery line) from the
cart, it is necessary to remove the delivery line before updating
the cart; otherwise the carrier is contacted with a 0 weight order
and crashes.
parent 3cdcc670
Branches
Tags
No related merge requests found
......@@ -160,6 +160,7 @@ class SaleOrder(orm.Model):
def _cart_update(self, cr, uid, ids, product_id=None, line_id=None, add_qty=0, set_qty=0, context=None, **kwargs):
""" Override to update carrier quotation if quantity changed """
self._delivery_unset(cr, uid, ids, context=context)
values = super(SaleOrder, self)._cart_update(
cr, uid, ids, product_id, line_id, add_qty, set_qty, context, **kwargs)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment