Skip to content

Commit

Permalink
Merge PR #1844 into 18.0
Browse files Browse the repository at this point in the history
Signed-off-by jbaudoux
  • Loading branch information
OCA-git-bot committed Feb 5, 2025
2 parents 698f7b0 + ad567ee commit 2afdc5e
Show file tree
Hide file tree
Showing 80 changed files with 4,891 additions and 0 deletions.
146 changes: 146 additions & 0 deletions stock_picking_backorder_strategy_cancel/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,146 @@
===============================
Picking backordering strategies
===============================

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:4a572362da71594a9158a62cab98e013721d0d4e9202afd827a966b181f6b9fc
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
.. |badge1| image:: https://img.shields.io/badge/maturity-Production%2FStable-green.png
:target: https://odoo-community.org/page/development-status
:alt: Production/Stable
.. |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--workflow-lightgray.png?logo=github
:target: https://github.com/OCA/stock-logistics-workflow/tree/18.0/stock_picking_backorder_strategy_cancel
:alt: OCA/stock-logistics-workflow
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/stock-logistics-workflow-18-0/stock-logistics-workflow-18-0-stock_picking_backorder_strategy_cancel
: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-workflow&target_branch=18.0
:alt: Try me on Runboat

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

Added new selection in Create Backorder field at Operation Type level.

- Cancel: backorder is cancelled

**Table of contents**

.. contents::
:local:

Installation
============

Your preferred way to install addons will work with Stock Picking
Backorder Strategy.

An easy way to install it with all its dependencies is using pip:

pip install --pre odoo11-addon-stock-picking-backorder-strategy then
restart Odoo, update the addons list in your database, and install the
Stock Picking Backorder Strategy application.

Usage
=====

To configure this module, you need to:

- Define backorder strategy on picking type (Warehouse > Configuration >
Types of Operation)

Changelog
=========

11.0.1.0.0 (2018-12-06)
-----------------------

- [11.0][MIG] stock_picking_backorder_strategy Migration to v11.0 Field
pack_operation_ids removed in v11 Method do_new_transfer changed to
button_validate

10.0.1.0.0 (2018-06-06)
-----------------------

- [10.0][MIG] stock_picking_backorder_strategy Migration to v10.0 Added
a default 'manual' strategy according to changed flow in pickings. Let
the normal process (backorder wizard) occurs

8.0.1.0.0 (2015-08-13)
----------------------

- [ADD] add module stock_backorder_strategy Define on stock_picking_type
how to manage backorder. create: default behavior no_create: no
backorder created cancel: backorder is cancelled

18.0.1.0.0 (2025-02-03)
-----------------------

- [18.0][MIG] The "stock_backorder_strategy" module has been renamed to
"stock_backorder_strategy_cancel" as all original functionalities of
"stock_backorder_strategy" module are now part of Odoo, except for
backorder cancellation, which remains in the module
"stock_backorder_strategy_cancel".

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

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

* ACSONE SA/NV

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

- Laetitia Gangloff <[email protected]>
- Denis Roussel <[email protected]>
- Mayank Gosai <[email protected]>
- Luis Escobar <[email protected]>
- Rujia Liu <[email protected]>

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.

.. |maintainer-rousseldenis| image:: https://github.com/rousseldenis.png?size=40px
:target: https://github.com/rousseldenis
:alt: rousseldenis
.. |maintainer-mgosai| image:: https://github.com/mgosai.png?size=40px
:target: https://github.com/mgosai
:alt: mgosai

Current `maintainers <https://odoo-community.org/page/maintainer-role>`__:

|maintainer-rousseldenis| |maintainer-mgosai|

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

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

{
"name": "Picking backordering strategies",
"version": "18.0.1.0.0",
"development_status": "Production/Stable",
"author": """ACSONE SA/NV,
Odoo Community Association (OCA)""",
"maintainers": ["rousseldenis", "mgosai"],
"category": "Warehouse Management",
"website": "https://github.com/OCA/stock-logistics-workflow",
"depends": ["stock"],
"license": "AGPL-3",
"installable": True,
"application": False,
"pre_init_hook": "pre_init_hook",
}
23 changes: 23 additions & 0 deletions stock_picking_backorder_strategy_cancel/hooks.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
from odoo.tools.sql import column_exists


def pre_init_hook(env):
if not column_exists(env.cr, "stock_picking_type", "backorder_strategy"):
return

env.cr.execute(
"""SELECT id FROM stock_picking_type WHERE backorder_strategy = 'cancel'"""
)
result = env.cr.fetchall()

if not result:
return

picking_ids = [res[0] for res in result]

