Add contact and invoice party

issue8992
review274701003
This commit is contained in:
Cédric Krier
2020-03-28 14:25:57 +01:00
parent 58eb65ea4b
commit be1a9f7bba
+2 -2
View File
@@ -13,6 +13,6 @@ class Sale(metaclass=PoolMeta):
def confirm(cls, sales):
for sale in sales:
if sale.shipment_method == 'order':
sale.party.check_credit_limit(sale.untaxed_amount,
origin=str(sale))
party = sale.invoice_party or sale.party
party.check_credit_limit(sale.untaxed_amount, origin=str(sale))
super(Sale, cls).confirm(sales)