-
- Downloads
[FIX] models: "ORDER BY" on many2one fields
When ordering results on a many2one fields, results are ordered by order of the target model. The code was wrongly assuming that this `_order` attribute only contains `_classic_read` fields (that can be directly read from the table in database). Now correctly generate the "ORDER BY" clause using the current table alias. `res.users` can now be sorted by name.
Showing
- openerp/addons/base/res/res_users.py 1 addition, 0 deletionsopenerp/addons/base/res/res_users.py
- openerp/addons/base/tests/test_search.py 15 additions, 0 deletionsopenerp/addons/base/tests/test_search.py
- openerp/models.py 52 additions, 54 deletionsopenerp/models.py
- openerp/osv/fields.py 1 addition, 2 deletionsopenerp/osv/fields.py
Loading
Please register or sign in to comment