-
-
Notifications
You must be signed in to change notification settings - Fork 191
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][MIG] sale_financial_risk #377
Conversation
3c094a8
to
82f088f
Compare
/ocabot migration sale_financial_risk |
82f088f
to
cb77e01
Compare
@carlosdauden changes done |
bb179a5
to
2ad78b5
Compare
@carlosdauden changes done |
Not working test-requirements because the version of module account_financial_risk isn't correctly version |
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.
Code LGTM
e339aeb
to
3db1dfb
Compare
…invoices) Company currency
Currently translated at 7.7% (1 of 13 strings) Translation: credit-control-12.0/credit-control-12.0-sale_financial_risk Translate-URL: https://translation.odoo-community.org/projects/credit-control-12-0/credit-control-12-0-sale_financial_risk/fr/
Currently translated at 7.7% (1 of 13 strings) Translation: credit-control-12.0/credit-control-12.0-sale_financial_risk Translate-URL: https://translation.odoo-community.org/projects/credit-control-12-0/credit-control-12-0-sale_financial_risk/pt_BR/
Currently translated at 46.2% (6 of 13 strings) Translation: credit-control-12.0/credit-control-12.0-sale_financial_risk Translate-URL: https://translation.odoo-community.org/projects/credit-control-12-0/credit-control-12-0-sale_financial_risk/it/
- Include context keys for avoiding mail operations overhead.
Currently translated at 100.0% (21 of 21 strings) Translation: credit-control-16.0/credit-control-16.0-sale_financial_risk Translate-URL: https://translation.odoo-community.org/projects/credit-control-16-0/credit-control-16-0-sale_financial_risk/es/
This issue appeared for multi-company, multi-currency configuration. Whenever risk was calculated for the partner, Sale Order amount was converted to company currency, instead of currency set on the partner. This commit fixes the issue by converting to correct currency (set on the partner).
The test_manual_currency_risk_not_exceeded test that assesses that the manual currency risk has not been passed fails when another module changes the company's currency. The reason for the failure is that if the company currency matches the currency of the sell order it does not convert correctly and in that case it interprets the limit within the same currency. For example, if the company currency is set as EUR and the sales order is placed in EUR, the conversion of the 100€ is not done and therefore exceeds the limit set to 99. To solve this, the company currency is first checked to set a different currency in the order. On the other hand, the tests should be frozen at a certain date to prevent the exchange rate of the exchange currency from going up or down thus avoiding errors when running the test, which should check that it has not been exceeded.
Currently translated at 100.0% (21 of 21 strings) Translation: credit-control-16.0/credit-control-16.0-sale_financial_risk Translate-URL: https://translation.odoo-community.org/projects/credit-control-16-0/credit-control-16-0-sale_financial_risk/nl/
1bd780a
to
3e15923
Compare
This PR has the |
@pedrobaeza good work! |
You have to give thanks to the contributors doing the migration and the review. @sbiosca-s73 please split the pre-commit changes from the migration itself as stated in the migration guide: https://github.com/OCA/maintainer-tools/wiki/Migration-to-version-17.0 |
3e15923
to
0c79ab7
Compare
@pedrobaeza changes done. Thanks! |
/ocabot merge nobump |
This PR looks fantastic, let's merge it! |
Congratulations, your PR was merged at 319bbee. Thanks a lot for contributing to OCA. ❤️ |
Migrate sale_financial_risk module to version 17.0