Skip to content
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]purchase_last_price_info:Multicompany Permission Error, what type of migration is this #2318

Open
linuxivan opened this issue Jun 26, 2024 · 2 comments
Labels

Comments

@linuxivan
Copy link

Module

purchase_last_price_info

Describe the bug

If you have not multicompany, when you add a new line at a new purchase quotation, gives an permission error about multi-company rule, literaly you cannot make a purchase, this is migrated without review or what?

To Reproduce

Affected versions:

Steps to reproduce the behavior:

  1. New DB with only 1 company
  2. Create a new purchase
  3. Add a line
  4. Change the purchase price
  5. Try to save

Additional context
Tried on runboat

image

@linuxivan linuxivan added the bug label Jun 26, 2024
@patrickt-oforce
Copy link

The error happen because Odoo has changed the multi-company rule in this commit odoo/odoo@a04df5c#diff-268cc255bd6ec91b9684239e0ea25bf0026c67fbfe88afef6bc1fa4b8a63598cR52 a possible way is to restore that rule on module install and in case of migration, restore during migration

@risto42
Copy link

risto42 commented Dec 8, 2024

we're having the same issue. prior to installing oca modules the problem doesn't seem to arise.

manually setting the rule to <field name="domain_force">[('company_id', 'in', company_ids + [False])]</field>
gets over the problem for now (that is, adding + [False])

The real question is, why all of a sudden is company_id == False ? apparently it was absent before...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants