can't sort by customer in line to invoice

Bug #681438 reported by Aline (OpenERP)
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Low
OpenERP R&D Addons Team 3

Bug Description

line to invoice (from Sales/Invoicing/Lines to Invoice)
      - bug when you sort by Customer (click on column header) -> you can fin traceback here under

reorganise group by : Salesman | Product Order | State

Traceback (most recent call last):
  File "/home/aline/openerp/trunk/server/bin/netsvc.py", line 489, in dispatch
    result = ExportService.getService(service_name).dispatch(method, auth, params)
  File "/home/aline/openerp/trunk/server/bin/service/web_services.py", line 586, in dispatch
    res = fn(db, uid, *params)
  File "/home/aline/openerp/trunk/server/bin/osv/osv.py", line 57, in wrapper
    return f(self, dbname, *args, **kwargs)
  File "/home/aline/openerp/trunk/server/bin/osv/osv.py", line 140, in execute
    res = pool.execute_cr(cr, uid, obj, method, *args, **kw)
  File "/home/aline/openerp/trunk/server/bin/osv/osv.py", line 130, in execute_cr
    return getattr(object, method)(cr, uid, *args, **kw)
  File "/home/aline/openerp/trunk/server/bin/osv/orm.py", line 1834, in search
    return self._search(cr, user, args, offset=offset, limit=limit, order=order, context=context, count=count)
  File "/home/aline/openerp/trunk/server/bin/osv/orm.py", line 4049, in _search
    order_by = self._generate_order_by(order, query)
  File "/home/aline/openerp/trunk/server/bin/osv/orm.py", line 4016, in _generate_order_by
    order_by_clause = self._generate_m2o_order_by(order_field, query)
  File "/home/aline/openerp/trunk/server/bin/osv/orm.py", line 3977, in _generate_m2o_order_by
    assert order_field_column._classic_write or getattr(order_field_column, 'store', False), "Many2one function/related fields must be stored to be used as ordering fields"
AssertionError: Many2one function/related fields must be stored to be used as ordering fields

Related branches

Changed in openobject-addons:
status: New → Confirmed
importance: Undecided → Low
assignee: nobody → OpenERP R&D Addons Team 3 (openerp-dev-addons3)
Changed in openobject-addons:
status: Confirmed → In Progress
Revision history for this message
rvo(Open ERP) (rvo-openerp) wrote :

Hello Aline,

It has been fixed in Addons3 branch.

revision-id: mra@mra-laptop-20101209125230-nrzbkf1ap0h7izf2
revno: 4738
branch-nick: trunk-dev-addons3

Thanks.

Changed in openobject-addons:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.