-
-
Notifications
You must be signed in to change notification settings - Fork 542
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
[17.0][FIX] contract: Malformed expression in the column_invisible attribute. #1195
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM functionally reviewed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, just one not blocking suggestion
0851e31
to
1c0f569
Compare
contract/views/contract_template.xml
Outdated
<p> <strong>#END#</strong>: End date of the invoiced period</p> | ||
<p> <strong | ||
>#INVOICEMONTHNAME#</strong>: Invoice month name of the invoiced period</p> | ||
<p> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Avoid these changes that are not related
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know, but I have an extension in the VS code that pre-formats when I save the changes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well, deactivate it for contributing to OCA, please. Undo this change and I think it's OK.
1c0f569
to
ee8a15b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/ocabot merge patch
Hey, thanks for contributing! Proceeding to merge this for you. |
Congratulations, your PR was merged at 55eac65. Thanks a lot for contributing to OCA. ❤️ |
Good morning, we have identified an error when creating a contract template for suppliers. This error occurs because the following Python expression is being evaluated in a
column_invisible
attribute.parent.contract_type == 'purchase' and not is_auto_renew
According to the Odoo documentation (https://github.com/odoo/documentation/blob/8f1d5d428c2bbb6f420577d02c28d5eef7678096/content/developer/reference/user_interface/view_architectures/generic_attribute_column_invisible.rst), I understand that in these cases, it is not possible to use the values from the tree in the expression. Instead, one must use the values from the parent or a value from the context.
I’m attaching a screenshot of the error.
