We DO copy the payment term on the supplier invoice (forgot to update some old code)
authorAlexis de Lattre <alexis@via.ecp.fr>
Wed, 11 Jul 2012 13:18:24 +0000 (15:18 +0200)
committerAlexis de Lattre <alexis@via.ecp.fr>
Wed, 11 Jul 2012 13:18:24 +0000 (15:18 +0200)
bzr revid: alexis@via.ecp.fr-20120711131824-xbyrmjvhqdtqbp4h

addons/stock/stock.py

index c27de8b..8436862 100644 (file)
@@ -987,10 +987,10 @@ class stock_picking(osv.osv):
             partner = self.pool.get('res.partner').browse(cr, uid, partner, context=context)
         if inv_type in ('out_invoice', 'out_refund'):
             account_id = partner.property_account_receivable.id
-            payment_term = partner.property_payment_term and partner.property_payment_term.id or False
+            payment_term = partner.property_payment_term.id or False
         else:
             account_id = partner.property_account_payable.id
-            payment_term = False # We don't copy the payment term on supplier inv.
+            payment_term = partner.property_supplier_payment_term.id or False
         comment = self._get_comment_invoice(cr, uid, picking)
         invoice_vals = {
             'name': picking.name,