Skip to content

Commit

Permalink
Merge PR #1887 into 16.0
Browse files Browse the repository at this point in the history
Signed-off-by HviorForgeFlow
  • Loading branch information
OCA-git-bot committed Jun 5, 2023
2 parents c730290 + e196284 commit 39d444c
Show file tree
Hide file tree
Showing 18 changed files with 1,336 additions and 0 deletions.
100 changes: 100 additions & 0 deletions purchase_merge/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,100 @@
==============
Purchase Merge
==============

.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
:target: https://odoo-community.org/page/development-status
:alt: Beta
.. |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%2Fpurchase--workflow-lightgray.png?logo=github
:target: https://github.com/OCA/purchase-workflow/tree/15.0/purchase_merge
:alt: OCA/purchase-workflow
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/purchase-workflow-15-0/purchase-workflow-15-0-purchase_merge
:alt: Translate me on Weblate
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png
:target: https://runbot.odoo-community.org/runbot/142/15.0
:alt: Try me on Runbot

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

This module adds a wizard to merge purchase order.


A wizard that can be called from tree view of purchase orders.
If merge criteria are validate:
All lines of all PO are "transferred" to the first one and some information like 'origin' and 'partner_ref' are concatenated.
We post a message on the chatter to indicate when the merge operation occurs and what were the PO concerned.
The empty PO are "canceled"

Merge criteria:
* PO are from the same supplier
* PO are in state 'draft'
* PO have the same
#. currency
#. picking type
#. incoterms
#. payment terms
#. fiscal position

**Table of contents**

.. contents::
:local:

Usage
=====

To use this module, you need to:

#. Merge purchase order with required criteria

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

Bugs are tracked on `GitHub Issues <https://github.com/OCA/purchase-workflow/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/purchase-workflow/issues/new?body=module:%20purchase_merge%0Aversion:%2015.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
~~~~~~~

* Camptocamp

Contributors
~~~~~~~~~~~~

* `Camptocamp <https://www.camptocamp.com>`_:

* Thomas Nowicki <thomas.nowicki@camptocamp.com>
* Bojan Anchev <bojan.anchev@camptocamp.com>

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/purchase-workflow <https://github.com/OCA/purchase-workflow/tree/15.0/purchase_merge>`_ 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 purchase_merge/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import wizard
18 changes: 18 additions & 0 deletions purchase_merge/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Copyright 2022 Camptocamp SA
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
{
"name": "Purchase Merge",
"summary": "Wizard to merge purchase with required conditions",
"version": "16.0.1.0.0",
"author": "Camptocamp, Odoo Community Association (OCA)",
"website": "https://github.com/OCA/purchase-workflow",
"license": "AGPL-3",
"category": "Purchase",
"depends": ["purchase_order_approved"],
"data": [
"security/ir.model.access.csv",
"wizard/purchase_merge_views.xml",
],
"external_dependencies": {"python": ["openupgradelib"]},
"installable": True,
}
138 changes: 138 additions & 0 deletions purchase_merge/i18n/purchase_merge.pot
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * purchase_merge
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 15.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: \n"
"Plural-Forms: \n"

#. module: purchase_merge
#: model_terms:ir.ui.view,arch_db:purchase_merge.purchase_merge_automatic_wizard_form
msgid "Automatic Merge Wizard"
msgstr ""

#. module: purchase_merge
#: model_terms:ir.ui.view,arch_db:purchase_merge.purchase_merge_automatic_wizard_form
msgid "Cancel"
msgstr ""

#. module: purchase_merge
#: model:ir.model.fields,field_description:purchase_merge.field_purchase_merge_automatic_wizard__create_uid
msgid "Created by"
msgstr ""

#. module: purchase_merge
#: model:ir.model.fields,field_description:purchase_merge.field_purchase_merge_automatic_wizard__create_date
msgid "Created on"
msgstr ""

#. module: purchase_merge
#: model:ir.model.fields,field_description:purchase_merge.field_purchase_merge_automatic_wizard__dst_purchase_id
msgid "Destination"
msgstr ""

#. module: purchase_merge
#: model:ir.model.fields,field_description:purchase_merge.field_purchase_merge_automatic_wizard__display_name
msgid "Display Name"
msgstr ""

#. module: purchase_merge
#: model:ir.model.fields,field_description:purchase_merge.field_purchase_merge_automatic_wizard__id
msgid "ID"
msgstr ""

#. module: purchase_merge
#: model:ir.model.fields,field_description:purchase_merge.field_purchase_merge_automatic_wizard____last_update
msgid "Last Modified on"
msgstr ""