update_query = """
UPDATE stock_picking_type
SET create_backorder = 'cancel'
WHERE id IN %s
"""
env.cr.execute(update_query, (tuple(picking_ids),))
64 changes: 64 additions & 0 deletions stock_picking_backorder_strategy_cancel/i18n/am.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_picking_backorder_strategy
#
# Translators:
msgid ""
msgstr ""
"Project-Id-Version: stock-logistics-workflow (8.0)\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-09-13 22:02+0000\n"
"PO-Revision-Date: 2015-10-21 16:33+0000\n"
"Last-Translator: <>\n"
"Language-Team: Amharic (http://www.transifex.com/oca/OCA-stock-logistics-"
"workflow-8-0/language/am/)\n"
"Language: am\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_picking_backorder_strategy
#: model:ir.model.fields,field_description:stock_picking_backorder_strategy.field_stock_picking_type__backorder_strategy
msgid "Backorder Strategy"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields.selection,name:stock_picking_backorder_strategy.selection__stock_picking_type__backorder_strategy__cancel
msgid "Cancel"
msgstr "Cancelar"

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields.selection,name:stock_picking_backorder_strategy.selection__stock_picking_type__backorder_strategy__create
msgid "Create"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields,help:stock_picking_backorder_strategy.field_stock_picking_type__backorder_strategy
msgid "Define what to do with backorder"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields.selection,name:stock_picking_backorder_strategy.selection__stock_picking_type__backorder_strategy__manual
msgid "Manual"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields.selection,name:stock_picking_backorder_strategy.selection__stock_picking_type__backorder_strategy__no_create
msgid "No create"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model,name:stock_picking_backorder_strategy.model_stock_picking_type
msgid "Picking Type"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model,name:stock_picking_backorder_strategy.model_stock_move
msgid "Stock Move"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model,name:stock_picking_backorder_strategy.model_stock_picking
msgid "Transfer"
msgstr ""
64 changes: 64 additions & 0 deletions stock_picking_backorder_strategy_cancel/i18n/bg.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_picking_backorder_strategy
#
# Translators:
msgid ""
msgstr ""
"Project-Id-Version: stock-logistics-workflow (8.0)\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-11-18 01:44+0000\n"
"PO-Revision-Date: 2015-10-21 16:33+0000\n"
"Last-Translator: <>\n"
"Language-Team: Bulgarian (http://www.transifex.com/oca/OCA-stock-logistics-"
"workflow-8-0/language/bg/)\n"
"Language: bg\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_picking_backorder_strategy
#: model:ir.model.fields,field_description:stock_picking_backorder_strategy.field_stock_picking_type__backorder_strategy
msgid "Backorder Strategy"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields.selection,name:stock_picking_backorder_strategy.selection__stock_picking_type__backorder_strategy__cancel
msgid "Cancel"
msgstr "Откажи"

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields.selection,name:stock_picking_backorder_strategy.selection__stock_picking_type__backorder_strategy__create
msgid "Create"
msgstr "Създай"

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields,help:stock_picking_backorder_strategy.field_stock_picking_type__backorder_strategy
msgid "Define what to do with backorder"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields.selection,name:stock_picking_backorder_strategy.selection__stock_picking_type__backorder_strategy__manual
msgid "Manual"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields.selection,name:stock_picking_backorder_strategy.selection__stock_picking_type__backorder_strategy__no_create
msgid "No create"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model,name:stock_picking_backorder_strategy.model_stock_picking_type
msgid "Picking Type"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model,name:stock_picking_backorder_strategy.model_stock_move
msgid "Stock Move"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model,name:stock_picking_backorder_strategy.model_stock_picking
msgid "Transfer"
msgstr ""
65 changes: 65 additions & 0 deletions stock_picking_backorder_strategy_cancel/i18n/bs.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * stock_picking_backorder_strategy
#
# Translators:
msgid ""
msgstr ""
"Project-Id-Version: stock-logistics-workflow (8.0)\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-11-18 01:44+0000\n"
"PO-Revision-Date: 2015-10-21 16:33+0000\n"
"Last-Translator: <>\n"
"Language-Team: Bosnian (http://www.transifex.com/oca/OCA-stock-logistics-"
"workflow-8-0/language/bs/)\n"
"Language: bs\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields,field_description:stock_picking_backorder_strategy.field_stock_picking_type__backorder_strategy
msgid "Backorder Strategy"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields.selection,name:stock_picking_backorder_strategy.selection__stock_picking_type__backorder_strategy__cancel
msgid "Cancel"
msgstr "Otkaži"

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields.selection,name:stock_picking_backorder_strategy.selection__stock_picking_type__backorder_strategy__create
msgid "Create"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields,help:stock_picking_backorder_strategy.field_stock_picking_type__backorder_strategy
msgid "Define what to do with backorder"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields.selection,name:stock_picking_backorder_strategy.selection__stock_picking_type__backorder_strategy__manual
msgid "Manual"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model.fields.selection,name:stock_picking_backorder_strategy.selection__stock_picking_type__backorder_strategy__no_create
msgid "No create"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model,name:stock_picking_backorder_strategy.model_stock_picking_type
msgid "Picking Type"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model,name:stock_picking_backorder_strategy.model_stock_move
msgid "Stock Move"
msgstr ""

#. module: stock_picking_backorder_strategy
#: model:ir.model,name:stock_picking_backorder_strategy.model_stock_picking
msgid "Transfer"
msgstr ""
Loading

0 comments on commit 2afdc5e

Please sign in to comment.