Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug with Many2one field domain not used for search more for One2many saved records #24742

Open
aek opened this issue May 15, 2018 · 2 comments
Open
Labels
11.0 13.0 14.0 Framework General frontend/backend framework issues

Comments

@aek
Copy link

aek commented May 15, 2018

Impacted versions:
v11.0, haven't tested on others

Steps to reproduce:
Edit a record with a o2m field, be sure that when a new record is add to the o2m field the form record contains a m2o field with a simple domain defined in the xml view

Current behavior:
After save and edit again the o2m record the m2o field in the o2m record form loose it's domain for the search more search popup.
I have found that the issue is at this line
https://github.com/odoo/odoo/blob/11.0/addons/web/static/src/js/fields/relational_fields.js#L465
Where:

domain: this.record.getDomain({fieldName: this.name}),

Should be fixed with:

domain: this.record.getDomain(this.recordParams),

That contains the proper saved viewType and allow to obtain the proper domain from the view type controller fields

Expected behavior:
No issue with the search more search popup for saved items in a m2o field of a o2m record

Video/Screenshot link (optional):
I have prepare a video to show the issue at:
https://streamable.com/mbl5h

@pedrobaeza
Copy link
Collaborator

@ged-odoo can you check this?

@pedrobaeza pedrobaeza added the Framework General frontend/backend framework issues label May 15, 2018
@Yenthe666 Yenthe666 added the 11.0 label May 16, 2018
@netmin
Copy link

netmin commented Apr 15, 2021

This Issue is relevant for versions 13 and 14. To reproduce the problem, you can go to Window Actions/Bank Accounts and change Views then change View Type to Qweb and Search More... for Views

Found all 929 records

Screenshot_2021-04-15 Bank Accounts - Odoo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
11.0 13.0 14.0 Framework General frontend/backend framework issues
Projects
None yet
Development

No branches or pull requests

4 participants