search doesn't work for inactive (active=False) many2one
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Odoo Server (MOVED TO GITHUB) |
Confirmed
|
Low
|
OpenERP's Framework R&D |
Bug Description
It proves impossible to search for records that have a value in a many2one field that refers to an inactive record.
This is totally counter_intuitive!!
Example:
I have a list with questions handled by certain users.
The model 'questions' contains this:
_columns = {
.....
'user_id': fields.many2one(
.... },
When I display the list of questions withouth entering search criteria I can see any and all questions wether from active of from
inactive users. However when I want to filter the list to find all questions delegated to a now inactive user, I will not find ANY question by these users, even though they are visible in the full list.
This appears to be the default for any search view.
I can create a work-around by adding the following ridiculous domain to the user field in the search view:
<field name="user_id" select="1" string="User" domain=
I can understand that when entering fields in a form, it is desirable not to show inactive records. That is what inactive means: do not use for new values / table rows. But making it - except for the workaround described above - impossible to find table rows that refer to inactive records is IMHO plain wrong.
Changed in openobject-server: | |
assignee: | nobody → OpenERP's Framework R&D (openerp-dev-framework) |
importance: | Undecided → Low |
status: | New → Confirmed |
summary: |
- search on inactive many2one + search doesn't work for inactive (active=False) many2one |