Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
61 commits
Select commit Hold shift + click to select a range
9a0d115
refactore creating a new route, a new procurement action and separate…
florian-dacosta Apr 29, 2015
4c89a4c
add test + use standard mts and mto rules
florian-dacosta May 12, 2015
b64d0b9
Better readme in stock_mts_mto_rule
gabrielo77 Sep 23, 2015
c909da6
OCA Transbot updated translations from Transifex
oca-transbot Oct 5, 2015
47e15c1
[UPD] prefix versions with 8.0
sbidoul Oct 9, 2015
46ed17a
[MIG] Make modules uninstallable
pedrobaeza Oct 14, 2015
68c38b8
Update README.rst
otherjustin Mar 8, 2016
176133a
[FIX] remove en.po that was erroneously created by transbot
sbidoul Aug 15, 2016
55da108
[MIG] Rename manifest files
pedrobaeza Oct 6, 2016
70c7ba7
fix stock_mts_mto procurement check method
florian-dacosta Aug 12, 2015
05b1d5d
OCA Transbot updated translations from Transifex
oca-transbot Oct 26, 2015
f4aef95
Update READMEs
Nov 25, 2015
48b74f0
set pull rule of customer location like split_procurement to allow wh…
JulioSerna Jan 5, 2016
35d21f7
OCA Transbot updated translations from Transifex
oca-transbot Jan 31, 2016
47b02b5
stock move name fix
lk-eska Mar 1, 2016
223de33
Do no run mts mto procurement if it already has been splited into at …
florian-dacosta Mar 10, 2016
6f9931d
stock_mts_mto_rule
JordiBForgeFlow Apr 12, 2016
810af69
[MIG] Migrate stock_mts_mto_rule to v10.0
Oct 9, 2016
c1d76fd
[IMP] stock_mts_mto_rule : Added some unit tests
Oct 17, 2016
24d7080
[FIX] stock_mts_mto_rule : Fixed v10 migration bugs, revealed by new …
Oct 18, 2016
c099ea5
OCA Transbot updated translations from Transifex
oca-transbot Nov 29, 2016
d5ba935
[FIX] stock_mts_mto_rule: Don't fail on renaming WH code
pedrobaeza Mar 31, 2017
71553b4
OCA Transbot updated translations from Transifex
oca-transbot May 2, 2017
8bc20d9
[FIX] _update_routes now handle multiple records (#325)
zaoral Sep 1, 2017
65b1a90
OCA Transbot updated translations from Transifex
oca-transbot Dec 2, 2017
1fc270f
Migrate stock_mts_mto_rule to version 11
florian-dacosta Mar 14, 2018
94e6a9d
[ADD] icon.png
OCA-git-bot Apr 3, 2019
a2cec5f
[MIG] Migrate stock_mts_mto_rule to 12.0
jaredkipe May 6, 2019
057db98
Translated using Weblate (French)
ozydev Jul 2, 2019
54fde68
Translated using Weblate (Chinese (Simplified))
liweijie0812 Oct 10, 2019
5a938ca
[FIX] stock_mts_mto_rule: add mts_rule_id and mto_rule_id on stock ru…
kos94ok-3D Nov 22, 2019
2227a0c
stock_mts_mto_rule 12.0.1.0.1
OCA-git-bot Nov 28, 2019
d4b2732
[IMP] stock_mts_mto_rule: Make tests resilient
pedrobaeza Feb 20, 2020
ef44f85
Translated using Weblate (Slovenian)
sysadminmatmoz Aug 11, 2020
5445ab7
[IMP] stock_mts_mto_rule: black, isort, prettier
deivislaya Sep 18, 2020
ab30bcc
[MIG] stock_mts_mto_rule: Migration to 13.0
deivislaya Sep 19, 2020
af51b36
[UPD] Update stock_mts_mto_rule.pot
oca-travis Nov 12, 2020
cf3543e
Update translation files
oca-transbot Nov 18, 2020
e2298b0
[MIG] stock_mts_mto_rule: Migration to 14.0
Dec 18, 2020
28fa529
[UPD] Update stock_mts_mto_rule.pot
oca-travis Oct 26, 2021
a7d2018
[MIG] stock_mts_mto_rule: Migration to 15.0
alan196 Nov 8, 2021
8e75bb8
[UPD] Update stock_mts_mto_rule.pot
Apr 25, 2022
c55b8e4
[UPD] README.rst
OCA-git-bot Apr 25, 2022
4c496b6
stock_mts_mto_rule 15.0.1.0.1
OCA-git-bot Apr 25, 2022
3be3aaa
[MIG] stock_mts_mto_rule: Migration to 16.0
msteinfeld-sirum Oct 10, 2022
44fe8fa
[UPD] Update stock_mts_mto_rule.pot
Oct 16, 2022
bc2cb8b
[UPD] README.rst
OCA-git-bot Oct 16, 2022
e99c797
Update translation files
weblate Oct 17, 2022
59586c7
[UPD] Update stock_mts_mto_rule.pot
Nov 22, 2022
51a4229
Update translation files
weblate Nov 22, 2022
cdfca0b
[UPD] README.rst
OCA-git-bot Sep 3, 2023
dfb5cd2
[IMP] stock_mts_mto_rule: pre-commit auto fixes
milinsoft Feb 5, 2024
8358761
[17.0][MIG] stock_mts_mto_rule: Migration to 17.0
milinsoft Feb 5, 2024
e84b3a5
[UPD] Update stock_mts_mto_rule.pot
Mar 11, 2024
5e54c81
[BOT] post-merge updates
OCA-git-bot Mar 11, 2024
532d842
Translated using Weblate (Italian)
mymage Mar 12, 2024
1f56005
Translated using Weblate (Spanish)
Ivorra78 Apr 23, 2024
402b684
Translated using Weblate (Italian)
mymage Jul 1, 2024
190941b
[IMP] stock_mts_mto_rule: Fix company_id for demo data
JasminSForgeFlow Oct 28, 2024
aa6a26d
[BOT] post-merge updates
OCA-git-bot Oct 28, 2024
9685e62
[MIG] stock_mts_mto_rule: Migration to 18.0
apik-mgu Sep 11, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
125 changes: 125 additions & 0 deletions stock_mts_mto_rule/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
==================
Stock MTS+MTO Rule
==================

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:b52e877de6856f1b7018678893b3857e90bbd2a626511cc95989c85573b86e1d
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

.. |badge1| image:: https://img.shields.io/badge/maturity-Mature-brightgreen.png
:target: https://odoo-community.org/page/development-status
:alt: Mature
.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html
:alt: License: AGPL-3
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fstock--logistics--warehouse-lightgray.png?logo=github
:target: https://github.com/OCA/stock-logistics-warehouse/tree/18.0/stock_mts_mto_rule
:alt: OCA/stock-logistics-warehouse
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/stock-logistics-warehouse-18-0/stock-logistics-warehouse-18-0-stock_mts_mto_rule
: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/stock-logistics-warehouse&target_branch=18.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|

This module add a Make To Stock + Make to Order Route.

If you choose the make to stock + make to order rule instead of the make
to order route, the creation of a purchase order will depend on the
virtual stock. There are 3 cases :

1. | The virtual stock of the product is 0
| => It will act exactly like the make to order route.

2. | The virtual stock is equal to the quantity ordered
| => It will act exactly like a make to stock route

3. | The virtual stock is more than 0 but less than ordered quantity
| => On part of the products will be taken from stock and a purchase
order
| will be created for the rest. So it will act like both make to
order and make to stock rule.

Example : We have a virtual stock of : 1 product A A sale Order is made
for 3 products A. 2 Procurements will be created :

1. 1 with a make to stock rule and a quantity of 1
2. 1 with a make to order rule and a quantity of 2.

After validation, a purchase order with 2 products will be created.

**Table of contents**

.. contents::
:local:

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

You have to select 'Use MTO+MTS rules' on the company's warehouse form.

Known issues
------------

If you cancel a delivery order and then recreate it from Recreate
Delivery Order button in sale order form, then the stock level at the
time of the Re-Creation won't be taken into account. So if a purchase
order was created when the sale order was first validated, a similar
purchase order will be created during the Re-creation of the delivery
order, even if not needed regarding the actual stock.

Usage
=====

You have to select the mts+mto route on the product form. You should not
select both the mts+mto route and the mto route.

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

Bugs are tracked on `GitHub Issues <https://github.com/OCA/stock-logistics-warehouse/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/stock-logistics-warehouse/issues/new?body=module:%20stock_mts_mto_rule%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.

Credits
=======

Authors
-------

* Akretion

Contributors
------------

- Florian da Costa <florian.dacosta@akretion.com>
- Jared Kipe <jared@hibou.io>
- Alan Ramos <alan.ramos@jarsa.com.mx>
- Aleksander Milinkevich <aleksander@versada.eu>
- Michel Guiheneuf <mgu@apik.cloud>

Maintainers
-----------

This module is maintained by the OCA.

.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org

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/stock-logistics-warehouse <https://github.com/OCA/stock-logistics-warehouse/tree/18.0/stock_mts_mto_rule>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
1 change: 1 addition & 0 deletions stock_mts_mto_rule/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import models
16 changes: 16 additions & 0 deletions stock_mts_mto_rule/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

{
"name": "Stock MTS+MTO Rule",
"summary": "Add a MTS+MTO route",
"version": "18.0.1.0.0",
"development_status": "Mature",
"category": "Warehouse",
"website": "https://github.com/OCA/stock-logistics-warehouse",
"author": "Akretion,Odoo Community Association (OCA)",
"license": "AGPL-3",
"application": False,
"installable": True,
"depends": ["stock"],
"data": ["data/stock_data.xml", "view/pull_rule.xml", "view/warehouse.xml"],
}
12 changes: 12 additions & 0 deletions stock_mts_mto_rule/data/stock_data.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8" ?>
<odoo noupdate="1">
<!--
Procurement rules
-->
<record id="route_mto_mts" model='stock.route'>
<field name="name">Make To Order + Make To Stock</field>
<field name="sequence">5</field>
<field name="product_selectable" eval="True" />
<field name="company_id" />
</record>
</odoo>
105 changes: 105 additions & 0 deletions stock_mts_mto_rule/i18n/cs_CZ.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_mts_mto_rule
#
# Translators:
# Lukáš Spurný <lukasspurny8@gmail.com>, 2018
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 10.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2018-02-27 11:37+0000\n"
"PO-Revision-Date: 2018-02-27 11:37+0000\n"
"Last-Translator: Lukáš Spurný <lukasspurny8@gmail.com>, 2018\n"
"Language-Team: Czech (Czech Republic) (https://www.transifex.com/oca/"
"teams/23907/cs_CZ/)\n"
"Language: cs_CZ\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n"

#. module: stock_mts_mto_rule
#: model:ir.model.fields,field_description:stock_mts_mto_rule.field_stock_rule__action
msgid "Action"
msgstr ""

#. module: stock_mts_mto_rule
#: model:ir.model.fields.selection,name:stock_mts_mto_rule.selection__stock_rule__action__split_procurement
msgid "Choose between MTS and MTO"
msgstr ""

#. module: stock_mts_mto_rule
#: model:ir.model.fields,help:stock_mts_mto_rule.field_stock_warehouse__mto_mts_management
msgid ""
"If this new route is selected on product form view, a purchase order will be "
"created only if the virtual stock is less than 0 else, the product will be "
"taken from stocks"
msgstr ""

#. module: stock_mts_mto_rule
#. odoo-python
#: code:addons/stock_mts_mto_rule/models/stock_rule.py:0
#, python-format
msgid ""
"Inconsistency between the source locations of the mts and mto rules linked "
"to the procurement rule: %s! It should be the same."
msgstr ""

#. module: stock_mts_mto_rule
#: model:ir.model.fields,field_description:stock_mts_mto_rule.field_stock_rule__mto_rule_id
msgid "MTO Rule"
msgstr ""

#. module: stock_mts_mto_rule
#: model:ir.model.fields,field_description:stock_mts_mto_rule.field_stock_warehouse__mts_mto_rule_id
msgid "MTO+MTS rule"
msgstr ""

#. module: stock_mts_mto_rule
#: model:ir.model.fields,field_description:stock_mts_mto_rule.field_stock_rule__mts_rule_id
msgid "MTS Rule"
msgstr ""

#. module: stock_mts_mto_rule
#. odoo-python
#: code:addons/stock_mts_mto_rule/models/stock_warehouse.py:0
#, python-format
msgid "MTS+MTO"
msgstr ""

#. module: stock_mts_mto_rule
#. odoo-python
#: code:addons/stock_mts_mto_rule/models/stock_warehouse.py:0
#: model:stock.route,name:stock_mts_mto_rule.route_mto_mts
#, python-format
msgid "Make To Order + Make To Stock"
msgstr ""

#. module: stock_mts_mto_rule
#. odoo-python
#: code:addons/stock_mts_mto_rule/models/stock_rule.py:0
#, python-format
msgid "No MTS or MTO rule configured on procurement rule: %s!"
msgstr ""

#. module: stock_mts_mto_rule
#: model:ir.model,name:stock_mts_mto_rule.model_stock_rule
msgid "Stock Rule"
msgstr ""

#. module: stock_mts_mto_rule
#: model:ir.model.fields,field_description:stock_mts_mto_rule.field_stock_warehouse__mto_mts_management
msgid "Use MTO+MTS rules"
msgstr ""

#. module: stock_mts_mto_rule
#: model:ir.model,name:stock_mts_mto_rule.model_stock_warehouse
msgid "Warehouse"
msgstr ""

#~ msgid "Procurement Rule"
#~ msgstr "Pravidlo zadávání zakázek"

#~ msgid "Procurement"
#~ msgstr "Zakázka"
123 changes: 123 additions & 0 deletions stock_mts_mto_rule/i18n/de.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_mts_mto_rule
#
# Translators:
# OCA Transbot <transbot@odoo-community.org>, 2017
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 10.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2017-11-30 03:53+0000\n"
"PO-Revision-Date: 2017-11-30 03:53+0000\n"
"Last-Translator: OCA Transbot <transbot@odoo-community.org>, 2017\n"
"Language-Team: German (https://www.transifex.com/oca/teams/23907/de/)\n"
"Language: de\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"

#. module: stock_mts_mto_rule
#: model:ir.model.fields,field_description:stock_mts_mto_rule.field_stock_rule__action
msgid "Action"
msgstr ""

#. module: stock_mts_mto_rule
#: model:ir.model.fields.selection,name:stock_mts_mto_rule.selection__stock_rule__action__split_procurement
msgid "Choose between MTS and MTO"
msgstr "Wähle aus MTO und MTS"

#. module: stock_mts_mto_rule
#: model:ir.model.fields,help:stock_mts_mto_rule.field_stock_warehouse__mto_mts_management
msgid ""
"If this new route is selected on product form view, a purchase order will be "
"created only if the virtual stock is less than 0 else, the product will be "
"taken from stocks"
msgstr ""
"Wird diese neue Route in der Produktdetailsicht gewählt, wird eine "
"Beschaffung nur dann bewirkt, wenn der Planbestand unter 0 fällt, "
"anderenfalls wird das Produkt aus dem Bestand genommen."

#. module: stock_mts_mto_rule
#. odoo-python
#: code:addons/stock_mts_mto_rule/models/stock_rule.py:0
#, python-format
msgid ""
"Inconsistency between the source locations of the mts and mto rules linked "
"to the procurement rule: %s! It should be the same."
msgstr ""

#. module: stock_mts_mto_rule
#: model:ir.model.fields,field_description:stock_mts_mto_rule.field_stock_rule__mto_rule_id
msgid "MTO Rule"
msgstr "MTO-Regel"

#. module: stock_mts_mto_rule
#: model:ir.model.fields,field_description:stock_mts_mto_rule.field_stock_warehouse__mts_mto_rule_id
msgid "MTO+MTS rule"
msgstr "MTO+MTS-Regel"

#. module: stock_mts_mto_rule
#: model:ir.model.fields,field_description:stock_mts_mto_rule.field_stock_rule__mts_rule_id
msgid "MTS Rule"
msgstr "MTS-Regel"

#. module: stock_mts_mto_rule
#. odoo-python
#: code:addons/stock_mts_mto_rule/models/stock_warehouse.py:0
#, python-format
msgid "MTS+MTO"
msgstr "MTS+MTO"

#. module: stock_mts_mto_rule
#. odoo-python
#: code:addons/stock_mts_mto_rule/models/stock_warehouse.py:0
#: model:stock.route,name:stock_mts_mto_rule.route_mto_mts
#, python-format
msgid "Make To Order + Make To Stock"
msgstr "MTO Auftragsfertigung + MTS Lagerfertigung"

#. module: stock_mts_mto_rule
#. odoo-python
#: code:addons/stock_mts_mto_rule/models/stock_rule.py:0
#, python-format
msgid "No MTS or MTO rule configured on procurement rule: %s!"
msgstr ""

#. module: stock_mts_mto_rule
#: model:ir.model,name:stock_mts_mto_rule.model_stock_rule
#, fuzzy
msgid "Stock Rule"
msgstr "MTS-Regel"

#. module: stock_mts_mto_rule
#: model:ir.model.fields,field_description:stock_mts_mto_rule.field_stock_warehouse__mto_mts_management
msgid "Use MTO+MTS rules"
msgstr "Verwende MTO+MTS-Regeln"

#. module: stock_mts_mto_rule
#: model:ir.model,name:stock_mts_mto_rule.model_stock_warehouse
msgid "Warehouse"
msgstr "Lager"

#~ msgid "Can't find MTO Rule on the warehouse"
#~ msgstr "Kann MTO-Regel zum Lager nicht finden"

#~ msgid "Can't find MTS Rule on the warehouse"
#~ msgstr "Kann MTS-Regel zum Lager nicht finden"

#~ msgid "Can't find any generic MTS+MTO route."
#~ msgstr "Kann keine allg. MTO- oder MTS-Route finden"

#~ msgid "Procurement Rule"
#~ msgstr "Beschaffungsregel"

#~ msgid "Mto+Mts Procurement"
#~ msgstr "MTO+MTS-Beschaffung"

#~ msgid "Procurement"
#~ msgstr "Beschaffung"

#~ msgid "Procurements"
#~ msgstr "Beschaffungen"
Loading