-
-
Notifications
You must be signed in to change notification settings - Fork 822
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
[16.0][IMP] purchase_request + purchase_request_type: Misc changes (hide company_id field + set groups to group_id field) #2440
[16.0][IMP] purchase_request + purchase_request_type: Misc changes (hide company_id field + set groups to group_id field) #2440
Conversation
93cd5f4
to
357c542
Compare
357c542
to
87eb11a
Compare
f06a2ea
to
ebdc9fd
Compare
8dfb9af
to
1b0f77f
Compare
1b0f77f
to
aab262b
Compare
Locked by purchase_triple_discount #2579 (comment) Finally the change of the approver has been removed because the focus is changed to Please @carlos-lopez-tecnativa can you review it? |
cc27604
to
af2d130
Compare
681342d
to
d668e22
Compare
purchase_request_tier_validation/data/purchase_request_tier_definition.xml
Outdated
Show resolved
Hide resolved
@@ -74,6 +74,7 @@ def test_compute_purchase_request_type(self): | |||
self.assertEqual(request2.reduce_step, self.type2.reduce_step) | |||
|
|||
def test_purchase_request_type_company_error(self): | |||
self.type1.company_id = self.env.company |
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.
This sounds weird if you need to assign the company explicitly. Isn't this revealing a problem?
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.
That's right, the data tier.definition
has no company_id
defined and this test is intended to check what happens if a tier.definition has company_id defined but, again, if you want this to work differently comment it and I will modify it.
af5c41c
to
71b5ad5
Compare
Add the company_id field always to avoid errors if a domain needs it. TT55213
… when you have Multi-company permission) TT55213
…hived filter TT55213
71b5ad5
to
d95f44a
Compare
…pty in the definition TT55213
…invalidate_cache() to invalidate_model() to avoid warning log Change the method to invalidate_model() to avoid the error: WARNING devel py.warnings: /opt/odoo/auto/addons/purchase_product_packaging_container_deposit/tests/test_purchase_product_packaging_container_deposit.py:277: DeprecationWarning: Deprecated method invalidate_cache(), use invalidate_model(), invalidate_recordset() or env.invalidate_all() instead
Change the Environment.manage() method to avoid the warning log: WARNING odoo py.warnings: /usr/lib/python3.10/contextlib.py:135: DeprecationWarning: Since Odoo 15.0, Environment.manage() is useless.
…o demo data TT55213
d95f44a
to
92e7b88
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.
LGTM
/ocabot merge minor |
Hey, thanks for contributing! Proceeding to merge this for you. |
Congratulations, your PR was merged at fb40987. Thanks a lot for contributing to OCA. ❤️ |
Changes done:
purchase_request
: Hide thecompany_id
field from the lines + add index.purchase_request
: Set groups togroup_id
fieldpurchase_request
: Add company_id field (invisible) to form view.purchase_request_type
: Show request_type field always (not only when you have Multi-company permission.purchase_request_type
: Leave the company_id field empty.purchase_request
: Leave the company_id field empty in the sequence.purchase_request_tier_validation
: Leave the company_id field empty in the definition.purchase_order_uninvoiced_amount
: Avoid warning log.purchase_product_packaging_container_deposit
: Change method toinvalidate_cache()
toinvalidate_model()
to avoid warning log.purchase_request_department
: ChangeEnvironment.manage()
method.purchase_request_tier_validation
: Change tier.definition data to demo data.purchase_request_type
: Change purchase.request.type data to demo data.purchase_request
: Add kanban view.Changes done:
purchase_request_type
: Change toggle_active to web_ribbon + Archived filter.Before

After

@Tecnativa TT51248 TT55213