diff --git a/sale_report_salesperson_from_partner/README.rst b/sale_report_salesperson_from_partner/README.rst index a6ae50a0..92111654 100644 --- a/sale_report_salesperson_from_partner/README.rst +++ b/sale_report_salesperson_from_partner/README.rst @@ -74,13 +74,13 @@ 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-pilar-vargas| image:: https://github.com/pilar-vargas.png?size=40px - :target: https://github.com/pilar-vargas - :alt: pilar-vargas +.. |maintainer-pilarvargas-tecnativa| image:: https://github.com/pilarvargas-tecnativa.png?size=40px + :target: https://github.com/pilarvargas-tecnativa + :alt: pilarvargas-tecnativa Current `maintainer `__: -|maintainer-pilar-vargas| +|maintainer-pilarvargas-tecnativa| This module is part of the `OCA/sale-reporting `_ project on GitHub. diff --git a/sale_report_salesperson_from_partner/__manifest__.py b/sale_report_salesperson_from_partner/__manifest__.py index 18c4d256..5bf58b00 100644 --- a/sale_report_salesperson_from_partner/__manifest__.py +++ b/sale_report_salesperson_from_partner/__manifest__.py @@ -2,7 +2,7 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). { "name": "Sale Report Salesperson From Partner", - "version": "15.0.1.0.0", + "version": "16.0.1.0.0", "author": "Tecnativa," "Odoo Community Association (OCA)", "website": "https://github.com/OCA/sale-reporting", "category": "Sales", diff --git a/sale_report_salesperson_from_partner/report/sale_report.py b/sale_report_salesperson_from_partner/report/sale_report.py index d9c88c15..f063aaa5 100644 --- a/sale_report_salesperson_from_partner/report/sale_report.py +++ b/sale_report_salesperson_from_partner/report/sale_report.py @@ -10,11 +10,12 @@ class SaleReport(models.Model): readonly=True, ) - def _group_by_sale(self, groupby=""): - res = super()._group_by_sale(groupby) + def _group_by_sale(self): + res = super()._group_by_sale() res += """,partner.user_id""" return res - def _select_additional_fields(self, fields): - fields["user_from_partner_id"] = ", partner.user_id as user_from_partner_id" - return super()._select_additional_fields(fields) + def _select_additional_fields(self): + res = super()._select_additional_fields() + res["user_from_partner_id"] = "partner.user_id" + return res diff --git a/sale_report_salesperson_from_partner/static/description/index.html b/sale_report_salesperson_from_partner/static/description/index.html index e51bd270..3e6c5436 100644 --- a/sale_report_salesperson_from_partner/static/description/index.html +++ b/sale_report_salesperson_from_partner/static/description/index.html @@ -422,7 +422,7 @@

Maintainers

mission is to support the collaborative development of Odoo features and promote its widespread use.

Current maintainer:

-

pilar-vargas

+

pilarvargas-tecnativa

This module is part of the OCA/sale-reporting project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

diff --git a/sale_report_salesperson_from_partner/tests/test_sale_report_salesperson_from_partner.py b/sale_report_salesperson_from_partner/tests/test_sale_report_salesperson_from_partner.py index c97e3789..7414c98a 100644 --- a/sale_report_salesperson_from_partner/tests/test_sale_report_salesperson_from_partner.py +++ b/sale_report_salesperson_from_partner/tests/test_sale_report_salesperson_from_partner.py @@ -1,23 +1,15 @@ -# Copyright 2022 Tecnativa - Víctor Martínez +# Copyright 2024 Tecnativa - Pilar Vargas # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -from odoo.tests import Form, common, new_test_user +from odoo.tests import Form, new_test_user +from odoo.addons.base.tests.common import BaseCommon -class SaleReportSalespersonFromPartner(common.TransactionCase): + +class SaleReportSalespersonFromPartner(BaseCommon): @classmethod def setUpClass(cls): super().setUpClass() - # Remove this variable in v16 and put instead: - # from odoo.addons.base.tests.common import DISABLED_MAIL_CONTEXT - DISABLED_MAIL_CONTEXT = { - "tracking_disable": True, - "mail_create_nolog": True, - "mail_create_nosubscribe": True, - "mail_notrack": True, - "no_reset_password": True, - } - cls.env = cls.env(context=dict(cls.env.context, **DISABLED_MAIL_CONTEXT)) cls.salesperson = new_test_user( cls.env, login="test_salesperson_from_partner",