Skip to content

Commit 3218e33

Browse files
committed
[MIG] purchase_stock_operating_unit: Migration to 16.0
1 parent a650a68 commit 3218e33

File tree

5 files changed

+22
-18
lines changed

5 files changed

+22
-18
lines changed

purchase_stock_operating_unit/README.rst

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,13 @@ Purchase Stock Operating Unit
1414
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
1515
:alt: License: AGPL-3
1616
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Foperating--unit-lightgray.png?logo=github
17-
:target: https://github.com/OCA/operating-unit/tree/15.0/purchase_stock_operating_unit
17+
:target: https://github.com/OCA/operating-unit/tree/16.0/purchase_stock_operating_unit
1818
:alt: OCA/operating-unit
1919
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
20-
:target: https://translation.odoo-community.org/projects/operating-unit-15-0/operating-unit-15-0-purchase_stock_operating_unit
20+
:target: https://translation.odoo-community.org/projects/operating-unit-16-0/operating-unit-16-0-purchase_stock_operating_unit
2121
:alt: Translate me on Weblate
2222
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
23-
:target: https://runbot.odoo-community.org/runbot/213/15.0
23+
:target: https://runbot.odoo-community.org/runbot/213/16.0
2424
:alt: Try me on Runbot
2525

2626
|badge1| |badge2| |badge3| |badge4| |badge5|
@@ -49,7 +49,7 @@ Bug Tracker
4949
Bugs are tracked on `GitHub Issues <https://github.com/OCA/operating-unit/issues>`_.
5050
In case of trouble, please check there if your issue has already been reported.
5151
If you spotted it first, help us smashing it by providing a detailed and welcomed
52-
`feedback <https://github.com/OCA/operating-unit/issues/new?body=module:%20purchase_stock_operating_unit%0Aversion:%2015.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
52+
`feedback <https://github.com/OCA/operating-unit/issues/new?body=module:%20purchase_stock_operating_unit%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
5353

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

@@ -65,6 +65,7 @@ Contributors
6565
~~~~~~~~~~~~
6666

6767
* Saran Lim. <saranl@ecosoft.co.th>
68+
* Alan Ramos <alan.ramos@jarsa.com>
6869

6970
Maintainers
7071
~~~~~~~~~~~
@@ -87,6 +88,6 @@ Current `maintainer <https://odoo-community.org/page/maintainer-role>`__:
8788

8889
|maintainer-Saran440|
8990

90-
This module is part of the `OCA/operating-unit <https://github.com/OCA/operating-unit/tree/15.0/purchase_stock_operating_unit>`_ project on GitHub.
91+
This module is part of the `OCA/operating-unit <https://github.com/OCA/operating-unit/tree/16.0/purchase_stock_operating_unit>`_ project on GitHub.
9192

9293
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

