Browse Source

Bugfixes

pull/39/head
Antonio Espinosa 9 years ago
parent
commit
7a89ae54b9
  1. 4
      pos_pricelist/models/point_of_sale.py

4
pos_pricelist/models/point_of_sale.py

@ -122,7 +122,7 @@ class PosOrder(models.Model):
taxes_to_delete = self.env['pos.order.tax'].search( taxes_to_delete = self.env['pos.order.tax'].search(
[('pos_order', '=', order.id)]) [('pos_order', '=', order.id)])
# Update order taxes list # Update order taxes list
for key, tax in self._tax_list_get().iteritems():
for key, tax in order._tax_list_get().iteritems():
current = taxes_to_delete.filtered( current = taxes_to_delete.filtered(
lambda r: r.tax.id == tax['tax_id']) lambda r: r.tax.id == tax['tax_id'])
if current: if current:
@ -132,7 +132,7 @@ class PosOrder(models.Model):
}) })
taxes_to_delete -= current taxes_to_delete -= current
else: else:
current = self.env['pos.order.tax'].create({
self.env['pos.order.tax'].create({
'pos_order': order.id, 'pos_order': order.id,
'tax': tax['tax_id'], 'tax': tax['tax_id'],
'name': tax['name'], 'name': tax['name'],

Loading…
Cancel
Save