[FIX] web_m2x_options: Fix error in tree views with many2many_tags - #1155
Merged
pedrobaeza merged 1 commit intoJan 16, 2019
Merged
Conversation
Member
|
With this, the tag will be clickable for selecting color? I think this is not the default behavior, and for this module, I would say that it's something not wanted. |
Member
Author
|
This patch only fixes the bug, but the logic beneath remains the same as it was. |
Member
|
Yeah, but I'm asking what is the logic, and if it's what I'm saying, we should inhibit it. |
Member
Author
|
If the widget is supposed to open the record when clicking on the tag, or if it is marked as Otherwise it will. |
The method `_onOpenColorPicker` is defined on `FormFieldMany2ManyTags`, not in `FieldMany2ManyTags`, so it can only be called on its descendants.
Otherwise, clicking on a `many2many_tags` tag when found in a tree view produces an error such as:
TypeError: self._onOpenColorPicker is not a function
http://localhost/web_m2x_options/static/src/js/form.js:354
Rastreo de error:
_onOpenBadge@http://localhost/web_m2x_options/static/src/js/form.js:354:17
proxy/<@http://localhost/web/static/src/js/core/mixins.js:279:20
dispatch@http://localhost/web/static/lib/jquery/jquery.js:4640:50
add/elemData.handle@http://localhost/web/static/lib/jquery/jquery.js:4309:41
yajo
force-pushed
the
11.0-web_m2x_options-fix_m2m_tags_list_view
branch
from
January 16, 2019 11:51
36f2571 to
ddbbe81
Compare
Member
Author
|
I fixed a little bug, this should be ready to merge. |
pedrobaeza
approved these changes
Jan 16, 2019
pedrobaeza
left a comment
Member
There was a problem hiding this comment.
I'm curious why do you need separated var definitions
rafaelbn
approved these changes
Jan 16, 2019
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.
The method
_onOpenColorPickeris defined onFormFieldMany2ManyTags, not inFieldMany2ManyTags, so it can only be called on its descendants.Otherwise, clicking on a
many2many_tagstag when found in a tree view produces an error such as:@Tecnativa