From cf06a25a9ed4fc68e627512843ccccae8eecf06b Mon Sep 17 00:00:00 2001 From: Jean-Sebastien SUZANNE <> Date: Mon, 8 Aug 2011 14:59:20 +0530 Subject: [PATCH 1/2] [FIX] sale : The invoice user_id is not already the same that sale order user_id lp bug: https://launchpad.net/bugs/821486 fixed bzr revid: bde@tinyerp.com-20110808092920-7101p0fxfkteissq --- addons/sale/wizard/sale_line_invoice.py | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/sale/wizard/sale_line_invoice.py b/addons/sale/wizard/sale_line_invoice.py index 8c0383acb02..4e75cc2090d 100644 --- a/addons/sale/wizard/sale_line_invoice.py +++ b/addons/sale/wizard/sale_line_invoice.py @@ -73,6 +73,7 @@ class sale_order_line_make_invoice(osv.osv_memory): 'comment': order.note, 'payment_term': pay_term, 'fiscal_position': order.fiscal_position.id or order.partner_id.property_account_position.id, + 'user_id': order.user_id and order.user_id.id or False, } inv_id = self.pool.get('account.invoice').create(cr, uid, inv) return inv_id From 6e93c87ed8dadf0b510f516dea82dbe48a8230c3 Mon Sep 17 00:00:00 2001 From: "Bharat (OpenERP)" Date: Wed, 10 Aug 2011 17:43:12 +0530 Subject: [PATCH 2/2] [FIX] fixed the same for company_id bzr revid: bde@tinyerp.com-20110810121312-bd1ii12fodgua00r --- addons/sale/wizard/sale_line_invoice.py | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/sale/wizard/sale_line_invoice.py b/addons/sale/wizard/sale_line_invoice.py index 4e75cc2090d..2fa7488a669 100644 --- a/addons/sale/wizard/sale_line_invoice.py +++ b/addons/sale/wizard/sale_line_invoice.py @@ -74,6 +74,7 @@ class sale_order_line_make_invoice(osv.osv_memory): 'payment_term': pay_term, 'fiscal_position': order.fiscal_position.id or order.partner_id.property_account_position.id, 'user_id': order.user_id and order.user_id.id or False, + 'company_id': order.company_id and order.company_id.id or False } inv_id = self.pool.get('account.invoice').create(cr, uid, inv) return inv_id