forked from OCA/sale-workflow
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ADD] 12.0 Sale Tier Validation module added
- Loading branch information
1 parent
7e155d7
commit 2efbd0b
Showing
11 changed files
with
478 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
.. image:: https://img.shields.io/badge/license-AGPL--3-blue.png | ||
:target: https://www.gnu.org/licenses/agpl | ||
:alt: License: AGPL-3 | ||
|
||
==================== | ||
Sale Tier Validation | ||
==================== | ||
|
||
This module extends the functionality of Sale Orders to support a tier | ||
validation process. | ||
|
||
Installation | ||
============ | ||
|
||
This module depends on ``base_tier_validation``. You can find it at | ||
`OCA/server-ux <https://github.com/OCA/server-ux>`_ | ||
|
||
Configuration | ||
============= | ||
|
||
To configure this module, you need to: | ||
|
||
#. Go to *Settings > Technical > Tier Validations > Tier Definition*. | ||
#. Create as many tiers as you want for Sale Order model. | ||
|
||
Usage | ||
===== | ||
|
||
To use this module, you need to: | ||
|
||
#. Create a Sale Order triggering at least one "Tier Definition". | ||
#. Click on *Request Validation* button. | ||
#. Under the tab *Reviews* have a look to pending reviews and their statuses. | ||
#. Once all reviews are validated click on *Confirm Order*. | ||
|
||
Additional features: | ||
|
||
* You can filter the SOs requesting your review through the filter *Needs my | ||
Review*. | ||
* User with rights to confirm the SO (validate all tiers that would | ||
be generated) can directly do the operation, this is, there is no need for | ||
her/him to request a validation. | ||
|
||
.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas | ||
:alt: Try me on Runbot | ||
:target: https://runbot.odoo-community.org/runbot/142/11.0 | ||
|
||
Bug Tracker | ||
=========== | ||
|
||
Bugs are tracked on `GitHub Issues | ||
<https://github.com/OCA/sale-workflow/issues>`_. In case of trouble, please | ||
check there if your issue has already been reported. If you spotted it first, | ||
help us smash it by providing detailed and welcomed feedback. | ||
|
||
Credits | ||
======= | ||
|
||
Images | ||
------ | ||
|
||
* Odoo Community Association: `Icon <https://odoo-community.org/logo.png>`_. | ||
|
||
Contributors | ||
------------ | ||
|
||
* Mayank Gosai <[email protected]> | ||
|
||
Do not contact contributors directly about support or help with technical issues. | ||
|
||
Maintainer | ||
---------- | ||
|
||
.. image:: https://odoo-community.org/logo.png | ||
:alt: Odoo Community Association | ||
:target: https://odoo-community.org | ||
|
||
This module is maintained by the OCA. | ||
|
||
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. | ||
|
||
To contribute to this module, please visit https://odoo-community.org. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). | ||
|
||
from . import models |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Copyright 2019 Open Source Integrators | ||
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). | ||
{ | ||
"name": "Sale Tier Validation", | ||
"summary": "Extends the functionality of Sale Orders to " | ||
"support a tier validation process.", | ||
"version": "12.0.1.0.0", | ||
"category": "Sale", | ||
"website": "https://github.com/OCA/sale-workflow", | ||
"author": "Open Source Integrators, Odoo Community Association (OCA)", | ||
"license": "AGPL-3", | ||
"application": False, | ||
"installable": True, | ||
"depends": [ | ||
"sale", | ||
"base_tier_validation", | ||
], | ||
"data": [ | ||
"views/sale_order_view.xml", | ||
], | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * sale_tier_validation | ||
# | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 12.0\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"SO-Revision-Date: 2019-05-08 12:03+0000\n" | ||
"Last-Translator: Enric Tobella <[email protected]>\n" | ||
"Language-Team: none\n" | ||
"Language: es\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" | ||
"X-Generator: Weblate 3.5.1\n" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "" | ||
"<i class=\"fa fa-info-circle\"/>This SO needs to be\n" | ||
" validated." | ||
msgstr "" | ||
"<i class=\"fa fa-info-circle\"/>Esta SO debe ser\n" | ||
" validada." | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "<i class=\"fa fa-thumbs-down\"/> Operation has been <b>rejected</b>." | ||
msgstr "<i class=\"fa fa-thumbs-down\"/>La operación ha sido <b>rechazada</b>." | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "<i class=\"fa fa-thumbs-up\"/> Operation has been <b>validated</b>!" | ||
msgstr "<i class=\"fa fa-thumbs-up\"/>La operación ha sido <b>validada</b>!" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.view_sale_order_filter | ||
msgid "My sales to review" | ||
msgstr "Mis Compras a revisar" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.view_sale_order_filter | ||
msgid "Needs my Review" | ||
msgstr "Necesita mi Revisión" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.view_sale_order_filter | ||
msgid "SOs validated and ready to be confirmed" | ||
msgstr "SOs validadas y preparadas para ser confirmadas" | ||
|
||
#. module: sale_tier_validation | ||
#: model:ir.model,name:sale_tier_validation.model_sale_order | ||
msgid "sale Order" | ||
msgstr "Orden de Compra" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "Reject" | ||
msgstr "Rechazar" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "Request Validation" | ||
msgstr "Solicitar Validación" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "Restart Validation" | ||
msgstr "Reiniciar Validación" | ||
|
||
#. module: sale_tier_validation | ||
#: model:ir.model,name:sale_tier_validation.model_tier_definition | ||
#, fuzzy | ||
#| msgid "tier.definition" | ||
msgid "Tier Definition" | ||
msgstr "tier.definition" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "Validate" | ||
msgstr "Validar" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.view_sale_order_filter | ||
msgid "Validated" | ||
msgstr "Validada" | ||
|
||
#~ msgid "Reviews" | ||
#~ msgstr "Revisiones" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * sale_tier_validation | ||
# | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 12.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: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "<i class=\"fa fa-info-circle\"/>This SO needs to be\n" | ||
" validated." | ||
msgstr "" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "<i class=\"fa fa-thumbs-down\"/> Operation has been <b>rejected</b>." | ||
msgstr "" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "<i class=\"fa fa-thumbs-up\"/> Operation has been <b>validated</b>!" | ||
msgstr "" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.view_sale_order_filter | ||
msgid "My Purchases to review" | ||
msgstr "" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.view_sale_order_filter | ||
msgid "Needs my Review" | ||
msgstr "" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.view_sale_order_filter | ||
msgid "SOs validated and ready to be confirmed" | ||
msgstr "" | ||
|
||
#. module: sale_tier_validation | ||
#: model:ir.model,name:sale_tier_validation.model_sale_order | ||
msgid "Sale Order" | ||
msgstr "" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "Reject" | ||
msgstr "" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "Request Validation" | ||
msgstr "" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "Restart Validation" | ||
msgstr "" | ||
|
||
#. module: sale_tier_validation | ||
#: model:ir.model,name:sale_tier_validation.model_tier_definition | ||
msgid "Tier Definition" | ||
msgstr "" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "Validate" | ||
msgstr "" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.view_sale_order_filter | ||
msgid "Validated" | ||
msgstr "" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * sale_tier_validation | ||
# | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 12.0\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"SO-Revision-Date: 2019-09-02 19:23+0000\n" | ||
"Last-Translator: 黎伟杰 <[email protected]>\n" | ||
"Language-Team: none\n" | ||
"Language: zh_CN\n" | ||
"MIME-Version: 1.0\n" | ||
"Content-Type: text/plain; charset=UTF-8\n" | ||
"Content-Transfer-Encoding: \n" | ||
"Plural-Forms: nplurals=1; plural=0;\n" | ||
"X-Generator: Weblate 3.8\n" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "<i class=\"fa fa-info-circle\"/>This SO needs to be\n" | ||
" validated." | ||
msgstr "" | ||
"<i class=\"fa fa-info-circle\"/>这个采购订单需要\n" | ||
" 验证。" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "<i class=\"fa fa-thumbs-down\"/> Operation has been <b>rejected</b>." | ||
msgstr "<i class=\"fa fa-thumbs-down\"/> 操作已被<b>拒绝</b>." | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "<i class=\"fa fa-thumbs-up\"/> Operation has been <b>validated</b>!" | ||
msgstr "<i class=\"fa fa-thumbs-up\"/> 操作已被 <b>验证</b>!" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.view_sale_order_filter | ||
msgid "My Sales to review" | ||
msgstr "查看我的采购" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.view_sale_order_filter | ||
msgid "Needs my Review" | ||
msgstr "需要我审查的" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.view_sale_order_filter | ||
msgid "SOs validated and ready to be confirmed" | ||
msgstr "采购订单已验证,待确认" | ||
|
||
#. module: sale_tier_validation | ||
#: model:ir.model,name:sale_tier_validation.model_sale_order | ||
msgid "Sale Order" | ||
msgstr "采购订单" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "Reject" | ||
msgstr "拒绝" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "Request Validation" | ||
msgstr "请求验证" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "Restart Validation" | ||
msgstr "重新启动验证" | ||
|
||
#. module: sale_tier_validation | ||
#: model:ir.model,name:sale_tier_validation.model_tier_definition | ||
msgid "Tier Definition" | ||
msgstr "层定义" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.sale_order_form | ||
msgid "Validate" | ||
msgstr "验证" | ||
|
||
#. module: sale_tier_validation | ||
#: model_terms:ir.ui.view,arch_db:sale_tier_validation.view_sale_order_filter | ||
msgid "Validated" | ||
msgstr "已验证" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# Copyright 2019 Open Source Integrators | ||
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). | ||
|
||
from . import sale_order | ||
from . import tier_definition |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# Copyright 2019 Open Source Integrators | ||
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). | ||
|
||
from odoo import models | ||
|
||
|
||
class SaleOrder(models.Model): | ||
_name = "sale.order" | ||
_inherit = ['sale.order', 'tier.validation'] | ||
_state_from = ['draft', 'sent', 'to approve'] | ||
_state_to = ['sale', 'approved'] |
Oops, something went wrong.