Skip to content

Commit 73306d9

Browse files
[MIG] sale_customer_rank: Migration to 18.0
1 parent d061fd2 commit 73306d9

File tree

5 files changed

+7
-4
lines changed

5 files changed

+7
-4
lines changed

sale_customer_rank/README.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ Contributors
5858
------------
5959

6060
- Miquel Raïch <[email protected]>
61+
- `Heliconia Solutions Pvt. Ltd. <https://www.heliconia.io>`__
6162

6263
Maintainers
6364
-----------

sale_customer_rank/__init__.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44
from odoo import api, SUPERUSER_ID
55

66

7-
def post_init_hook(cr, registry):
8-
env = api.Environment(cr, SUPERUSER_ID, {})
9-
partners = env["sale.order"].search([]).mapped("partner_id")
7+
def post_init_hook(env):
8+
envs = api.Environment(env.cr, SUPERUSER_ID, {})
9+
partners = envs["sale.order"].search([]).mapped("partner_id")
1010
partners |= partners.mapped("commercial_partner_id")
1111
for partner in partners:
1212
partner._increase_rank("customer_rank", partner.sale_order_count)

sale_customer_rank/__manifest__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
{
55
"name": "Sale Customer Rank",
66
"summary": "Update Customer Rank when creating a Sale Order",
7-
"version": "16.0.1.0.0",
7+
"version": "18.0.1.0.0",
88
"category": "Sales",
99
"website": "https://github.com/OCA/partner-contact",
1010
"author": "ForgeFlow, Odoo Community Association (OCA)",
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
- Miquel Raïch \<<[email protected]>\>
2+
- [Heliconia Solutions Pvt. Ltd.](https://www.heliconia.io)

sale_customer_rank/static/description/index.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -404,6 +404,7 @@ <h2><a class="toc-backref" href="#toc-entry-3">Authors</a></h2>
404404
<h2><a class="toc-backref" href="#toc-entry-4">Contributors</a></h2>
405405
<ul class="simple">
406406
<li>Miquel Raïch &lt;<a class="reference external" href="mailto:miquel.raich&#64;forgeflow.com">miquel.raich&#64;forgeflow.com</a>&gt;</li>
407+
<li><a class="reference external" href="https://www.heliconia.io">Heliconia Solutions Pvt. Ltd.</a></li>
407408
</ul>
408409
</div>
409410
<div class="section" id="maintainers">

0 commit comments

Comments
 (0)