mass_editing: Fix issue with ir.model.fields implementation of search#638
Merged
pedrobaeza merged 1 commit intoJan 17, 2017
Merged
Conversation
Author
|
I kept digging about the usage of 'model_id' to test a string. In all our codebase I found two usages:
Can I safely switch the 'model_id' for 'model'? I found only two cases where model_id.model is not the same as model: But I wonder if that's an error. |
Member
|
Thank you for taking up this one! This hack in the model's search method allowed for a domain containing a stringified list of ids. It has been obsolete since 4442424, and can safely be removed (i.e. remove the whole file). |
Author
|
Hi @StefanRijnhart, I'll move your suggestion to the PR #638 which is the one standing for this issue. |
Author
|
Opps, I didn't notice this is the PR... |
As commented by @StefanRijnhart, this is no longer needed after 4442424: > This hack in the model's search method allowed for a domain containing a stringified list of ids. It has been obsolete since 4442424, and can safely be removed (i.e. remove the whole file). Closes OCA#638.
mvaled
force-pushed
the
8.0-fix-mass-editing-with-strings
branch
from
January 16, 2017 23:17
6168a48 to
09732a8
Compare
Author
|
Done in 09732a8 |
StefanRijnhart
approved these changes
Jan 17, 2017
StefanRijnhart
left a comment
Member
There was a problem hiding this comment.
Thanks! Tested on runbot.
pedrobaeza
approved these changes
Jan 17, 2017
JayVora-SerpentCS
pushed a commit
to JayVora-SerpentCS/server-tools
that referenced
this pull request
Feb 15, 2017
As commented by @StefanRijnhart, this is no longer needed after 4442424: > This hack in the model's search method allowed for a domain containing a stringified list of ids. It has been obsolete since 4442424, and can safely be removed (i.e. remove the whole file). Closes OCA#638.
SiesslPhillip
pushed a commit
to grueneerde/OCA-server-tools
that referenced
this pull request
Nov 20, 2024
Syncing from upstream OCA/server-tools (10.0)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Without 'mass_editing' installed you can search the 'ir.model.fields' like this:
and it works.
However mass_editing changes the 'search' method and broke this type of query. This commit fixes the 'search' method so that it allows the legacy behavior.
Closes #325 for a new PR.