#. module: purchase_merge
#: model:ir.model.fields,field_description:purchase_merge.field_purchase_merge_automatic_wizard__write_uid
msgid "Last Updated by"
msgstr ""

#. module: purchase_merge
#: model:ir.model.fields,field_description:purchase_merge.field_purchase_merge_automatic_wizard__write_date
msgid "Last Updated on"
msgstr ""

#. module: purchase_merge
#: model_terms:ir.ui.view,arch_db:purchase_merge.purchase_merge_automatic_wizard_form
msgid "Merge Purchase"
msgstr ""

#. module: purchase_merge
#: model:ir.actions.act_window,name:purchase_merge.action_purchase_merge
msgid "Merge Selected Purchase"
msgstr ""

#. module: purchase_merge
#: model:ir.model.fields,field_description:purchase_merge.field_purchase_merge_automatic_wizard__purchase_ids
#: model_terms:ir.ui.view,arch_db:purchase_merge.purchase_merge_automatic_wizard_form
msgid "Purchase"
msgstr ""

#. module: purchase_merge
#: model_terms:ir.ui.view,arch_db:purchase_merge.purchase_merge_automatic_wizard_form
msgid "Selected purchase will be merged together."
msgstr ""

#. module: purchase_merge
#: code:addons/purchase_merge/wizard/purchase_merge.py:0
#, python-format
msgid "This purchase order lines have been merged {} : {}"
msgstr ""

#. module: purchase_merge
#: code:addons/purchase_merge/wizard/purchase_merge.py:0
#, python-format
msgid "You can't merge purchase orders that aren't in draft state like: {}"
msgstr ""

#. module: purchase_merge
#: code:addons/purchase_merge/wizard/purchase_merge.py:0
#, python-format
msgid "You can't merge purchase orders with different currencies: %s"
msgstr ""

#. module: purchase_merge
#: code:addons/purchase_merge/wizard/purchase_merge.py:0
#, python-format
msgid "You can't merge purchase orders with different fiscal positions: %s"
msgstr ""

#. module: purchase_merge
#: code:addons/purchase_merge/wizard/purchase_merge.py:0
#, python-format
msgid "You can't merge purchase orders with different incoterms: %s"
msgstr ""

#. module: purchase_merge
#: code:addons/purchase_merge/wizard/purchase_merge.py:0
#, python-format
msgid "You can't merge purchase orders with different payment terms: %s"
msgstr ""

#. module: purchase_merge
#: code:addons/purchase_merge/wizard/purchase_merge.py:0
#, python-format
msgid "You can't merge purchase orders with different picking types: %s"
msgstr ""

#. module: purchase_merge
#: code:addons/purchase_merge/wizard/purchase_merge.py:0
#, python-format
msgid "You can't merge purchase orders with different suppliers: %s"
msgstr ""

#. module: purchase_merge
#: model:ir.model,name:purchase_merge.model_purchase_merge_automatic_wizard
msgid "purchase.merge.automatic.wizard"
msgstr ""
4 changes: 4 additions & 0 deletions purchase_merge/readme/CONTRIBUTORS.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
* `Camptocamp <https://www.camptocamp.com>`_:

* Thomas Nowicki <thomas.nowicki@camptocamp.com>
* Bojan Anchev <bojan.anchev@camptocamp.com>
18 changes: 18 additions & 0 deletions purchase_merge/readme/DESCRIPTION.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
This module adds a wizard to merge purchase order.


A wizard that can be called from tree view of purchase orders.
If merge criteria are validate:
All lines of all PO are "transferred" to the first one and some information like 'origin' and 'partner_ref' are concatenated.
We post a message on the chatter to indicate when the merge operation occurs and what were the PO concerned.
The empty PO are "canceled"

Merge criteria:
* PO are from the same supplier
* PO are in state 'draft'
* PO have the same
#. currency
#. picking type
#. incoterms
#. payment terms
#. fiscal position
3 changes: 3 additions & 0 deletions purchase_merge/readme/USAGE.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
To use this module, you need to:

#. Merge purchase order with required criteria
2 changes: 2 additions & 0 deletions purchase_merge/security/ir.model.access.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
access_purchase_merge_automatic_wizard_user,access_purchase_merge_automatic_wizard_user,model_purchase_merge_automatic_wizard,purchase.group_purchase_user,1,1,1,1
Binary file added purchase_merge/static/description/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 39d444c

Please sign in to comment.