purchase_stock_operating_unit/__manifest__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
{
55
"name": "Purchase Stock Operating Unit",
66
"summary": "Copies the operating unit of purchase picking to the stock picking",
7-
"version": "15.0.1.0.0",
7+
"version": "16.0.1.0.0",
88
"author": "Ecosoft, Odoo Community Association (OCA)",
99
"website": "https://github.com/OCA/operating-unit",
1010
"category": "Purchase Management",
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
* Saran Lim. <saranl@ecosoft.co.th>
2+
* Alan Ramos <alan.ramos@jarsa.com>

purchase_stock_operating_unit/static/description/index.html

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
44
<head>
55
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6-
<meta name="generator" content="Docutils 0.15.1: http://docutils.sourceforge.net/" />
6+
<meta name="generator" content="Docutils: http://docutils.sourceforge.net/" />
77
<title>Purchase Stock Operating Unit</title>
88
<style type="text/css">
99

@@ -367,7 +367,7 @@ <h1 class="title">Purchase Stock Operating Unit</h1>
367367
!! This file is generated by oca-gen-addon-readme !!
368368
!! changes will be overwritten. !!
369369
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
370-
<p><a class="reference external" 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" 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" href="https://github.com/OCA/operating-unit/tree/15.0/purchase_stock_operating_unit"><img alt="OCA/operating-unit" src="https://img.shields.io/badge/github-OCA%2Foperating--unit-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/operating-unit-15-0/operating-unit-15-0-purchase_stock_operating_unit"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external" href="https://runbot.odoo-community.org/runbot/213/15.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p>
370+
<p><a class="reference external" 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" 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" href="https://github.com/OCA/operating-unit/tree/16.0/purchase_stock_operating_unit"><img alt="OCA/operating-unit" src="https://img.shields.io/badge/github-OCA%2Foperating--unit-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/operating-unit-16-0/operating-unit-16-0-purchase_stock_operating_unit"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external" href="https://runbot.odoo-community.org/runbot/213/16.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p>
371371
<p>This module is used to integrated between Purchase and Stock to send
372372
Operating Unit in the warehouse that has been selected from Deliver To to Stock Picking.</p>
373373
<p><strong>Table of contents</strong></p>
@@ -398,7 +398,7 @@ <h1><a class="toc-backref" href="#id2">Bug Tracker</a></h1>
398398
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/operating-unit/issues">GitHub Issues</a>.
399399
In case of trouble, please check there if your issue has already been reported.
400400
If you spotted it first, help us smashing it by providing a detailed and welcomed
401-
<a class="reference external" href="https://github.com/OCA/operating-unit/issues/new?body=module:%20purchase_stock_operating_unit%0Aversion:%2015.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
401+
<a class="reference external" href="https://github.com/OCA/operating-unit/issues/new?body=module:%20purchase_stock_operating_unit%0Aversion:%2016.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
402402
<p>Do not contact contributors directly about support or help with technical issues.</p>
403403
</div>
404404
<div class="section" id="credits">
@@ -413,6 +413,7 @@ <h2><a class="toc-backref" href="#id4">Authors</a></h2>
413413
<h2><a class="toc-backref" href="#id5">Contributors</a></h2>
414414
<ul class="simple">
415415
<li>Saran Lim. &lt;<a class="reference external" href="mailto:saranl&#64;ecosoft.co.th">saranl&#64;ecosoft.co.th</a>&gt;</li>
416+
<li>Alan Ramos &lt;<a class="reference external" href="mailto:alan.ramos&#64;jarsa.com">alan.ramos&#64;jarsa.com</a>&gt;</li>
416417
</ul>
417418
</div>
418419
<div class="section" id="maintainers">
@@ -424,7 +425,7 @@ <h2><a class="toc-backref" href="#id6">Maintainers</a></h2>
424425
promote its widespread use.</p>
425426
<p>Current <a class="reference external" href="https://odoo-community.org/page/maintainer-role">maintainer</a>:</p>
426427
<p><a class="reference external" href="https://github.com/Saran440"><img alt="Saran440" src="https://github.com/Saran440.png?size=40px" /></a></p>
427-
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/operating-unit/tree/15.0/purchase_stock_operating_unit">OCA/operating-unit</a> project on GitHub.</p>
428+
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/operating-unit/tree/16.0/purchase_stock_operating_unit">OCA/operating-unit</a> project on GitHub.</p>
428429
<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>
429430
</div>
430431
</div>

purchase_stock_operating_unit/tests/test_purchase_stock_operating_unit.py

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,20 +10,21 @@
1010

1111

1212
class TestPurchaseStockOperatingUnit(TestPurchaseOperatingUnit):
13-
def setUp(self):
14-
super().setUp()
15-
self.warehouse_b2b = self.env.ref("stock_operating_unit.stock_warehouse_b2b")
16-
self.picking_type2 = self.env["stock.picking.type"].search(
13+
@classmethod
14+
def setUpClass(cls):
15+
super().setUpClass()
16+
cls.warehouse_b2b = cls.env.ref("stock_operating_unit.stock_warehouse_b2b")
17+
cls.picking_type2 = cls.env["stock.picking.type"].search(
1718
[
1819
("code", "=", "incoming"),
19-
("warehouse_id", "=", self.warehouse_b2b.id),
20+
("warehouse_id", "=", cls.warehouse_b2b.id),
2021
],
2122
limit=1,
2223
)
2324
# Add permission b2b operating unit in user1
24-
self.b2b = self.env.ref("operating_unit.b2b_operating_unit")
25-
user = self.env["res.users"].browse(self.user1_id)
26-
user.operating_unit_ids = [(4, self.b2b.id)]
25+
cls.b2b = cls.env.ref("operating_unit.b2b_operating_unit")
26+
user = cls.env["res.users"].browse(cls.user1_id)
27+
user.operating_unit_ids = [(4, cls.b2b.id)]
2728

2829
def test_01_purchase_stock_operating_unit(self):
2930
self.assertEqual(self.purchase1.state, "purchase")

0 commit comments

Comments
 (0)