diff --git a/product_pricelist/README.rst b/product_pricelist/README.rst deleted file mode 100644 index 17839db13..000000000 --- a/product_pricelist/README.rst +++ /dev/null @@ -1,69 +0,0 @@ -.. |company| replace:: ADHOC SA - -.. |company_logo| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-logo.png - :alt: ADHOC SA - :target: https://www.adhoc.com.ar - -.. |icon| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-icon.png - -.. image:: https://img.shields.io/badge/license-AGPL--3-blue.png - :target: https://www.gnu.org/licenses/agpl - :alt: License: AGPL-3 - -================================== -Pricelists information on Products -================================== - -This modules adds a funcionality to show the price for that product for every pricelist. - -Installation -============ - -To install this module, you need to: - - -Configuration -============= - -To configure this module, you need to: - -#. Go to pricelist and select the field "Show in products" to show this pricelist in the products. - - -Usage -===== - -To use this module, you need to: - - -.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas - :alt: Try me on Runbot - :target: http://runbot.adhoc.com.ar/ - -Bug Tracker -=========== - -Bugs are tracked on `GitHub 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. - -Credits -======= - -Images ------- - -* |company| |icon| - -Contributors ------------- - -Maintainer ----------- - -|company_logo| - -This module is maintained by the |company|. - -To contribute to this module, please visit https://www.adhoc.com.ar. diff --git a/product_pricelist/__init__.py b/product_pricelist/__init__.py deleted file mode 100644 index d03377692..000000000 --- a/product_pricelist/__init__.py +++ /dev/null @@ -1,5 +0,0 @@ -############################################################################## -# For copyright and license notices, see __manifest__.py file in module root -# directory -############################################################################## -from . import models diff --git a/product_pricelist/__manifest__.py b/product_pricelist/__manifest__.py deleted file mode 100644 index 1d9cc8b5a..000000000 --- a/product_pricelist/__manifest__.py +++ /dev/null @@ -1,40 +0,0 @@ -############################################################################## -# -# Copyright (C) 2015 ADHOC SA (http://www.adhoc.com.ar) -# All Rights Reserved. -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero General Public License as -# published by the Free Software Foundation, either version 3 of the -# License, or (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## -{ - "name": "Pricelists information on Products", - "version": "19.0.1.0.0", - "category": "Sales & Purchases", - "sequence": 14, - "author": "ADHOC SA", - "website": "www.adhoc.com.ar", - "license": "AGPL-3", - "depends": [ - "sale", - ], - "data": [ - "security/ir.model.access.csv", - "views/product_template_views.xml", - "views/product_pricelist_views.xml", - ], - "demo": [], - "installable": True, - "auto_install": False, - "application": False, -} diff --git a/product_pricelist/i18n/br.po b/product_pricelist/i18n/br.po deleted file mode 100644 index b8e306604..000000000 --- a/product_pricelist/i18n/br.po +++ /dev/null @@ -1,58 +0,0 @@ -# Translation of Odoo Server. -# This file contains the translation of the following modules: -# * product_pricelist -# -# Translators: -# Cesar Lucho Tatad , 2020 -# -msgid "" -msgstr "" -"Project-Id-Version: Odoo Server 13.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-01-11 13:03+0000\n" -"PO-Revision-Date: 2020-08-09 01:20+0000\n" -"Last-Translator: Cesar Lucho Tatad , 2020\n" -"Language-Team: Breton (https://www.transifex.com/adhoc/teams/46451/br/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: \n" -"Language: br\n" -"Plural-Forms: nplurals=5; plural=((n%10 == 1) && (n%100 != 11) && (n%100 !=71) && (n%100 !=91) ? 0 :(n%10 == 2) && (n%100 != 12) && (n%100 !=72) && (n%100 !=92) ? 1 :(n%10 ==3 || n%10==4 || n%10==9) && (n%100 < 10 || n% 100 > 19) && (n%100 < 70 || n%100 > 79) && (n%100 < 90 || n%100 > 99) ? 2 :(n != 0 && n % 1000000 == 0) ? 3 : 4);\n" - -#. module: product_pricelist -#: model:ir.model.fields,help:product_pricelist.field_product_pricelist__show_products -msgid "" -"By selecting it allows you to display the pricelist with the price of that " -"product in the products" -msgstr "" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_pricelist__price -msgid "Price" -msgstr "" - -#. module: product_pricelist -#: model:ir.model.fields,help:product_pricelist.field_product_pricelist__price -msgid "Price for product specified on the context" -msgstr "" - -#. module: product_pricelist -#: model:ir.model,name:product_pricelist.model_product_pricelist -msgid "Pricelist" -msgstr "Rhestr pris" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_product__pricelist_ids -#: model:ir.model.fields,field_description:product_pricelist.field_product_template__pricelist_ids -msgid "Pricelists" -msgstr "" - -#. module: product_pricelist -#: model:ir.model,name:product_pricelist.model_product_template -msgid "Product Template" -msgstr "Templed Cynnyrch" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_pricelist__show_products -msgid "Show in products" -msgstr "" diff --git a/product_pricelist/i18n/es.po b/product_pricelist/i18n/es.po deleted file mode 100644 index 9ab6c50b1..000000000 --- a/product_pricelist/i18n/es.po +++ /dev/null @@ -1,79 +0,0 @@ -# Translation of Odoo Server. -# This file contains the translation of the following modules: -# * product_pricelist -# -# Translators: -# Juan José Scarafía , 2025 -# -msgid "" -msgstr "" -"Project-Id-Version: Odoo Server 19.0+e\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2025-10-16 14:37+0000\n" -"PO-Revision-Date: 2025-10-15 14:22+0000\n" -"Last-Translator: Juan José Scarafía , 2025\n" -"Language-Team: Spanish (https://app.transifex.com/adhoc/teams/46451/es/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: \n" -"Language: es\n" -"Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n" - -#. module: product_pricelist -#: model:ir.model.fields,help:product_pricelist.field_product_pricelist__show_products -msgid "" -"By selecting it allows you to display the pricelist with the price of that " -"product in the products" -msgstr "" -"Con esta opción le permite visualizar en los productos las listas de precios" -" con el precio para ese producto" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_pricelist__display_name -#: model:ir.model.fields,field_description:product_pricelist.field_product_product__display_name -#: model:ir.model.fields,field_description:product_pricelist.field_product_template__display_name -msgid "Display Name" -msgstr "Nombre para mostrar" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_pricelist__id -#: model:ir.model.fields,field_description:product_pricelist.field_product_product__id -#: model:ir.model.fields,field_description:product_pricelist.field_product_template__id -msgid "ID" -msgstr "" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_pricelist__price -msgid "Price" -msgstr "Precio" - -#. module: product_pricelist -#: model:ir.model.fields,help:product_pricelist.field_product_pricelist__price -msgid "Price for product specified on the context" -msgstr "Precio por producto especificado en el contexto" - -#. module: product_pricelist -#: model:ir.model,name:product_pricelist.model_product_pricelist -msgid "Pricelist" -msgstr "Lista de precios" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_product__pricelist_ids -#: model:ir.model.fields,field_description:product_pricelist.field_product_template__pricelist_ids -msgid "Pricelists" -msgstr "Lista de precios" - -#. module: product_pricelist -#: model:ir.model,name:product_pricelist.model_product_template -msgid "Product" -msgstr "Producto" - -#. module: product_pricelist -#: model:ir.model,name:product_pricelist.model_product_product -msgid "Product Variant" -msgstr "Variante de producto" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_pricelist__show_products -msgid "Show in products" -msgstr "Mostrar en productos" diff --git a/product_pricelist/i18n/product_pricelist.pot b/product_pricelist/i18n/product_pricelist.pot deleted file mode 100644 index b483e6e73..000000000 --- a/product_pricelist/i18n/product_pricelist.pot +++ /dev/null @@ -1,73 +0,0 @@ -# Translation of Odoo Server. -# This file contains the translation of the following modules: -# * product_pricelist -# -msgid "" -msgstr "" -"Project-Id-Version: Odoo Server 19.0+e\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2025-11-25 17:03+0000\n" -"PO-Revision-Date: 2025-11-25 17:03+0000\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: product_pricelist -#: model:ir.model.fields,help:product_pricelist.field_product_pricelist__show_products -msgid "" -"By selecting it allows you to display the pricelist with the price of that " -"product in the products" -msgstr "" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_pricelist__display_name -#: model:ir.model.fields,field_description:product_pricelist.field_product_product__display_name -#: model:ir.model.fields,field_description:product_pricelist.field_product_template__display_name -msgid "Display Name" -msgstr "" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_pricelist__id -#: model:ir.model.fields,field_description:product_pricelist.field_product_product__id -#: model:ir.model.fields,field_description:product_pricelist.field_product_template__id -msgid "ID" -msgstr "" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_pricelist__price -msgid "Price" -msgstr "" - -#. module: product_pricelist -#: model:ir.model.fields,help:product_pricelist.field_product_pricelist__price -msgid "Price for product specified on the context" -msgstr "" - -#. module: product_pricelist -#: model:ir.model,name:product_pricelist.model_product_pricelist -msgid "Pricelist" -msgstr "" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_product__pricelist_ids -#: model:ir.model.fields,field_description:product_pricelist.field_product_template__pricelist_ids -msgid "Pricelists" -msgstr "" - -#. module: product_pricelist -#: model:ir.model,name:product_pricelist.model_product_template -msgid "Product" -msgstr "" - -#. module: product_pricelist -#: model:ir.model,name:product_pricelist.model_product_product -msgid "Product Variant" -msgstr "" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_pricelist__show_products -msgid "Show in products" -msgstr "" diff --git a/product_pricelist/i18n/ru.po b/product_pricelist/i18n/ru.po deleted file mode 100644 index 80ed4e141..000000000 --- a/product_pricelist/i18n/ru.po +++ /dev/null @@ -1,58 +0,0 @@ -# Translation of Odoo Server. -# This file contains the translation of the following modules: -# * product_pricelist -# -# Translators: -# Irina Fedulova , 2020 -# -msgid "" -msgstr "" -"Project-Id-Version: Odoo Server 13.0\n" -"Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-01-11 13:03+0000\n" -"PO-Revision-Date: 2020-08-09 01:20+0000\n" -"Last-Translator: Irina Fedulova , 2020\n" -"Language-Team: Russian (https://www.transifex.com/adhoc/teams/46451/ru/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: \n" -"Language: ru\n" -"Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n" - -#. module: product_pricelist -#: model:ir.model.fields,help:product_pricelist.field_product_pricelist__show_products -msgid "" -"By selecting it allows you to display the pricelist with the price of that " -"product in the products" -msgstr "" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_pricelist__price -msgid "Price" -msgstr "Цена" - -#. module: product_pricelist -#: model:ir.model.fields,help:product_pricelist.field_product_pricelist__price -msgid "Price for product specified on the context" -msgstr "" - -#. module: product_pricelist -#: model:ir.model,name:product_pricelist.model_product_pricelist -msgid "Pricelist" -msgstr "Прайс" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_product__pricelist_ids -#: model:ir.model.fields,field_description:product_pricelist.field_product_template__pricelist_ids -msgid "Pricelists" -msgstr "Прайсы" - -#. module: product_pricelist -#: model:ir.model,name:product_pricelist.model_product_template -msgid "Product Template" -msgstr "Шаблон товара" - -#. module: product_pricelist -#: model:ir.model.fields,field_description:product_pricelist.field_product_pricelist__show_products -msgid "Show in products" -msgstr "Показать в товарах" diff --git a/product_pricelist/models/__init__.py b/product_pricelist/models/__init__.py deleted file mode 100644 index bd8e39864..000000000 --- a/product_pricelist/models/__init__.py +++ /dev/null @@ -1,7 +0,0 @@ -############################################################################## -# For copyright and license notices, see __manifest__.py file in module root -# directory -############################################################################## -from . import product_template -from . import product_pricelist -from . import product_product diff --git a/product_pricelist/models/product_pricelist.py b/product_pricelist/models/product_pricelist.py deleted file mode 100644 index f4e01e37b..000000000 --- a/product_pricelist/models/product_pricelist.py +++ /dev/null @@ -1,50 +0,0 @@ -############################################################################## -# For copyright and license notices, see __manifest__.py file in module root -# directory -############################################################################## -from odoo import api, fields, models - - -class ProductPricelist(models.Model): - _inherit = "product.pricelist" - - price = fields.Monetary( - compute="_compute_price", - help="Price for product specified on the context", - ) - show_products = fields.Boolean( - "Show in products", - default=True, - help="By selecting it allows you to display the pricelist " "with the price of that product in the products", - ) - - def _compute_price(self): - self = self.sudo() - active_id = model = False - if "pricelist_product_id" in self.env.context: - active_id = self.env.context.get("pricelist_product_id") - model = "product.product" - elif "pricelist_template_id" in self.env.context: - active_id = self.env.context.get("pricelist_template_id") - model = "product.template" - else: - self.price = 0.0 - - if active_id and model: - product = self.env[model].browse(active_id) - for rec in self: - contextual_price = product.with_context(pricelist=rec.id)._get_contextual_price() - rec.sudo().write({"price": contextual_price}) - - @api.model - def _get_view(self, view_id=None, view_type="form", **options): - arch, view = super()._get_view(view_id, view_type, **options) - if view_type == "form": - if ( - self.env.user.has_group("sales_team.group_sale_salesman") - or self.env.user.has_group("sales_team.group_sale_salesman_all_leads") - ) and not self.env.user.has_group("sales_team.group_sale_manager"): - fields = arch.xpath("//form") - for node in fields: - node.set("edit", "false") - return arch, view diff --git a/product_pricelist/models/product_product.py b/product_pricelist/models/product_product.py deleted file mode 100644 index 4b37e61fc..000000000 --- a/product_pricelist/models/product_product.py +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################## -# For copyright and license notices, see __manifest__.py file in module root -# directory -############################################################################## -from odoo import fields, models - - -class ProductProduct(models.Model): - _inherit = "product.product" - - pricelist_ids = fields.One2many( - "product.pricelist", - compute="_compute_pricelist_ids", - string="Pricelists", - ) - - def _compute_pricelist_ids(self): - for rec in self: - rec.pricelist_ids = rec.pricelist_ids.search([("show_products", "=", True)]) - rec.pricelist_ids.with_context(pricelist_product_id=rec.id)._compute_price() diff --git a/product_pricelist/models/product_template.py b/product_pricelist/models/product_template.py deleted file mode 100644 index b0a2ae873..000000000 --- a/product_pricelist/models/product_template.py +++ /dev/null @@ -1,20 +0,0 @@ -############################################################################## -# For copyright and license notices, see __manifest__.py file in module root -# directory -############################################################################## -from odoo import fields, models - - -class ProductTemplate(models.Model): - _inherit = "product.template" - - pricelist_ids = fields.One2many( - "product.pricelist", - compute="_compute_pricelist_ids", - string="Pricelists", - ) - - def _compute_pricelist_ids(self): - for rec in self: - rec.pricelist_ids = rec.pricelist_ids.search([("show_products", "=", True)]) - rec.pricelist_ids.with_context(pricelist_template_id=rec.id)._compute_price() diff --git a/product_pricelist/security/ir.model.access.csv b/product_pricelist/security/ir.model.access.csv deleted file mode 100644 index 782971fb9..000000000 --- a/product_pricelist/security/ir.model.access.csv +++ /dev/null @@ -1,3 +0,0 @@ -id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink -access_product_pricelist_sale_user,product.pricelist.sale.user,product.model_product_pricelist,sales_team.group_sale_salesman,1,1,0,0 -access_product_pricelist_sale_user_all_leads,product.pricelist.sale.user.all.leads,product.model_product_pricelist,sales_team.group_sale_salesman_all_leads,1,1,0,0 diff --git a/product_pricelist/views/product_pricelist_views.xml b/product_pricelist/views/product_pricelist_views.xml deleted file mode 100644 index 4a58ef901..000000000 --- a/product_pricelist/views/product_pricelist_views.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - product.pricelist.form - product.pricelist - - - - - - - - diff --git a/product_pricelist/views/product_template_views.xml b/product_pricelist/views/product_template_views.xml deleted file mode 100644 index d91473345..000000000 --- a/product_pricelist/views/product_template_views.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - product.template.prices.form - product.template - - - - - - - - - - - - - -