Skip to content

Commit

Permalink
[MIG] sale_invoice_policy: Migration to 18.0
Browse files Browse the repository at this point in the history
  • Loading branch information
marielejeune committed Oct 8, 2024
1 parent 0cf1f60 commit 6ac4533
Show file tree
Hide file tree
Showing 6 changed files with 27 additions and 24 deletions.
33 changes: 17 additions & 16 deletions sale_invoice_policy/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ Sale invoice Policy
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fsale--workflow-lightgray.png?logo=github
:target: https://github.com/OCA/sale-workflow/tree/17.0/sale_invoice_policy
:target: https://github.com/OCA/sale-workflow/tree/18.0/sale_invoice_policy
:alt: OCA/sale-workflow
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/sale-workflow-17-0/sale-workflow-17-0-sale_invoice_policy
:target: https://translation.odoo-community.org/projects/sale-workflow-18-0/sale-workflow-18-0-sale_invoice_policy
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png
:target: https://runboat.odoo-community.org/builds?repo=OCA/sale-workflow&target_branch=17.0
:target: https://runboat.odoo-community.org/builds?repo=OCA/sale-workflow&target_branch=18.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|
Expand All @@ -39,18 +39,18 @@ breaking behaviour (as it is defined from >= v10 on product level).
Usage
=====

- Create Sale Order
- Select Invoicing Policy on Sale Order or let it void
- Either the policy selected on Sale Order would be used, either if not
filled in, the policy would be chosen from product configuration
- Create Sale Order
- Select Invoicing Policy on Sale Order or let it void
- Either the policy selected on Sale Order would be used, either if not
filled in, the policy would be chosen from product configuration

Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/sale-workflow/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
`feedback <https://github.com/OCA/sale-workflow/issues/new?body=module:%20sale_invoice_policy%0Aversion:%2017.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
`feedback <https://github.com/OCA/sale-workflow/issues/new?body=module:%20sale_invoice_policy%0Aversion:%2018.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

Do not contact contributors directly about support or help with technical issues.

Expand All @@ -65,13 +65,14 @@ Authors
Contributors
------------

- Cédric Pigeon <[email protected]>
- François Honoré <[email protected]>
- Denis Roussel <[email protected]>
- Alexei Rivera <[email protected]>
- Luis J. Salvatierra <[email protected]>
- Alejandro Ji Cheung <[email protected]>
- Ioan Galan <[email protected]>
- Cédric Pigeon <[email protected]>
- François Honoré <[email protected]>
- Denis Roussel <[email protected]>
- Alexei Rivera <[email protected]>
- Luis J. Salvatierra <[email protected]>
- Alejandro Ji Cheung <[email protected]>
- Ioan Galan <[email protected]>
- Marie Lejeune <[email protected]>

Maintainers
-----------
Expand All @@ -86,6 +87,6 @@ OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.

