-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
[8.0][BUG] web_advanced_search_x2x - Wrong queries in filters #222
Comments
the trick is that you need to submit your search after the first selection. If you add conditions in advances search, the terms will be joined by conjunction. If you apply first, and then add the second condition, you'll get the disjunction. |
Hi @hbrunn , I leaved this without answer and without solving. Let's say conditions in Projects.
I'm looking (in this example) for A OR B OR C = 154
I'm not able to reproduce this, as you said me. I think I was using you trick and that why I said module has a [BUG] In Odoo core: (Go to Projects -> projects) 1 - If you want to make disjunction, A OR B, you have to select first condition (A=is manager), add second codition (B=is member), ... and after all conditions are added click in the button Apply.
2 - If you want to make conjunction, A AND B, you have to select first condition (A=is manager), apply, add second codition (B=is member), aplpy, ...
Adding module OCA web_advanced_search_x2x 3 - So with my search (I would like to filter projects which User (uid) is "manager" OR "member" OR "follower".) and you comment I did:
Could you tell me if I'm missing the trick? Additionaly
|
About your other questions: negative operators on x2many fields in odoo are nearly never treated the way a user would expect, so implementing it on this level is a recipe for frustration. For your use cases, use https://github.com/OCA/web/tree/7.0/web_advanced_filters |
@pedrobaeza @antespi if we want to implement negative operator we must take care on #222 (comment) and maybe discuss with @hbrunn |
Solved in #263 |
Hi @hbrunn ,
This happends with any query but I will show here only one.
I would like to filter projects which User (uid) is "manager" OR "member" or "follower".
In Odoo core we cannot make this search because the follower are res.partner and not res.user then we need to select Follower -> Is in selection and then in res.parter search User -> the user.
When Odoo creates the filter for this you can only select the res.partner and this is the query:
When I create the query using advance search it make this wrong:
But it must create this:
Regards
The text was updated successfully, but these errors were encountered: