Skip to content

Commit

Permalink
[MIG] purchase_sale_stock_inter_company: Migration to 16.0
Browse files Browse the repository at this point in the history
  • Loading branch information
chafique-delli authored and JordiBForgeFlow committed Jun 12, 2023
1 parent 2bb2166 commit d9f3d5d
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 23 deletions.
19 changes: 14 additions & 5 deletions purchase_sale_stock_inter_company/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ Inter Company Module for Purchase to Sale Order with warehouse
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fmulti--company-lightgray.png?logo=github
:target: https://github.com/OCA/multi-company/tree/15.0/purchase_sale_stock_inter_company
:target: https://github.com/OCA/multi-company/tree/16.0/purchase_sale_stock_inter_company
:alt: OCA/multi-company
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/multi-company-15-0/multi-company-15-0-purchase_sale_stock_inter_company
:target: https://translation.odoo-community.org/projects/multi-company-16-0/multi-company-16-0-purchase_sale_stock_inter_company
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
:target: https://runbot.odoo-community.org/runbot/133/15.0
:target: https://runbot.odoo-community.org/runbot/133/16.0
:alt: Try me on Runbot

|badge1| |badge2| |badge3| |badge4| |badge5|
Expand All @@ -30,6 +30,15 @@ This module considers the propagation of the warehouse into the sale orders.
This module is a glue module and is auto installed if `purchase_sale_inter_company`, `sale_stock` and `purchase_stock` modules are installed.
Full purpose description can be found in `purchase_sale_inter_company`.


Configuration
=============

To configure this module, you need to:
#. Go to the menu *Settings > General Settings*.
#. Go to the tab *Companies / Inter Company OCA features*, in the group *Purchase/Sale*, check the option *Sale from purchase*.
#. Then, select the *Warehouse for Sale Orders*, it is the warehouse that will be used to automatically generate the sale order in the other company.

**Table of contents**

.. contents::
Expand All @@ -41,7 +50,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues <https://github.com/OCA/multi-company/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed
`feedback <https://github.com/OCA/multi-company/issues/new?body=module:%20purchase_sale_stock_inter_company%0Aversion:%2015.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
`feedback <https://github.com/OCA/multi-company/issues/new?body=module:%20purchase_sale_stock_inter_company%0Aversion:%2016.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 Down Expand Up @@ -83,6 +92,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/multi-company <https://github.com/OCA/multi-company/tree/15.0/purchase_sale_stock_inter_company>`_ project on GitHub.
This module is part of the `OCA/multi-company <https://github.com/OCA/multi-company/tree/16.0/purchase_sale_stock_inter_company>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
6 changes: 3 additions & 3 deletions purchase_sale_stock_inter_company/models/stock_picking.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ class StockPicking(models.Model):

intercompany_picking_id = fields.Many2one(comodel_name="stock.picking")

def action_done(self):
def _action_done(self):
# Only DropShip pickings
po_picks = self.browse()
for pick in self.filtered(
Expand Down Expand Up @@ -53,5 +53,5 @@ def action_done(self):
)
# Transfer dropship pickings
for po_pick in po_picks.sudo():
po_pick.with_company(po_pick.company_id.id).action_done()
return super(StockPicking, self).action_done()
po_pick.with_company(po_pick.company_id.id)._action_done()
return super()._action_done()
4 changes: 4 additions & 0 deletions purchase_sale_stock_inter_company/readme/CONFIGURE.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
To configure this module, you need to:
#. Go to the menu *Settings > General Settings*.
#. Go to the tab *Companies / Inter Company OCA features*, in the group *Purchase/Sale*, check the option *Sale from purchase*.
#. Then, select the *Warehouse for Sale Orders*, it is the warehouse that will be used to automatically generate the sale order in the other company.
38 changes: 23 additions & 15 deletions purchase_sale_stock_inter_company/static/description/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="generator" content="Docutils 0.15.1: http://docutils.sourceforge.net/" />
<meta name="generator" content="Docutils 0.16.1: http://docutils.sourceforge.net/" />
<title>Inter Company Module for Purchase to Sale Order with warehouse</title>
<style type="text/css">

/*
:Author: David Goodger (goodger@python.org)
:Id: $Id: html4css1.css 7952 2016-07-26 18:15:59Z milde $
:Id: $Id: html4css1.css 7952 2016-07-26 18:16:59Z milde $
:Copyright: This stylesheet has been placed in the public domain.

Default cascading style sheet for the HTML output of Docutils.
Expand Down Expand Up @@ -367,42 +367,50 @@ <h1 class="title">Inter Company Module for Purchase to Sale Order with warehouse
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<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/multi-company/tree/15.0/purchase_sale_stock_inter_company"><img alt="OCA/multi-company" src="https://img.shields.io/badge/github-OCA%2Fmulti--company-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/multi-company-15-0/multi-company-15-0-purchase_sale_stock_inter_company"><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/133/15.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p>
<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/multi-company/tree/16.0/purchase_sale_stock_inter_company"><img alt="OCA/multi-company" src="https://img.shields.io/badge/github-OCA%2Fmulti--company-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/multi-company-16-0/multi-company-16-0-purchase_sale_stock_inter_company"><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/133/16.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p>
<p>This module considers the propagation of the warehouse into the sale orders.</p>
<p>This module is a glue module and is auto installed if <cite>purchase_sale_inter_company</cite>, <cite>sale_stock</cite> and <cite>purchase_stock</cite> modules are installed.
Full purpose description can be found in <cite>purchase_sale_inter_company</cite>.</p>
<p><strong>Table of contents</strong></p>
<div class="contents local topic" id="contents">
<ul class="simple">
<li><a class="reference internal" href="#bug-tracker" id="id1">Bug Tracker</a></li>
<li><a class="reference internal" href="#credits" id="id2">Credits</a><ul>
<li><a class="reference internal" href="#authors" id="id3">Authors</a></li>
<li><a class="reference internal" href="#contributors" id="id4">Contributors</a></li>
<li><a class="reference internal" href="#maintainers" id="id5">Maintainers</a></li>
<li><a class="reference internal" href="#configuration" id="id1">Configuration</a></li>
<li><a class="reference internal" href="#bug-tracker" id="id2">Bug Tracker</a></li>
<li><a class="reference internal" href="#credits" id="id3">Credits</a><ul>
<li><a class="reference internal" href="#authors" id="id4">Authors</a></li>
<li><a class="reference internal" href="#contributors" id="id5">Contributors</a></li>
<li><a class="reference internal" href="#maintainers" id="id6">Maintainers</a></li>
</ul>
</li>
</ul>
</div>
<div class="section" id="configuration">
<h1><a class="toc-backref" href="#id1">Configuration</a></h1>
<p>To configure this module, you need to:</p>
<p>#. Go to the menu <em>Settings > General Settings</em>.</p>
<p>#. Go to the tab <em>Companies / Inter Company OCA features</em>, in the group <em>Purchase/Sale</em>, check the option <em>Sale from purchase</em>.</p>
<p>#. Then, select the <em>Warehouse for Sale Orders</em>, it is the warehouse that will be used to automatically generate the sale order in the other company.</p>
</div>
<div class="section" id="bug-tracker">
<h1><a class="toc-backref" href="#id1">Bug Tracker</a></h1>
<h1><a class="toc-backref" href="#id2">Bug Tracker</a></h1>
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/multi-company/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 smashing it by providing a detailed and welcomed
<a class="reference external" href="https://github.com/OCA/multi-company/issues/new?body=module:%20purchase_sale_stock_inter_company%0Aversion:%2015.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/multi-company/issues/new?body=module:%20purchase_sale_stock_inter_company%0Aversion:%2016.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">
<h1><a class="toc-backref" href="#id2">Credits</a></h1>
<h1><a class="toc-backref" href="#id3">Credits</a></h1>
<div class="section" id="authors">
<h2><a class="toc-backref" href="#id3">Authors</a></h2>
<h2><a class="toc-backref" href="#id4">Authors</a></h2>
<ul class="simple">
<li>Odoo SA</li>
<li>Akretion</li>
<li>Tecnativa</li>
</ul>
</div>
<div class="section" id="contributors">
<h2><a class="toc-backref" href="#id4">Contributors</a></h2>
<h2><a class="toc-backref" href="#id5">Contributors</a></h2>
<ul class="simple">
<li>Adria Gil Sorribes &lt;<a class="reference external" href="mailto:adria.gil&#64;forgeflow.com">adria.gil&#64;forgeflow.com</a>&gt;</li>
<li><cite>Akretion &lt;https://www.akretion.com&gt;</cite>:<ul>
Expand All @@ -421,13 +429,13 @@ <h2><a class="toc-backref" href="#id4">Contributors</a></h2>
</ul>
</div>
<div class="section" id="maintainers">
<h2><a class="toc-backref" href="#id5">Maintainers</a></h2>
<h2><a class="toc-backref" href="#id6">Maintainers</a></h2>
<p>This module is maintained by the OCA.</p>
<a class="reference external image-reference" href="https://odoo-community.org"><img alt="Odoo Community Association" src="https://odoo-community.org/logo.png" /></a>
<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/multi-company/tree/15.0/purchase_sale_stock_inter_company">OCA/multi-company</a> project on GitHub.</p>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/multi-company/tree/16.0/purchase_sale_stock_inter_company">OCA/multi-company</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

0 comments on commit d9f3d5d

Please sign in to comment.