This module is part of the `OCA/sale-workflow <https://github.com/OCA/sale-workflow/tree/17.0/sale_invoice_policy>`_ project on GitHub.
This module is part of the `OCA/sale-workflow <https://github.com/OCA/sale-workflow/tree/18.0/sale_invoice_policy>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
2 changes: 1 addition & 1 deletion sale_invoice_policy/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"author": "ACSONE SA/NV, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/sale-workflow",
"category": "Sales Management",
"version": "17.0.1.0.0",
"version": "18.0.1.0.0",
"license": "AGPL-3",
"depends": ["sale_stock"],
"data": [
Expand Down
2 changes: 1 addition & 1 deletion sale_invoice_policy/models/res_config_settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def get_values(self):
def set_values(self):
super().set_values()
ir_default_obj = self.env["ir.default"]
if self.env["res.users"].has_group("base.group_erp_manager"):
if self.env.user.has_group("base.group_erp_manager"):
ir_default_obj = ir_default_obj.sudo()
ir_default_obj.set(
"res.config.settings",
Expand Down
1 change: 1 addition & 0 deletions sale_invoice_policy/readme/CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@
- Luis J. Salvatierra \<<[email protected]>\>
- Alejandro Ji Cheung \<<[email protected]>\>
- Ioan Galan \<<[email protected]>\>
- Marie Lejeune \<<[email protected]>\>
7 changes: 4 additions & 3 deletions sale_invoice_policy/static/description/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,7 @@ <h1 class="title">Sale invoice Policy</h1>
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:e0e9ea9224547864b98ee1983ffb82d814ee04c29de1427ac5ddffc017d58c05
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/licence-AGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/sale-workflow/tree/17.0/sale_invoice_policy"><img alt="OCA/sale-workflow" src="https://img.shields.io/badge/github-OCA%2Fsale--workflow-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/sale-workflow-17-0/sale-workflow-17-0-sale_invoice_policy"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/sale-workflow&amp;target_branch=17.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
<p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/licence-AGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/sale-workflow/tree/18.0/sale_invoice_policy"><img alt="OCA/sale-workflow" src="https://img.shields.io/badge/github-OCA%2Fsale--workflow-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/sale-workflow-18-0/sale-workflow-18-0-sale_invoice_policy"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/sale-workflow&amp;target_branch=18.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
<p>This modules helps to get Invoicing Policy on Sale Order Level without
breaking behaviour (as it is defined from &gt;= v10 on product level).</p>
<p><strong>Table of contents</strong></p>
Expand Down Expand Up @@ -398,7 +398,7 @@ <h1><a class="toc-backref" href="#toc-entry-2">Bug Tracker</a></h1>
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/sale-workflow/issues">GitHub Issues</a>.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us to smash it by providing a detailed and welcomed
<a class="reference external" href="https://github.com/OCA/sale-workflow/issues/new?body=module:%20sale_invoice_policy%0Aversion:%2017.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
<a class="reference external" href="https://github.com/OCA/sale-workflow/issues/new?body=module:%20sale_invoice_policy%0Aversion:%2018.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
<p>Do not contact contributors directly about support or help with technical issues.</p>
</div>
<div class="section" id="credits">
Expand All @@ -419,6 +419,7 @@ <h2><a class="toc-backref" href="#toc-entry-5">Contributors</a></h2>
<li>Luis J. Salvatierra &lt;<a class="reference external" href="mailto:luis.salvatierra&#64;factorlibre.com">luis.salvatierra&#64;factorlibre.com</a>&gt;</li>
<li>Alejandro Ji Cheung &lt;<a class="reference external" href="mailto:alejandro.jicheung&#64;factorlibre.com">alejandro.jicheung&#64;factorlibre.com</a>&gt;</li>
<li>Ioan Galan &lt;<a class="reference external" href="mailto:ioan&#64;studio73.es">ioan&#64;studio73.es</a>&gt;</li>
<li>Marie Lejeune &lt;<a class="reference external" href="mailto:marie.lejeune&#64;acsone.eu">marie.lejeune&#64;acsone.eu</a>&gt;</li>
</ul>
</div>
<div class="section" id="maintainers">
Expand All @@ -428,7 +429,7 @@ <h2><a class="toc-backref" href="#toc-entry-6">Maintainers</a></h2>
<p>OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.</p>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/sale-workflow/tree/17.0/sale_invoice_policy">OCA/sale-workflow</a> project on GitHub.</p>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/sale-workflow/tree/18.0/sale_invoice_policy">OCA/sale-workflow</a> project on GitHub.</p>
<p>You are welcome to contribute. To learn how please visit <a class="reference external" href="https://odoo-community.org/page/Contribute">https://odoo-community.org/page/Contribute</a>.</p>
</div>
</div>
Expand Down
6 changes: 3 additions & 3 deletions sale_invoice_policy/tests/test_sale_invoice_policy.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,15 @@ def setUpClass(cls):
cls.sale_obj = cls.env["sale.order"]
cls.partner = cls.env.ref("base.res_partner_2")
cls.product = cls.product_obj.create(
{"name": "Test", "detailed_type": "consu", "list_price": 20.0}
{"name": "Test", "type": "consu", "list_price": 20.0}
)
cls.product2 = cls.product_obj.create(
{"name": "Test 2", "detailed_type": "consu", "list_price": 45.0}
{"name": "Test 2", "type": "consu", "list_price": 45.0}
)
cls.product3 = cls.product_obj.create(
{
"name": "Test 3 (service)",
"detailed_type": "service",
"type": "service",
"list_price": 850.5,
}
)
Expand Down

0 comments on commit 6ac4533

Please sign in to comment.