← Back to team overview

openerp-community-reviewer team mailing list archive

[Merge] lp:~scigghia/ocb-addons/7.0_prop_supplier_invoice_number into lp:ocb-addons

 

Andrea Cometa has proposed merging lp:~scigghia/ocb-addons/7.0_prop_supplier_invoice_number into lp:ocb-addons.

Requested reviews:
  OpenERP Community Backports Team (ocb)

For more details, see:
https://code.launchpad.net/~scigghia/ocb-addons/7.0_prop_supplier_invoice_number/+merge/208934

when paying a supplier invoice, with voucher, may be useful to show supplier invoice number instead of ref for supplier invoice, and invoice_number instead of ref or name for out invoice

I think this could be done in action_move_create in account.py done by this mp
-- 
https://code.launchpad.net/~scigghia/ocb-addons/7.0_prop_supplier_invoice_number/+merge/208934
Your team OpenERP Community Backports Team is requested to review the proposed merge of lp:~scigghia/ocb-addons/7.0_prop_supplier_invoice_number into lp:ocb-addons.
=== modified file 'account/account_invoice.py'
--- account/account_invoice.py	2014-02-05 10:03:24 +0000
+++ account/account_invoice.py	2014-03-01 15:21:09 +0000
@@ -1024,7 +1024,9 @@
             line = self.finalize_invoice_move_lines(cr, uid, inv, line)
 
             move = {
-                'ref': inv.reference and inv.reference or inv.name,
+                'ref': (inv.supplier_invoice_number and
+                        inv.supplier_invoice_number or
+                        inv.number or inv.name),
                 'line_id': line,
                 'journal_id': journal_id,
                 'date': date,


Follow ups