[FIX] account: order on invoice lines based on sequence number (for complains, please...
authorMartin Trigaux <mat@openerp.com>
Tue, 3 Sep 2013 12:59:00 +0000 (14:59 +0200)
committerMartin Trigaux <mat@openerp.com>
Tue, 3 Sep 2013 12:59:00 +0000 (14:59 +0200)
bzr revid: mat@openerp.com-20130903125900-wl1r1etx9pyhe185

addons/account/account_invoice.py
addons/account/account_invoice_view.xml

index 9ff634a..2b8ff77 100644 (file)
@@ -1407,6 +1407,7 @@ class account_invoice_line(osv.osv):
 
     _name = "account.invoice.line"
     _description = "Invoice Line"
+    _order = "invoice_id,sequence"
     _columns = {
         'name': fields.text('Description', required=True),
         'origin': fields.char('Source Document', size=256, help="Reference of the document that produced this invoice."),
index c30297b..ecfd737 100644 (file)
                         <page string="Invoice">
                             <field context="{'partner_id': partner_id, 'price_type': context.get('price_type') or False, 'type': type}" name="invoice_line">
                                 <tree string="Invoice lines" editable="bottom">
+                                    <field name="sequence" widget="handle" />
                                     <field name="product_id"
                                         on_change="product_id_change(product_id, uos_id, quantity, name, parent.type, parent.partner_id, parent.fiscal_position, price_unit, parent.currency_id, context, parent.company_id)"/>
                                     <field name="name"/>