From adebc341fde3322cd158d78160f5138db42718ae Mon Sep 17 00:00:00 2001 From: "Pedro M. Baeza" Date: Fri, 12 Jun 2020 17:05:10 +0200 Subject: [PATCH 01/25] [ADD] sale_commission_salesman: Sales commissions from salesman This module extends the functionality of `sale_commission` to allow you to auto-populate salesmen as commission agents without setting explicitly them on the customer. **IMPORTANT**: The salesman will be only populated if no other commission agent is set via other method, to assure that there's no overlapping commissions. Configuration ============= * Go to *Contacts*. * Search for the contact linked to the salesman user and open it. * If it's actually linked to a user, you'll see a new check in the *Agent information* page, called "Convert salesman into agent". * Check it for having that salesman automatically populated as agent. You need to assign a commission to that agent as well. Usage ===== To use this module, you need to: * Go to *Sales > Orders > Quotations* and create a new one. * Fill the customer with one with no agents set. * Select a salesman with the mark checked. * Add a line in the quotation, and you will see the salesman populated as commission agent. --- sale_commission_salesman/README.rst | 106 + sale_commission_salesman/__init__.py | 3 + sale_commission_salesman/__manifest__.py | 19 + sale_commission_salesman/i18n/es.po | 56 + .../i18n/sale_commission_salesman.pot | 48 + sale_commission_salesman/models/__init__.py | 5 + .../models/account_invoice.py | 27 + .../models/res_partner.py | 23 + sale_commission_salesman/models/sale_order.py | 27 + sale_commission_salesman/readme/CONFIGURE.rst | 6 + .../readme/CONTRIBUTORS.rst | 3 + sale_commission_salesman/readme/CREDITS.rst | 1 + .../readme/DESCRIPTION.rst | 6 + sale_commission_salesman/readme/USAGE.rst | 7 + .../static/description/icon.png | Bin 0 -> 17671 bytes .../static/description/icon.svg | 2819 +++++++++++++++++ .../static/description/index.html | 457 +++ sale_commission_salesman/tests/__init__.py | 3 + .../tests/test_sale_commission_salesman.py | 108 + .../views/res_partner_views.xml | 17 + 20 files changed, 3741 insertions(+) create mode 100644 sale_commission_salesman/README.rst create mode 100644 sale_commission_salesman/__init__.py create mode 100644 sale_commission_salesman/__manifest__.py create mode 100644 sale_commission_salesman/i18n/es.po create mode 100644 sale_commission_salesman/i18n/sale_commission_salesman.pot create mode 100644 sale_commission_salesman/models/__init__.py create mode 100644 sale_commission_salesman/models/account_invoice.py create mode 100644 sale_commission_salesman/models/res_partner.py create mode 100644 sale_commission_salesman/models/sale_order.py create mode 100644 sale_commission_salesman/readme/CONFIGURE.rst create mode 100644 sale_commission_salesman/readme/CONTRIBUTORS.rst create mode 100644 sale_commission_salesman/readme/CREDITS.rst create mode 100644 sale_commission_salesman/readme/DESCRIPTION.rst create mode 100644 sale_commission_salesman/readme/USAGE.rst create mode 100644 sale_commission_salesman/static/description/icon.png create mode 100644 sale_commission_salesman/static/description/icon.svg create mode 100644 sale_commission_salesman/static/description/index.html create mode 100644 sale_commission_salesman/tests/__init__.py create mode 100644 sale_commission_salesman/tests/test_sale_commission_salesman.py create mode 100644 sale_commission_salesman/views/res_partner_views.xml diff --git a/sale_commission_salesman/README.rst b/sale_commission_salesman/README.rst new file mode 100644 index 000000000..bb2baa494 --- /dev/null +++ b/sale_commission_salesman/README.rst @@ -0,0 +1,106 @@ +=============================== +Sales commissions from salesman +=============================== + +.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! 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%2Fcommission-lightgray.png?logo=github + :target: https://github.com/OCA/commission/tree/11.0/sale_commission_salesman + :alt: OCA/commission +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/commission-11-0/commission-11-0-sale_commission_salesman + :alt: Translate me on Weblate +.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png + :target: https://runbot.odoo-community.org/runbot/165/11.0 + :alt: Try me on Runbot + +|badge1| |badge2| |badge3| |badge4| |badge5| + +This module extends the functionality of `sale_commission` to allow you to +auto-populate salesmen as commission agents without setting explicitly them +on the customer. + +**IMPORTANT**: The salesman will be only populated if no other commission agent +is set via other method, to assure that there's no overlapping commissions. + +**Table of contents** + +.. contents:: + :local: + +Configuration +============= + +#. Go to *Contacts*. +#. Search for the contact linked to the salesman user and open it. +#. If it's actually linked to a user, you'll see a new check in the + *Agent information* page, called "Convert salesman into agent". +#. Check it for having that salesman automatically populated as agent. You + need to assign a commission to that agent as well. + +Usage +===== + +To use this module, you need to: + +#. Go to *Sales > Orders > Quotations* and create a new one. +#. Fill the customer with one with no agents set. +#. Select a salesman with the mark checked. +#. Add a line in the quotation, and you will see the salesman populated as + commission agent. + +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 `_. + +Do not contact contributors directly about support or help with technical issues. + +Credits +======= + +Authors +~~~~~~~ + +* Tecnativa + +Contributors +~~~~~~~~~~~~ + +* `Tecnativa `__: + + * Pedro M. Baeza + +Other credits +~~~~~~~~~~~~~ + +- Part of the icon made from Icon Fonts is licensed by CC BY 3.0 + +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/commission `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/sale_commission_salesman/__init__.py b/sale_commission_salesman/__init__.py new file mode 100644 index 000000000..31660d6a9 --- /dev/null +++ b/sale_commission_salesman/__init__.py @@ -0,0 +1,3 @@ +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from . import models diff --git a/sale_commission_salesman/__manifest__.py b/sale_commission_salesman/__manifest__.py new file mode 100644 index 000000000..8f5bb7ddf --- /dev/null +++ b/sale_commission_salesman/__manifest__.py @@ -0,0 +1,19 @@ +# Copyright 2020 Tecnativa - Pedro M. Baeza +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +{ + "name": "Sales commissions from salesman", + "version": "11.0.1.0.0", + "author": "Tecnativa, " + "Odoo Community Association (OCA)", + "category": "Sales", + "website": "https://github.com/OCA/commission", + "license": "AGPL-3", + "depends": [ + "sale_commission", + ], + "data": [ + "views/res_partner_views.xml", + ], + "installable": True, +} diff --git a/sale_commission_salesman/i18n/es.po b/sale_commission_salesman/i18n/es.po new file mode 100644 index 000000000..a56c54aad --- /dev/null +++ b/sale_commission_salesman/i18n/es.po @@ -0,0 +1,56 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * sale_commission_salesman +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 11.0\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: 2020-06-12 14:51+0000\n" +"PO-Revision-Date: 2020-06-12 16:55+0200\n" +"Last-Translator: <>\n" +"Language-Team: \n" +"Language: es\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: \n" +"X-Generator: Poedit 2.3\n" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_res_partner +msgid "Contact" +msgstr "Contacto" + +#. module: sale_commission_salesman +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner_salesman_as_agent +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_users_salesman_as_agent +msgid "Convert salesman into agent" +msgstr "Convertir comercial a agente" + +#. module: sale_commission_salesman +#: model:ir.model.fields,help:sale_commission_salesman.field_res_partner_salesman_as_agent +#: model:ir.model.fields,help:sale_commission_salesman.field_res_users_salesman_as_agent +msgid "" +"If the user linked to this partner is put as salesman and no other " +"commission rule is triggered, this agent will be added as the commission " +"agent" +msgstr "" +"Si el usuario enlazado con este contacto se coloca como comercial y no hay " +"otra regla de comisión, este agente se añadirá como comisionista" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_account_invoice_line +msgid "Invoice Line" +msgstr "Linea de la Factura" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_sale_order_line +msgid "Sales Order Line" +msgstr "Línea de pedido de ventas" + +#. module: sale_commission_salesman +#: code:addons/sale_commission_salesman/models/res_partner.py:21 +#, python-format +msgid "You can't have a salesman auto-agent without commission." +msgstr "No puede tener un comercial auto-agente sin comisión definida." diff --git a/sale_commission_salesman/i18n/sale_commission_salesman.pot b/sale_commission_salesman/i18n/sale_commission_salesman.pot new file mode 100644 index 000000000..b99729ebd --- /dev/null +++ b/sale_commission_salesman/i18n/sale_commission_salesman.pot @@ -0,0 +1,48 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * sale_commission_salesman +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 11.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_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_res_partner +msgid "Contact" +msgstr "" + +#. module: sale_commission_salesman +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner_salesman_as_agent +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_users_salesman_as_agent +msgid "Convert salesman into agent" +msgstr "" + +#. module: sale_commission_salesman +#: model:ir.model.fields,help:sale_commission_salesman.field_res_partner_salesman_as_agent +#: model:ir.model.fields,help:sale_commission_salesman.field_res_users_salesman_as_agent +msgid "If the user linked to this partner is put as salesman and no other commission rule is triggered, this agent will be added as the commission agent" +msgstr "" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_account_invoice_line +msgid "Invoice Line" +msgstr "" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_sale_order_line +msgid "Sales Order Line" +msgstr "" + +#. module: sale_commission_salesman +#: code:addons/sale_commission_salesman/models/res_partner.py:21 +#, python-format +msgid "You can't have a salesman auto-agent without commission." +msgstr "" + diff --git a/sale_commission_salesman/models/__init__.py b/sale_commission_salesman/models/__init__.py new file mode 100644 index 000000000..9582ff43d --- /dev/null +++ b/sale_commission_salesman/models/__init__.py @@ -0,0 +1,5 @@ +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from . import account_invoice +from . import res_partner +from . import sale_order diff --git a/sale_commission_salesman/models/account_invoice.py b/sale_commission_salesman/models/account_invoice.py new file mode 100644 index 000000000..b0c687065 --- /dev/null +++ b/sale_commission_salesman/models/account_invoice.py @@ -0,0 +1,27 @@ +# Copyright 2020 Tecnativa - Pedro M. Baeza +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from odoo import models + + +class AccountInvoiceLine(models.Model): + _inherit = 'account.invoice.line' + + def _prepare_agents_vals(self, vals=None): + """Add salesman agent if configured so and no other commission + already populated. + """ + res = super()._prepare_agents_vals(vals=vals) + if not res: + partner = self.invoice_id.user_id.partner_id + if not self and vals.get("invoice_id"): + invoice = self.env["account.invoice"].browse(vals["invoice_id"]) + partner = invoice.user_id.partner_id + if partner.agent and partner.salesman_as_agent: + res = [ + (0, 0, { + 'agent': partner.id, + 'commission': partner.commission.id, + }), + ] + return res diff --git a/sale_commission_salesman/models/res_partner.py b/sale_commission_salesman/models/res_partner.py new file mode 100644 index 000000000..c76092d0e --- /dev/null +++ b/sale_commission_salesman/models/res_partner.py @@ -0,0 +1,23 @@ +# Copyright 2020 Tecnativa - Pedro M. Baeza +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from odoo import _, api, exceptions, fields, models + + +class ResPartner(models.Model): + _inherit = "res.partner" + + salesman_as_agent = fields.Boolean( + string="Convert salesman into agent", + help="If the user linked to this partner is put as salesman and no " + "other commission rule is triggered, this agent will be " + "added as the commission agent", + ) + + @api.constrains("salesman_as_agent", "commission") + def _check_salesman_as_agent(self): + for record in self: + if record.salesman_as_agent and not record.commission: + raise exceptions.ValidationError(_( + "You can't have a salesman auto-agent without commission." + )) diff --git a/sale_commission_salesman/models/sale_order.py b/sale_commission_salesman/models/sale_order.py new file mode 100644 index 000000000..4abc32ad9 --- /dev/null +++ b/sale_commission_salesman/models/sale_order.py @@ -0,0 +1,27 @@ +# Copyright 2020 Tecnativa - Pedro M. Baeza +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from odoo import models + + +class SaleOrdeLine(models.Model): + _inherit = 'sale.order.line' + + def _prepare_agents_vals(self, vals=None): + """Add salesman agent if configured so and no other commission + already populated. + """ + res = super()._prepare_agents_vals(vals=vals) + if not res: + partner = self.order_id.user_id.partner_id + if not self and vals.get("order_id"): + order = self.env["sale.order"].browse(vals["order_id"]) + partner = order.user_id.partner_id + if partner.agent and partner.salesman_as_agent: + res = [ + (0, 0, { + 'agent': partner.id, + 'commission': partner.commission.id, + }), + ] + return res diff --git a/sale_commission_salesman/readme/CONFIGURE.rst b/sale_commission_salesman/readme/CONFIGURE.rst new file mode 100644 index 000000000..dac00b397 --- /dev/null +++ b/sale_commission_salesman/readme/CONFIGURE.rst @@ -0,0 +1,6 @@ +#. Go to *Contacts*. +#. Search for the contact linked to the salesman user and open it. +#. If it's actually linked to a user, you'll see a new check in the + *Agent information* page, called "Convert salesman into agent". +#. Check it for having that salesman automatically populated as agent. You + need to assign a commission to that agent as well. diff --git a/sale_commission_salesman/readme/CONTRIBUTORS.rst b/sale_commission_salesman/readme/CONTRIBUTORS.rst new file mode 100644 index 000000000..2b13251be --- /dev/null +++ b/sale_commission_salesman/readme/CONTRIBUTORS.rst @@ -0,0 +1,3 @@ +* `Tecnativa `__: + + * Pedro M. Baeza diff --git a/sale_commission_salesman/readme/CREDITS.rst b/sale_commission_salesman/readme/CREDITS.rst new file mode 100644 index 000000000..4a895093c --- /dev/null +++ b/sale_commission_salesman/readme/CREDITS.rst @@ -0,0 +1 @@ +- Part of the icon made from Icon Fonts is licensed by CC BY 3.0 diff --git a/sale_commission_salesman/readme/DESCRIPTION.rst b/sale_commission_salesman/readme/DESCRIPTION.rst new file mode 100644 index 000000000..602dda7ec --- /dev/null +++ b/sale_commission_salesman/readme/DESCRIPTION.rst @@ -0,0 +1,6 @@ +This module extends the functionality of `sale_commission` to allow you to +auto-populate salesmen as commission agents without setting explicitly them +on the customer. + +**IMPORTANT**: The salesman will be only populated if no other commission agent +is set via other method, to assure that there's no overlapping commissions. diff --git a/sale_commission_salesman/readme/USAGE.rst b/sale_commission_salesman/readme/USAGE.rst new file mode 100644 index 000000000..04205310b --- /dev/null +++ b/sale_commission_salesman/readme/USAGE.rst @@ -0,0 +1,7 @@ +To use this module, you need to: + +#. Go to *Sales > Orders > Quotations* and create a new one. +#. Fill the customer with one with no agents set. +#. Select a salesman with the mark checked. +#. Add a line in the quotation, and you will see the salesman populated as + commission agent. diff --git a/sale_commission_salesman/static/description/icon.png b/sale_commission_salesman/static/description/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..7ce73f84986909d76a2189c08edbbd3583680187 GIT binary patch literal 17671 zcmXtf19T=$6K4^GtC%;-NXVpS_UGY}RgW+r+jHhLy*RVG#*7ET^E_C8;CyKiBc z|AbW>+?-9!KrCHd9bI@B866zW>`iQ~9F3e^|Fe?O)Xde$%9fFhm79Z`@jqtt4(9a# zmkj;?$j}>m(OVlB{b!PN71Pu=tmgkXI5>JaTUl7Tf{2PT5i7bG+gh0r|8TG~`X>Fu z%=Fu)|1tcp+3!|O{>Rwe%*4UY&cWX0e=R%yPsj9sDvaJ{&JK*s3`~qe`<*W!AjBY2 zKZI31v(G!d8ttU?j$a~;kSyBouEVp@AflOtE3$;6Ay9ziIOt<)i-)T6mDScw)l1D# zC5;t2(n{+UP1^sQ#oOUzgpeg=nNXZb&6sdlMr9KxeD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18wNax@{PGhz?_(>T8p8zIujuUG>ecDg-m2QrCO`1pO`g^Sa#!H-WKHXcuVi) z{duc*Rfof_4h91q4u`h5c+P;OvR$0L3Z8rJsYAy4koWp1XGUe95H(bQF;o(S zR~58s%71LsKQp{|?axm>x$?eSwEoWsewQFK!}9VnEiC~nE5~Rs7*N08rz=-}$L)5X z`lEfk)tm5S(r~*Sxvn$Em^lRHl$1pr#aNyq4Ki1uzc6)&?T5qZG*vrO(t758XdH?wKY3> z^pXvS$82%&oGmZoW>SG0`Te^JcP+s;V~1=2SYBQx09aaD!ph1D0l;8zj({(s-+z@} zfBg~x$8h{OaN)w`+5GOu>gww5Tn`*LV5QAp!AD02?G*q=j;z_)v%t}#M-BKbhQnh9 z0B + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + Openclipart + + + Pile of Golden Coins + 2010-04-09T03:27:45 + A pile of hypothetical golden coins, drawn in Inkscape. + https://openclipart.org/detail/43969/pile-of-golden-coins-by-j_alves + + + J_Alves + + + + + coin + currency + gold + money + thaler + + + + + + + + + + + diff --git a/sale_commission_salesman/static/description/index.html b/sale_commission_salesman/static/description/index.html new file mode 100644 index 000000000..1800fb0db --- /dev/null +++ b/sale_commission_salesman/static/description/index.html @@ -0,0 +1,457 @@ + + + + + + +Sales commissions from salesman + + + +
+

Sales commissions from salesman

+ + +

Beta License: AGPL-3 OCA/commission Translate me on Weblate Try me on Runbot

+

This module extends the functionality of sale_commission to allow you to +auto-populate salesmen as commission agents without setting explicitly them +on the customer.

+

IMPORTANT: The salesman will be only populated if no other commission agent +is set via other method, to assure that there’s no overlapping commissions.

+

Table of contents

+ +
+

Configuration

+
    +
  1. Go to Contacts.
  2. +
  3. Search for the contact linked to the salesman user and open it.
  4. +
  5. If it’s actually linked to a user, you’ll see a new check in the +Agent information page, called “Convert salesman into agent”.
  6. +
  7. Check it for having that salesman automatically populated as agent. You +need to assign a commission to that agent as well.
  8. +
+
+
+

Usage

+

To use this module, you need to:

+
    +
  1. Go to Sales > Orders > Quotations and create a new one.
  2. +
  3. Fill the customer with one with no agents set.
  4. +
  5. Select a salesman with the mark checked.
  6. +
  7. Add a line in the quotation, and you will see the salesman populated as +commission agent.
  8. +
+
+
+

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.

+

Do not contact contributors directly about support or help with technical issues.

+
+
+

Credits

+
+

Authors

+
    +
  • Tecnativa
  • +
+
+
+

Contributors

+ +
+
+

Other credits

+ +
+
+

Maintainers

+

This module is maintained by the OCA.

+Odoo Community Association +

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/commission project on GitHub.

+

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

+
+
+
+ + diff --git a/sale_commission_salesman/tests/__init__.py b/sale_commission_salesman/tests/__init__.py new file mode 100644 index 000000000..673e9d887 --- /dev/null +++ b/sale_commission_salesman/tests/__init__.py @@ -0,0 +1,3 @@ +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from . import test_sale_commission_salesman diff --git a/sale_commission_salesman/tests/test_sale_commission_salesman.py b/sale_commission_salesman/tests/test_sale_commission_salesman.py new file mode 100644 index 000000000..fa718f12a --- /dev/null +++ b/sale_commission_salesman/tests/test_sale_commission_salesman.py @@ -0,0 +1,108 @@ +# Copyright 2020 Tecnativa - Pedro M. Baeza +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from odoo import exceptions +from odoo.tests.common import SavepointCase + + +class TestSaleCommissionSalesman(SavepointCase): + + @classmethod + def setUpClass(cls): + super().setUpClass() + cls.product = cls.env['product.product'].create({ + 'name': 'Test Product 1', + 'list_price': 100, + }) + SaleCommission = cls.env['sale.commission'] + cls.commission_1 = SaleCommission.create({ + 'name': '1% commission', + 'fix_qty': 1.0, + }) + Partner = cls.env['res.partner'] + cls.salesman = cls.env["res.users"].create({ + "name": "Test agent", + "login": "sale_comission_salesman_test", + }) + cls.agent = cls.salesman.partner_id + cls.agent.write({ + "agent": True, + "salesman_as_agent": True, + 'commission': cls.commission_1.id, + }) + cls.other_agent = Partner.create({ + 'name': 'Test other agent', + 'agent': True, + 'commission': cls.commission_1.id, + }) + cls.partner = Partner.create({ + 'name': 'Partner test', + }) + cls.sale_order = cls.env['sale.order'].create({ + 'partner_id': cls.partner.id, + 'user_id': cls.salesman.id, + }) + cls.invoice = cls.env['account.invoice'].create({ + 'partner_id': cls.partner.id, + 'user_id': cls.salesman.id, + }) + + def test_check_salesman_commission(self): + with self.assertRaises(exceptions.ValidationError): + self.agent.commission = False + + def test_sale_commission_salesman(self): + line = self.env['sale.order.line'].with_context( + partner_id=self.partner.id + ).create({ + 'order_id': self.sale_order.id, + 'product_id': self.product.id, + }) + self.assertTrue(line.agents) + self.assertTrue(line.agents.agent, self.agent) + self.assertTrue(line.agents.commission, self.commission_1) + + def test_sale_commission_salesman_no_population(self): + self.partner.agents = [(4, self.other_agent.id)] + line = self.env['sale.order.line'].with_context( + partner_id=self.partner.id + ).create({ + 'order_id': self.sale_order.id, + 'product_id': self.product.id, + }) + self.assertTrue(len(line.agents), 1) + self.assertTrue(line.agents.agent, self.other_agent) + + def test_invoice_commission_salesman(self): + line_obj = self.env['account.invoice.line'] + line = line_obj.with_context( + partner_id=self.partner.id + ).create({ + 'invoice_id': self.invoice.id, + 'product_id': self.product.id, + 'account_id': line_obj.get_invoice_line_account( + self.invoice.type, self.product, False, + self.invoice.company_id).id, + 'name': self.product.name, + 'price_unit': 1, + }) + self.assertTrue(line.agents) + self.assertTrue(line.agents.agent, self.agent) + self.assertTrue(line.agents.commission, self.commission_1) + + def test_invoice_commission_salesman_no_population(self): + self.partner.agents = [(4, self.other_agent.id)] + line_obj = self.env['account.invoice.line'] + line = line_obj.with_context( + partner_id=self.partner.id + ).create({ + 'invoice_id': self.invoice.id, + 'product_id': self.product.id, + 'account_id': line_obj.get_invoice_line_account( + self.invoice.type, self.product, False, + self.invoice.company_id).id, + 'name': self.product.name, + 'price_unit': 1, + }) + self.assertTrue(len(line.agents), 1) + self.assertTrue(line.agents.agent, self.other_agent) diff --git a/sale_commission_salesman/views/res_partner_views.xml b/sale_commission_salesman/views/res_partner_views.xml new file mode 100644 index 000000000..1477f25f7 --- /dev/null +++ b/sale_commission_salesman/views/res_partner_views.xml @@ -0,0 +1,17 @@ + + + + + + res.partner + + + + + + + + + + From 075d6ccd95d10c78e65fe00357f46b0825fbed72 Mon Sep 17 00:00:00 2001 From: "Pedro M. Baeza" Date: Mon, 27 Jul 2020 20:36:12 +0200 Subject: [PATCH 02/25] [MIG] sale_commission_salesman: Migration to 12.0 - Standard procedure. --- sale_commission_salesman/README.rst | 10 +++++----- sale_commission_salesman/__manifest__.py | 2 +- .../i18n/sale_commission_salesman.pot | 10 +++++----- sale_commission_salesman/static/description/index.html | 6 +++--- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/sale_commission_salesman/README.rst b/sale_commission_salesman/README.rst index bb2baa494..49593c5b1 100644 --- a/sale_commission_salesman/README.rst +++ b/sale_commission_salesman/README.rst @@ -14,13 +14,13 @@ Sales commissions from salesman :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fcommission-lightgray.png?logo=github - :target: https://github.com/OCA/commission/tree/11.0/sale_commission_salesman + :target: https://github.com/OCA/commission/tree/12.0/sale_commission_salesman :alt: OCA/commission .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/commission-11-0/commission-11-0-sale_commission_salesman + :target: https://translation.odoo-community.org/projects/commission-12-0/commission-12-0-sale_commission_salesman :alt: Translate me on Weblate .. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/165/11.0 + :target: https://runbot.odoo-community.org/runbot/165/12.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -64,7 +64,7 @@ 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 `_. +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -101,6 +101,6 @@ 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/commission `_ project on GitHub. +This module is part of the `OCA/commission `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/sale_commission_salesman/__manifest__.py b/sale_commission_salesman/__manifest__.py index 8f5bb7ddf..f4f0c62ae 100644 --- a/sale_commission_salesman/__manifest__.py +++ b/sale_commission_salesman/__manifest__.py @@ -3,7 +3,7 @@ { "name": "Sales commissions from salesman", - "version": "11.0.1.0.0", + "version": "12.0.1.0.0", "author": "Tecnativa, " "Odoo Community Association (OCA)", "category": "Sales", diff --git a/sale_commission_salesman/i18n/sale_commission_salesman.pot b/sale_commission_salesman/i18n/sale_commission_salesman.pot index b99729ebd..15fb8abf2 100644 --- a/sale_commission_salesman/i18n/sale_commission_salesman.pot +++ b/sale_commission_salesman/i18n/sale_commission_salesman.pot @@ -4,7 +4,7 @@ # msgid "" msgstr "" -"Project-Id-Version: Odoo Server 11.0\n" +"Project-Id-Version: Odoo Server 12.0\n" "Report-Msgid-Bugs-To: \n" "Last-Translator: <>\n" "Language-Team: \n" @@ -19,14 +19,14 @@ msgid "Contact" msgstr "" #. module: sale_commission_salesman -#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner_salesman_as_agent -#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_users_salesman_as_agent +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner__salesman_as_agent +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_users__salesman_as_agent msgid "Convert salesman into agent" msgstr "" #. module: sale_commission_salesman -#: model:ir.model.fields,help:sale_commission_salesman.field_res_partner_salesman_as_agent -#: model:ir.model.fields,help:sale_commission_salesman.field_res_users_salesman_as_agent +#: model:ir.model.fields,help:sale_commission_salesman.field_res_partner__salesman_as_agent +#: model:ir.model.fields,help:sale_commission_salesman.field_res_users__salesman_as_agent msgid "If the user linked to this partner is put as salesman and no other commission rule is triggered, this agent will be added as the commission agent" msgstr "" diff --git a/sale_commission_salesman/static/description/index.html b/sale_commission_salesman/static/description/index.html index 1800fb0db..19a4fe370 100644 --- a/sale_commission_salesman/static/description/index.html +++ b/sale_commission_salesman/static/description/index.html @@ -367,7 +367,7 @@

Sales commissions from salesman

!! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> -

Beta License: AGPL-3 OCA/commission Translate me on Weblate Try me on Runbot

+

Beta License: AGPL-3 OCA/commission Translate me on Weblate Try me on Runbot

This module extends the functionality of sale_commission to allow you to auto-populate salesmen as commission agents without setting explicitly them on the customer.

@@ -415,7 +415,7 @@

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.

+feedback.

Do not contact contributors directly about support or help with technical issues.

@@ -448,7 +448,7 @@

Maintainers

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/commission project on GitHub.

+

This module is part of the OCA/commission project on GitHub.

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

From e73474303ddacd959eaadcfd6ab47df60c6c2af5 Mon Sep 17 00:00:00 2001 From: "Pedro M. Baeza" Date: Fri, 7 Aug 2020 19:09:54 +0200 Subject: [PATCH 03/25] [IMP] sale_commission_salesman: black, isort, prettier --- sale_commission_salesman/__manifest__.py | 11 +- .../models/account_invoice.py | 7 +- .../models/res_partner.py | 10 +- sale_commission_salesman/models/sale_order.py | 7 +- .../tests/test_sale_commission_salesman.py | 138 +++++++++--------- .../views/res_partner_views.xml | 13 +- 6 files changed, 85 insertions(+), 101 deletions(-) diff --git a/sale_commission_salesman/__manifest__.py b/sale_commission_salesman/__manifest__.py index f4f0c62ae..29d54726a 100644 --- a/sale_commission_salesman/__manifest__.py +++ b/sale_commission_salesman/__manifest__.py @@ -4,16 +4,11 @@ { "name": "Sales commissions from salesman", "version": "12.0.1.0.0", - "author": "Tecnativa, " - "Odoo Community Association (OCA)", + "author": "Tecnativa, " "Odoo Community Association (OCA)", "category": "Sales", "website": "https://github.com/OCA/commission", "license": "AGPL-3", - "depends": [ - "sale_commission", - ], - "data": [ - "views/res_partner_views.xml", - ], + "depends": ["sale_commission",], + "data": ["views/res_partner_views.xml",], "installable": True, } diff --git a/sale_commission_salesman/models/account_invoice.py b/sale_commission_salesman/models/account_invoice.py index b0c687065..164cc4048 100644 --- a/sale_commission_salesman/models/account_invoice.py +++ b/sale_commission_salesman/models/account_invoice.py @@ -5,7 +5,7 @@ class AccountInvoiceLine(models.Model): - _inherit = 'account.invoice.line' + _inherit = "account.invoice.line" def _prepare_agents_vals(self, vals=None): """Add salesman agent if configured so and no other commission @@ -19,9 +19,6 @@ def _prepare_agents_vals(self, vals=None): partner = invoice.user_id.partner_id if partner.agent and partner.salesman_as_agent: res = [ - (0, 0, { - 'agent': partner.id, - 'commission': partner.commission.id, - }), + (0, 0, {"agent": partner.id, "commission": partner.commission.id,}), ] return res diff --git a/sale_commission_salesman/models/res_partner.py b/sale_commission_salesman/models/res_partner.py index c76092d0e..2ba9a9a3d 100644 --- a/sale_commission_salesman/models/res_partner.py +++ b/sale_commission_salesman/models/res_partner.py @@ -10,14 +10,14 @@ class ResPartner(models.Model): salesman_as_agent = fields.Boolean( string="Convert salesman into agent", help="If the user linked to this partner is put as salesman and no " - "other commission rule is triggered, this agent will be " - "added as the commission agent", + "other commission rule is triggered, this agent will be " + "added as the commission agent", ) @api.constrains("salesman_as_agent", "commission") def _check_salesman_as_agent(self): for record in self: if record.salesman_as_agent and not record.commission: - raise exceptions.ValidationError(_( - "You can't have a salesman auto-agent without commission." - )) + raise exceptions.ValidationError( + _("You can't have a salesman auto-agent without commission.") + ) diff --git a/sale_commission_salesman/models/sale_order.py b/sale_commission_salesman/models/sale_order.py index 4abc32ad9..74bd6b776 100644 --- a/sale_commission_salesman/models/sale_order.py +++ b/sale_commission_salesman/models/sale_order.py @@ -5,7 +5,7 @@ class SaleOrdeLine(models.Model): - _inherit = 'sale.order.line' + _inherit = "sale.order.line" def _prepare_agents_vals(self, vals=None): """Add salesman agent if configured so and no other commission @@ -19,9 +19,6 @@ def _prepare_agents_vals(self, vals=None): partner = order.user_id.partner_id if partner.agent and partner.salesman_as_agent: res = [ - (0, 0, { - 'agent': partner.id, - 'commission': partner.commission.id, - }), + (0, 0, {"agent": partner.id, "commission": partner.commission.id,}), ] return res diff --git a/sale_commission_salesman/tests/test_sale_commission_salesman.py b/sale_commission_salesman/tests/test_sale_commission_salesman.py index fa718f12a..073e62160 100644 --- a/sale_commission_salesman/tests/test_sale_commission_salesman.py +++ b/sale_commission_salesman/tests/test_sale_commission_salesman.py @@ -6,103 +6,97 @@ class TestSaleCommissionSalesman(SavepointCase): - @classmethod def setUpClass(cls): super().setUpClass() - cls.product = cls.env['product.product'].create({ - 'name': 'Test Product 1', - 'list_price': 100, - }) - SaleCommission = cls.env['sale.commission'] - cls.commission_1 = SaleCommission.create({ - 'name': '1% commission', - 'fix_qty': 1.0, - }) - Partner = cls.env['res.partner'] - cls.salesman = cls.env["res.users"].create({ - "name": "Test agent", - "login": "sale_comission_salesman_test", - }) + cls.product = cls.env["product.product"].create( + {"name": "Test Product 1", "list_price": 100,} + ) + SaleCommission = cls.env["sale.commission"] + cls.commission_1 = SaleCommission.create( + {"name": "1% commission", "fix_qty": 1.0,} + ) + Partner = cls.env["res.partner"] + cls.salesman = cls.env["res.users"].create( + {"name": "Test agent", "login": "sale_comission_salesman_test",} + ) cls.agent = cls.salesman.partner_id - cls.agent.write({ - "agent": True, - "salesman_as_agent": True, - 'commission': cls.commission_1.id, - }) - cls.other_agent = Partner.create({ - 'name': 'Test other agent', - 'agent': True, - 'commission': cls.commission_1.id, - }) - cls.partner = Partner.create({ - 'name': 'Partner test', - }) - cls.sale_order = cls.env['sale.order'].create({ - 'partner_id': cls.partner.id, - 'user_id': cls.salesman.id, - }) - cls.invoice = cls.env['account.invoice'].create({ - 'partner_id': cls.partner.id, - 'user_id': cls.salesman.id, - }) + cls.agent.write( + { + "agent": True, + "salesman_as_agent": True, + "commission": cls.commission_1.id, + } + ) + cls.other_agent = Partner.create( + { + "name": "Test other agent", + "agent": True, + "commission": cls.commission_1.id, + } + ) + cls.partner = Partner.create({"name": "Partner test",}) + cls.sale_order = cls.env["sale.order"].create( + {"partner_id": cls.partner.id, "user_id": cls.salesman.id,} + ) + cls.invoice = cls.env["account.invoice"].create( + {"partner_id": cls.partner.id, "user_id": cls.salesman.id,} + ) def test_check_salesman_commission(self): with self.assertRaises(exceptions.ValidationError): self.agent.commission = False def test_sale_commission_salesman(self): - line = self.env['sale.order.line'].with_context( - partner_id=self.partner.id - ).create({ - 'order_id': self.sale_order.id, - 'product_id': self.product.id, - }) + line = ( + self.env["sale.order.line"] + .with_context(partner_id=self.partner.id) + .create({"order_id": self.sale_order.id, "product_id": self.product.id,}) + ) self.assertTrue(line.agents) self.assertTrue(line.agents.agent, self.agent) self.assertTrue(line.agents.commission, self.commission_1) def test_sale_commission_salesman_no_population(self): self.partner.agents = [(4, self.other_agent.id)] - line = self.env['sale.order.line'].with_context( - partner_id=self.partner.id - ).create({ - 'order_id': self.sale_order.id, - 'product_id': self.product.id, - }) + line = ( + self.env["sale.order.line"] + .with_context(partner_id=self.partner.id) + .create({"order_id": self.sale_order.id, "product_id": self.product.id,}) + ) self.assertTrue(len(line.agents), 1) self.assertTrue(line.agents.agent, self.other_agent) def test_invoice_commission_salesman(self): - line_obj = self.env['account.invoice.line'] - line = line_obj.with_context( - partner_id=self.partner.id - ).create({ - 'invoice_id': self.invoice.id, - 'product_id': self.product.id, - 'account_id': line_obj.get_invoice_line_account( - self.invoice.type, self.product, False, - self.invoice.company_id).id, - 'name': self.product.name, - 'price_unit': 1, - }) + line_obj = self.env["account.invoice.line"] + line = line_obj.with_context(partner_id=self.partner.id).create( + { + "invoice_id": self.invoice.id, + "product_id": self.product.id, + "account_id": line_obj.get_invoice_line_account( + self.invoice.type, self.product, False, self.invoice.company_id + ).id, + "name": self.product.name, + "price_unit": 1, + } + ) self.assertTrue(line.agents) self.assertTrue(line.agents.agent, self.agent) self.assertTrue(line.agents.commission, self.commission_1) def test_invoice_commission_salesman_no_population(self): self.partner.agents = [(4, self.other_agent.id)] - line_obj = self.env['account.invoice.line'] - line = line_obj.with_context( - partner_id=self.partner.id - ).create({ - 'invoice_id': self.invoice.id, - 'product_id': self.product.id, - 'account_id': line_obj.get_invoice_line_account( - self.invoice.type, self.product, False, - self.invoice.company_id).id, - 'name': self.product.name, - 'price_unit': 1, - }) + line_obj = self.env["account.invoice.line"] + line = line_obj.with_context(partner_id=self.partner.id).create( + { + "invoice_id": self.invoice.id, + "product_id": self.product.id, + "account_id": line_obj.get_invoice_line_account( + self.invoice.type, self.product, False, self.invoice.company_id + ).id, + "name": self.product.name, + "price_unit": 1, + } + ) self.assertTrue(len(line.agents), 1) self.assertTrue(line.agents.agent, self.other_agent) diff --git a/sale_commission_salesman/views/res_partner_views.xml b/sale_commission_salesman/views/res_partner_views.xml index 1477f25f7..719563ca2 100644 --- a/sale_commission_salesman/views/res_partner_views.xml +++ b/sale_commission_salesman/views/res_partner_views.xml @@ -1,17 +1,18 @@ - + - res.partner - + - - + + - From 85d0e3f357e0e407261c8109f0de8c90b342b8ca Mon Sep 17 00:00:00 2001 From: "Pedro M. Baeza" Date: Fri, 7 Aug 2020 20:09:43 +0200 Subject: [PATCH 04/25] [MIG] sale_commission_salesman: Migration to 13.0 * Standard procedure * Adapt account.invoice > account.move * Adapt tests --- sale_commission_salesman/README.rst | 10 +- sale_commission_salesman/__manifest__.py | 6 +- sale_commission_salesman/i18n/es.po | 19 ++-- .../i18n/sale_commission_salesman.pot | 18 ++-- sale_commission_salesman/models/__init__.py | 2 +- .../models/account_invoice.py | 24 ----- .../models/account_move.py | 23 +++++ .../models/res_partner.py | 4 +- sale_commission_salesman/models/sale_order.py | 16 +--- .../static/description/index.html | 6 +- .../tests/test_sale_commission_salesman.py | 96 ++++++++----------- .../views/res_partner_views.xml | 2 +- 12 files changed, 105 insertions(+), 121 deletions(-) delete mode 100644 sale_commission_salesman/models/account_invoice.py create mode 100644 sale_commission_salesman/models/account_move.py diff --git a/sale_commission_salesman/README.rst b/sale_commission_salesman/README.rst index 49593c5b1..e0af1ac39 100644 --- a/sale_commission_salesman/README.rst +++ b/sale_commission_salesman/README.rst @@ -14,13 +14,13 @@ Sales commissions from salesman :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fcommission-lightgray.png?logo=github - :target: https://github.com/OCA/commission/tree/12.0/sale_commission_salesman + :target: https://github.com/OCA/commission/tree/13.0/sale_commission_salesman :alt: OCA/commission .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/commission-12-0/commission-12-0-sale_commission_salesman + :target: https://translation.odoo-community.org/projects/commission-13-0/commission-13-0-sale_commission_salesman :alt: Translate me on Weblate .. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/165/12.0 + :target: https://runbot.odoo-community.org/runbot/165/13.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -64,7 +64,7 @@ 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 `_. +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -101,6 +101,6 @@ 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/commission `_ project on GitHub. +This module is part of the `OCA/commission `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/sale_commission_salesman/__manifest__.py b/sale_commission_salesman/__manifest__.py index 29d54726a..b9ea9acaa 100644 --- a/sale_commission_salesman/__manifest__.py +++ b/sale_commission_salesman/__manifest__.py @@ -3,12 +3,12 @@ { "name": "Sales commissions from salesman", - "version": "12.0.1.0.0", + "version": "13.0.1.0.0", "author": "Tecnativa, " "Odoo Community Association (OCA)", "category": "Sales", "website": "https://github.com/OCA/commission", "license": "AGPL-3", - "depends": ["sale_commission",], - "data": ["views/res_partner_views.xml",], + "depends": ["sale_commission"], + "data": ["views/res_partner_views.xml"], "installable": True, } diff --git a/sale_commission_salesman/i18n/es.po b/sale_commission_salesman/i18n/es.po index a56c54aad..2c2c21923 100644 --- a/sale_commission_salesman/i18n/es.po +++ b/sale_commission_salesman/i18n/es.po @@ -23,14 +23,14 @@ msgid "Contact" msgstr "Contacto" #. module: sale_commission_salesman -#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner_salesman_as_agent -#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_users_salesman_as_agent +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner__salesman_as_agent +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_users__salesman_as_agent msgid "Convert salesman into agent" msgstr "Convertir comercial a agente" #. module: sale_commission_salesman -#: model:ir.model.fields,help:sale_commission_salesman.field_res_partner_salesman_as_agent -#: model:ir.model.fields,help:sale_commission_salesman.field_res_users_salesman_as_agent +#: model:ir.model.fields,help:sale_commission_salesman.field_res_partner__salesman_as_agent +#: model:ir.model.fields,help:sale_commission_salesman.field_res_users__salesman_as_agent msgid "" "If the user linked to this partner is put as salesman and no other " "commission rule is triggered, this agent will be added as the commission " @@ -40,9 +40,9 @@ msgstr "" "otra regla de comisión, este agente se añadirá como comisionista" #. module: sale_commission_salesman -#: model:ir.model,name:sale_commission_salesman.model_account_invoice_line -msgid "Invoice Line" -msgstr "Linea de la Factura" +#: model:ir.model,name:sale_commission_salesman.model_account_move_line +msgid "Journal Item" +msgstr "" #. module: sale_commission_salesman #: model:ir.model,name:sale_commission_salesman.model_sale_order_line @@ -50,7 +50,10 @@ msgid "Sales Order Line" msgstr "Línea de pedido de ventas" #. module: sale_commission_salesman -#: code:addons/sale_commission_salesman/models/res_partner.py:21 +#: code:addons/sale_commission_salesman/models/res_partner.py:0 #, python-format msgid "You can't have a salesman auto-agent without commission." msgstr "No puede tener un comercial auto-agente sin comisión definida." + +#~ msgid "Invoice Line" +#~ msgstr "Linea de la Factura" diff --git a/sale_commission_salesman/i18n/sale_commission_salesman.pot b/sale_commission_salesman/i18n/sale_commission_salesman.pot index 15fb8abf2..2a4bb22e6 100644 --- a/sale_commission_salesman/i18n/sale_commission_salesman.pot +++ b/sale_commission_salesman/i18n/sale_commission_salesman.pot @@ -1,12 +1,12 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: -# * sale_commission_salesman +# * sale_commission_salesman # msgid "" msgstr "" -"Project-Id-Version: Odoo Server 12.0\n" +"Project-Id-Version: Odoo Server 13.0\n" "Report-Msgid-Bugs-To: \n" -"Last-Translator: <>\n" +"Last-Translator: \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -27,12 +27,15 @@ msgstr "" #. module: sale_commission_salesman #: model:ir.model.fields,help:sale_commission_salesman.field_res_partner__salesman_as_agent #: model:ir.model.fields,help:sale_commission_salesman.field_res_users__salesman_as_agent -msgid "If the user linked to this partner is put as salesman and no other commission rule is triggered, this agent will be added as the commission agent" +msgid "" +"If the user linked to this partner is put as salesman and no other " +"commission rule is triggered, this agent will be added as the commission " +"agent" msgstr "" #. module: sale_commission_salesman -#: model:ir.model,name:sale_commission_salesman.model_account_invoice_line -msgid "Invoice Line" +#: model:ir.model,name:sale_commission_salesman.model_account_move_line +msgid "Journal Item" msgstr "" #. module: sale_commission_salesman @@ -41,8 +44,7 @@ msgid "Sales Order Line" msgstr "" #. module: sale_commission_salesman -#: code:addons/sale_commission_salesman/models/res_partner.py:21 +#: code:addons/sale_commission_salesman/models/res_partner.py:0 #, python-format msgid "You can't have a salesman auto-agent without commission." msgstr "" - diff --git a/sale_commission_salesman/models/__init__.py b/sale_commission_salesman/models/__init__.py index 9582ff43d..50fe8eac5 100644 --- a/sale_commission_salesman/models/__init__.py +++ b/sale_commission_salesman/models/__init__.py @@ -1,5 +1,5 @@ # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). -from . import account_invoice +from . import account_move from . import res_partner from . import sale_order diff --git a/sale_commission_salesman/models/account_invoice.py b/sale_commission_salesman/models/account_invoice.py deleted file mode 100644 index 164cc4048..000000000 --- a/sale_commission_salesman/models/account_invoice.py +++ /dev/null @@ -1,24 +0,0 @@ -# Copyright 2020 Tecnativa - Pedro M. Baeza -# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). - -from odoo import models - - -class AccountInvoiceLine(models.Model): - _inherit = "account.invoice.line" - - def _prepare_agents_vals(self, vals=None): - """Add salesman agent if configured so and no other commission - already populated. - """ - res = super()._prepare_agents_vals(vals=vals) - if not res: - partner = self.invoice_id.user_id.partner_id - if not self and vals.get("invoice_id"): - invoice = self.env["account.invoice"].browse(vals["invoice_id"]) - partner = invoice.user_id.partner_id - if partner.agent and partner.salesman_as_agent: - res = [ - (0, 0, {"agent": partner.id, "commission": partner.commission.id,}), - ] - return res diff --git a/sale_commission_salesman/models/account_move.py b/sale_commission_salesman/models/account_move.py new file mode 100644 index 000000000..e0028f089 --- /dev/null +++ b/sale_commission_salesman/models/account_move.py @@ -0,0 +1,23 @@ +# Copyright 2020 Tecnativa - Pedro M. Baeza +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from odoo import models + + +class AccountMoveLine(models.Model): + _inherit = "account.move.line" + + def _compute_agent_ids(self): + """Add salesman agent if configured so and no other commission + already populated. + """ + super()._compute_agent_ids() + for record in self.filtered( + lambda x: x.move_id.partner_id + and x.move_id.type[:3] == "out" + and x.product_id + and not x.agent_ids + ): + partner = self.move_id.invoice_user_id.partner_id + if partner.agent and partner.salesman_as_agent: + record.agent_ids = [(0, 0, self._prepare_agent_vals(partner))] diff --git a/sale_commission_salesman/models/res_partner.py b/sale_commission_salesman/models/res_partner.py index 2ba9a9a3d..3f284bd4e 100644 --- a/sale_commission_salesman/models/res_partner.py +++ b/sale_commission_salesman/models/res_partner.py @@ -14,10 +14,10 @@ class ResPartner(models.Model): "added as the commission agent", ) - @api.constrains("salesman_as_agent", "commission") + @api.constrains("salesman_as_agent", "commission_id") def _check_salesman_as_agent(self): for record in self: - if record.salesman_as_agent and not record.commission: + if record.salesman_as_agent and not record.commission_id: raise exceptions.ValidationError( _("You can't have a salesman auto-agent without commission.") ) diff --git a/sale_commission_salesman/models/sale_order.py b/sale_commission_salesman/models/sale_order.py index 74bd6b776..cddbb9665 100644 --- a/sale_commission_salesman/models/sale_order.py +++ b/sale_commission_salesman/models/sale_order.py @@ -7,18 +7,12 @@ class SaleOrdeLine(models.Model): _inherit = "sale.order.line" - def _prepare_agents_vals(self, vals=None): + def _compute_agent_ids(self): """Add salesman agent if configured so and no other commission already populated. """ - res = super()._prepare_agents_vals(vals=vals) - if not res: + super()._compute_agent_ids() + for record in self.filtered(lambda x: x.order_id.partner_id): partner = self.order_id.user_id.partner_id - if not self and vals.get("order_id"): - order = self.env["sale.order"].browse(vals["order_id"]) - partner = order.user_id.partner_id - if partner.agent and partner.salesman_as_agent: - res = [ - (0, 0, {"agent": partner.id, "commission": partner.commission.id,}), - ] - return res + if not record.agent_ids and partner.agent and partner.salesman_as_agent: + record.agent_ids = [(0, 0, self._prepare_agent_vals(partner))] diff --git a/sale_commission_salesman/static/description/index.html b/sale_commission_salesman/static/description/index.html index 19a4fe370..2a0da26f1 100644 --- a/sale_commission_salesman/static/description/index.html +++ b/sale_commission_salesman/static/description/index.html @@ -367,7 +367,7 @@

Sales commissions from salesman

!! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> -

Beta License: AGPL-3 OCA/commission Translate me on Weblate Try me on Runbot

+

Beta License: AGPL-3 OCA/commission Translate me on Weblate Try me on Runbot

This module extends the functionality of sale_commission to allow you to auto-populate salesmen as commission agents without setting explicitly them on the customer.

@@ -415,7 +415,7 @@

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.

+feedback.

Do not contact contributors directly about support or help with technical issues.

@@ -448,7 +448,7 @@

Maintainers

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/commission project on GitHub.

+

This module is part of the OCA/commission project on GitHub.

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

diff --git a/sale_commission_salesman/tests/test_sale_commission_salesman.py b/sale_commission_salesman/tests/test_sale_commission_salesman.py index 073e62160..cc9a8ac17 100644 --- a/sale_commission_salesman/tests/test_sale_commission_salesman.py +++ b/sale_commission_salesman/tests/test_sale_commission_salesman.py @@ -2,7 +2,7 @@ # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). from odoo import exceptions -from odoo.tests.common import SavepointCase +from odoo.tests.common import Form, SavepointCase class TestSaleCommissionSalesman(SavepointCase): @@ -10,93 +10,79 @@ class TestSaleCommissionSalesman(SavepointCase): def setUpClass(cls): super().setUpClass() cls.product = cls.env["product.product"].create( - {"name": "Test Product 1", "list_price": 100,} + {"name": "Test Product 1", "list_price": 100} ) SaleCommission = cls.env["sale.commission"] cls.commission_1 = SaleCommission.create( - {"name": "1% commission", "fix_qty": 1.0,} + {"name": "1% commission", "fix_qty": 1.0} ) Partner = cls.env["res.partner"] cls.salesman = cls.env["res.users"].create( - {"name": "Test agent", "login": "sale_comission_salesman_test",} + {"name": "Test agent", "login": "sale_comission_salesman_test"} ) cls.agent = cls.salesman.partner_id cls.agent.write( { "agent": True, "salesman_as_agent": True, - "commission": cls.commission_1.id, + "commission_id": cls.commission_1.id, } ) cls.other_agent = Partner.create( { "name": "Test other agent", "agent": True, - "commission": cls.commission_1.id, + "commission_id": cls.commission_1.id, } ) - cls.partner = Partner.create({"name": "Partner test",}) + cls.partner = Partner.create({"name": "Partner test"}) cls.sale_order = cls.env["sale.order"].create( - {"partner_id": cls.partner.id, "user_id": cls.salesman.id,} + {"partner_id": cls.partner.id, "user_id": cls.salesman.id} ) - cls.invoice = cls.env["account.invoice"].create( - {"partner_id": cls.partner.id, "user_id": cls.salesman.id,} + cls.invoice = cls.env["account.move"].create( + { + "partner_id": cls.partner.id, + "invoice_user_id": cls.salesman.id, + "type": "out_invoice", + } ) def test_check_salesman_commission(self): with self.assertRaises(exceptions.ValidationError): - self.agent.commission = False + self.agent.commission_id = False def test_sale_commission_salesman(self): - line = ( - self.env["sale.order.line"] - .with_context(partner_id=self.partner.id) - .create({"order_id": self.sale_order.id, "product_id": self.product.id,}) + line = self.env["sale.order.line"].create( + {"order_id": self.sale_order.id, "product_id": self.product.id} ) - self.assertTrue(line.agents) - self.assertTrue(line.agents.agent, self.agent) - self.assertTrue(line.agents.commission, self.commission_1) + self.assertTrue(line.agent_ids) + self.assertTrue(line.agent_ids.agent_id, self.agent) + self.assertTrue(line.agent_ids.commission_id, self.commission_1) def test_sale_commission_salesman_no_population(self): - self.partner.agents = [(4, self.other_agent.id)] - line = ( - self.env["sale.order.line"] - .with_context(partner_id=self.partner.id) - .create({"order_id": self.sale_order.id, "product_id": self.product.id,}) + self.partner.agent_ids = [(4, self.other_agent.id)] + line = self.env["sale.order.line"].create( + {"order_id": self.sale_order.id, "product_id": self.product.id} ) - self.assertTrue(len(line.agents), 1) - self.assertTrue(line.agents.agent, self.other_agent) + self.assertTrue(len(line.agent_ids), 1) + self.assertTrue(line.agent_ids.agent_id, self.other_agent) def test_invoice_commission_salesman(self): - line_obj = self.env["account.invoice.line"] - line = line_obj.with_context(partner_id=self.partner.id).create( - { - "invoice_id": self.invoice.id, - "product_id": self.product.id, - "account_id": line_obj.get_invoice_line_account( - self.invoice.type, self.product, False, self.invoice.company_id - ).id, - "name": self.product.name, - "price_unit": 1, - } - ) - self.assertTrue(line.agents) - self.assertTrue(line.agents.agent, self.agent) - self.assertTrue(line.agents.commission, self.commission_1) + invoice_form = Form(self.invoice) + with invoice_form.invoice_line_ids.new() as line_form: + line_form.product_id = self.product + invoice_form.save() + line = self.invoice.invoice_line_ids + self.assertTrue(line.agent_ids) + self.assertTrue(line.agent_ids.agent_id, self.agent) + self.assertTrue(line.agent_ids.commission_id, self.commission_1) def test_invoice_commission_salesman_no_population(self): - self.partner.agents = [(4, self.other_agent.id)] - line_obj = self.env["account.invoice.line"] - line = line_obj.with_context(partner_id=self.partner.id).create( - { - "invoice_id": self.invoice.id, - "product_id": self.product.id, - "account_id": line_obj.get_invoice_line_account( - self.invoice.type, self.product, False, self.invoice.company_id - ).id, - "name": self.product.name, - "price_unit": 1, - } - ) - self.assertTrue(len(line.agents), 1) - self.assertTrue(line.agents.agent, self.other_agent) + self.partner.agent_ids = [(4, self.other_agent.id)] + invoice_form = Form(self.invoice) + with invoice_form.invoice_line_ids.new() as line_form: + line_form.product_id = self.product + invoice_form.save() + line = self.invoice.invoice_line_ids + self.assertTrue(line.agent_ids) + self.assertTrue(line.agent_ids.agent_id, self.other_agent) diff --git a/sale_commission_salesman/views/res_partner_views.xml b/sale_commission_salesman/views/res_partner_views.xml index 719563ca2..055161624 100644 --- a/sale_commission_salesman/views/res_partner_views.xml +++ b/sale_commission_salesman/views/res_partner_views.xml @@ -6,7 +6,7 @@ res.partner - + Date: Sat, 12 Sep 2020 21:11:02 +0000 Subject: [PATCH 05/25] Added translation using Weblate (Spanish (Argentina)) --- sale_commission_salesman/i18n/es.po | 10 ++--- sale_commission_salesman/i18n/es_AR.po | 56 ++++++++++++++++++++++++++ 2 files changed, 61 insertions(+), 5 deletions(-) create mode 100644 sale_commission_salesman/i18n/es_AR.po diff --git a/sale_commission_salesman/i18n/es.po b/sale_commission_salesman/i18n/es.po index 2c2c21923..25861d32d 100644 --- a/sale_commission_salesman/i18n/es.po +++ b/sale_commission_salesman/i18n/es.po @@ -7,15 +7,15 @@ msgstr "" "Project-Id-Version: Odoo Server 11.0\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2020-06-12 14:51+0000\n" -"PO-Revision-Date: 2020-06-12 16:55+0200\n" -"Last-Translator: <>\n" +"PO-Revision-Date: 2021-03-17 15:45+0000\n" +"Last-Translator: Ana Suárez \n" "Language-Team: \n" "Language: es\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"Plural-Forms: \n" -"X-Generator: Poedit 2.3\n" +"Plural-Forms: nplurals=2; plural=n != 1;\n" +"X-Generator: Weblate 4.3.2\n" #. module: sale_commission_salesman #: model:ir.model,name:sale_commission_salesman.model_res_partner @@ -42,7 +42,7 @@ msgstr "" #. module: sale_commission_salesman #: model:ir.model,name:sale_commission_salesman.model_account_move_line msgid "Journal Item" -msgstr "" +msgstr "Apunte contable" #. module: sale_commission_salesman #: model:ir.model,name:sale_commission_salesman.model_sale_order_line diff --git a/sale_commission_salesman/i18n/es_AR.po b/sale_commission_salesman/i18n/es_AR.po new file mode 100644 index 000000000..53edc3574 --- /dev/null +++ b/sale_commission_salesman/i18n/es_AR.po @@ -0,0 +1,56 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * sale_commission_salesman +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 13.0\n" +"Report-Msgid-Bugs-To: \n" +"PO-Revision-Date: 2020-10-05 20:16+0000\n" +"Last-Translator: Ignacio Buioli \n" +"Language-Team: none\n" +"Language: es_AR\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.10\n" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_res_partner +msgid "Contact" +msgstr "Contacto" + +#. module: sale_commission_salesman +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner__salesman_as_agent +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_users__salesman_as_agent +msgid "Convert salesman into agent" +msgstr "Convertir vendedor en agente" + +#. module: sale_commission_salesman +#: model:ir.model.fields,help:sale_commission_salesman.field_res_partner__salesman_as_agent +#: model:ir.model.fields,help:sale_commission_salesman.field_res_users__salesman_as_agent +msgid "" +"If the user linked to this partner is put as salesman and no other " +"commission rule is triggered, this agent will be added as the commission " +"agent" +msgstr "" +"Si el usuario vinculado a este socio se pone como vendedor y no se activa " +"ninguna otra regla de comisión, este agente se agregará como el agente de " +"comisión" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_account_move_line +msgid "Journal Item" +msgstr "Apunte contable" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_sale_order_line +msgid "Sales Order Line" +msgstr "Línea de Orden de Ventas" + +#. module: sale_commission_salesman +#: code:addons/sale_commission_salesman/models/res_partner.py:0 +#, python-format +msgid "You can't have a salesman auto-agent without commission." +msgstr "No puede tener un agente automático de ventas sin comisión." From 968f4e54f83575b76cb31f17b26f8cb1073572af Mon Sep 17 00:00:00 2001 From: sinerkiaid <30922659+sinerkiaid@users.noreply.github.com> Date: Tue, 30 Mar 2021 14:29:21 +0200 Subject: [PATCH 06/25] Solution for error #274 Solves [13.0] sale_commission_pricelist - sale_commission_salesman error #274 --- sale_commission_salesman/models/sale_order.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sale_commission_salesman/models/sale_order.py b/sale_commission_salesman/models/sale_order.py index cddbb9665..3e663560b 100644 --- a/sale_commission_salesman/models/sale_order.py +++ b/sale_commission_salesman/models/sale_order.py @@ -15,4 +15,4 @@ def _compute_agent_ids(self): for record in self.filtered(lambda x: x.order_id.partner_id): partner = self.order_id.user_id.partner_id if not record.agent_ids and partner.agent and partner.salesman_as_agent: - record.agent_ids = [(0, 0, self._prepare_agent_vals(partner))] + record.agent_ids = [(0, 0, record._prepare_agent_vals(partner))] From b505dd83448d480ee286ca7216118332094f7ebb Mon Sep 17 00:00:00 2001 From: sinerkiaid <30922659+sinerkiaid@users.noreply.github.com> Date: Fri, 2 Apr 2021 15:11:58 +0200 Subject: [PATCH 07/25] Apply suggestions from code review Co-authored-by: Bhavesh Odedra --- sale_commission_salesman/__manifest__.py | 2 +- sale_commission_salesman/models/sale_order.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sale_commission_salesman/__manifest__.py b/sale_commission_salesman/__manifest__.py index b9ea9acaa..3058e06ff 100644 --- a/sale_commission_salesman/__manifest__.py +++ b/sale_commission_salesman/__manifest__.py @@ -3,7 +3,7 @@ { "name": "Sales commissions from salesman", - "version": "13.0.1.0.0", + "version": "13.0.1.0.1", "author": "Tecnativa, " "Odoo Community Association (OCA)", "category": "Sales", "website": "https://github.com/OCA/commission", diff --git a/sale_commission_salesman/models/sale_order.py b/sale_commission_salesman/models/sale_order.py index 3e663560b..37b9581da 100644 --- a/sale_commission_salesman/models/sale_order.py +++ b/sale_commission_salesman/models/sale_order.py @@ -13,6 +13,6 @@ def _compute_agent_ids(self): """ super()._compute_agent_ids() for record in self.filtered(lambda x: x.order_id.partner_id): - partner = self.order_id.user_id.partner_id + partner = record.order_id.user_id.partner_id if not record.agent_ids and partner.agent and partner.salesman_as_agent: record.agent_ids = [(0, 0, record._prepare_agent_vals(partner))] From 65066dbc325af7ece9b1583fb25aab5f3946f31b Mon Sep 17 00:00:00 2001 From: jabelchi Date: Fri, 4 Jun 2021 08:00:38 +0000 Subject: [PATCH 08/25] Added translation using Weblate (Catalan) --- sale_commission_salesman/i18n/ca.po | 55 +++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 sale_commission_salesman/i18n/ca.po diff --git a/sale_commission_salesman/i18n/ca.po b/sale_commission_salesman/i18n/ca.po new file mode 100644 index 000000000..553e16449 --- /dev/null +++ b/sale_commission_salesman/i18n/ca.po @@ -0,0 +1,55 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * sale_commission_salesman +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 13.0\n" +"Report-Msgid-Bugs-To: \n" +"PO-Revision-Date: 2021-06-04 10:48+0000\n" +"Last-Translator: jabelchi \n" +"Language-Team: none\n" +"Language: ca\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 4.3.2\n" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_res_partner +msgid "Contact" +msgstr "Contacte" + +#. module: sale_commission_salesman +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner__salesman_as_agent +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_users__salesman_as_agent +msgid "Convert salesman into agent" +msgstr "Convertir venedor en agent" + +#. module: sale_commission_salesman +#: model:ir.model.fields,help:sale_commission_salesman.field_res_partner__salesman_as_agent +#: model:ir.model.fields,help:sale_commission_salesman.field_res_users__salesman_as_agent +msgid "" +"If the user linked to this partner is put as salesman and no other " +"commission rule is triggered, this agent will be added as the commission " +"agent" +msgstr "" +"Si l'usuari enllaçat a aquest contacte es posa com a comercial i no s'activa " +"cap altra regla de comissions, aquest agent s'afegirà com a comissionista" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_account_move_line +msgid "Journal Item" +msgstr "Apunt comptable" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_sale_order_line +msgid "Sales Order Line" +msgstr "Línia de comanda de venda" + +#. module: sale_commission_salesman +#: code:addons/sale_commission_salesman/models/res_partner.py:0 +#, python-format +msgid "You can't have a salesman auto-agent without commission." +msgstr "No podeu tenir un comercial auto-agent sense comissió." From e02f1933a34f94982795b22c4da94dae525ddc97 Mon Sep 17 00:00:00 2001 From: aromera Date: Mon, 10 Jan 2022 14:04:46 +0100 Subject: [PATCH 09/25] [MIG] sale_commission_salesman: Migration to 14.0 --- sale_commission_salesman/README.rst | 10 ++++---- sale_commission_salesman/__manifest__.py | 2 +- .../i18n/sale_commission_salesman.pot | 23 ++++++++++++++++++- .../models/account_move.py | 2 +- .../static/description/index.html | 6 ++--- .../tests/test_sale_commission_salesman.py | 2 +- 6 files changed, 33 insertions(+), 12 deletions(-) diff --git a/sale_commission_salesman/README.rst b/sale_commission_salesman/README.rst index e0af1ac39..2caa26fb2 100644 --- a/sale_commission_salesman/README.rst +++ b/sale_commission_salesman/README.rst @@ -14,13 +14,13 @@ Sales commissions from salesman :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fcommission-lightgray.png?logo=github - :target: https://github.com/OCA/commission/tree/13.0/sale_commission_salesman + :target: https://github.com/OCA/commission/tree/14.0/sale_commission_salesman :alt: OCA/commission .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/commission-13-0/commission-13-0-sale_commission_salesman + :target: https://translation.odoo-community.org/projects/commission-14-0/commission-14-0-sale_commission_salesman :alt: Translate me on Weblate .. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/165/13.0 + :target: https://runbot.odoo-community.org/runbot/165/14.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -64,7 +64,7 @@ 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 `_. +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -101,6 +101,6 @@ 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/commission `_ project on GitHub. +This module is part of the `OCA/commission `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/sale_commission_salesman/__manifest__.py b/sale_commission_salesman/__manifest__.py index 3058e06ff..3dd37f0cf 100644 --- a/sale_commission_salesman/__manifest__.py +++ b/sale_commission_salesman/__manifest__.py @@ -3,7 +3,7 @@ { "name": "Sales commissions from salesman", - "version": "13.0.1.0.1", + "version": "14.0.1.0.0", "author": "Tecnativa, " "Odoo Community Association (OCA)", "category": "Sales", "website": "https://github.com/OCA/commission", diff --git a/sale_commission_salesman/i18n/sale_commission_salesman.pot b/sale_commission_salesman/i18n/sale_commission_salesman.pot index 2a4bb22e6..646cfc674 100644 --- a/sale_commission_salesman/i18n/sale_commission_salesman.pot +++ b/sale_commission_salesman/i18n/sale_commission_salesman.pot @@ -4,7 +4,7 @@ # msgid "" msgstr "" -"Project-Id-Version: Odoo Server 13.0\n" +"Project-Id-Version: Odoo Server 14.0\n" "Report-Msgid-Bugs-To: \n" "Last-Translator: \n" "Language-Team: \n" @@ -24,6 +24,20 @@ msgstr "" msgid "Convert salesman into agent" msgstr "" +#. module: sale_commission_salesman +#: model:ir.model.fields,field_description:sale_commission_salesman.field_account_move_line__display_name +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner__display_name +#: model:ir.model.fields,field_description:sale_commission_salesman.field_sale_order_line__display_name +msgid "Display Name" +msgstr "" + +#. module: sale_commission_salesman +#: model:ir.model.fields,field_description:sale_commission_salesman.field_account_move_line__id +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner__id +#: model:ir.model.fields,field_description:sale_commission_salesman.field_sale_order_line__id +msgid "ID" +msgstr "" + #. module: sale_commission_salesman #: model:ir.model.fields,help:sale_commission_salesman.field_res_partner__salesman_as_agent #: model:ir.model.fields,help:sale_commission_salesman.field_res_users__salesman_as_agent @@ -38,6 +52,13 @@ msgstr "" msgid "Journal Item" msgstr "" +#. module: sale_commission_salesman +#: model:ir.model.fields,field_description:sale_commission_salesman.field_account_move_line____last_update +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner____last_update +#: model:ir.model.fields,field_description:sale_commission_salesman.field_sale_order_line____last_update +msgid "Last Modified on" +msgstr "" + #. module: sale_commission_salesman #: model:ir.model,name:sale_commission_salesman.model_sale_order_line msgid "Sales Order Line" diff --git a/sale_commission_salesman/models/account_move.py b/sale_commission_salesman/models/account_move.py index e0028f089..4238c982a 100644 --- a/sale_commission_salesman/models/account_move.py +++ b/sale_commission_salesman/models/account_move.py @@ -14,7 +14,7 @@ def _compute_agent_ids(self): super()._compute_agent_ids() for record in self.filtered( lambda x: x.move_id.partner_id - and x.move_id.type[:3] == "out" + and x.move_id.move_type[:3] == "out" and x.product_id and not x.agent_ids ): diff --git a/sale_commission_salesman/static/description/index.html b/sale_commission_salesman/static/description/index.html index 2a0da26f1..27104d0bc 100644 --- a/sale_commission_salesman/static/description/index.html +++ b/sale_commission_salesman/static/description/index.html @@ -367,7 +367,7 @@

Sales commissions from salesman

!! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> -

Beta License: AGPL-3 OCA/commission Translate me on Weblate Try me on Runbot

+

Beta License: AGPL-3 OCA/commission Translate me on Weblate Try me on Runbot

This module extends the functionality of sale_commission to allow you to auto-populate salesmen as commission agents without setting explicitly them on the customer.

@@ -415,7 +415,7 @@

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.

+feedback.

Do not contact contributors directly about support or help with technical issues.

@@ -448,7 +448,7 @@

Maintainers

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/commission project on GitHub.

+

This module is part of the OCA/commission project on GitHub.

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

diff --git a/sale_commission_salesman/tests/test_sale_commission_salesman.py b/sale_commission_salesman/tests/test_sale_commission_salesman.py index cc9a8ac17..377cefde4 100644 --- a/sale_commission_salesman/tests/test_sale_commission_salesman.py +++ b/sale_commission_salesman/tests/test_sale_commission_salesman.py @@ -43,7 +43,7 @@ def setUpClass(cls): { "partner_id": cls.partner.id, "invoice_user_id": cls.salesman.id, - "type": "out_invoice", + "move_type": "out_invoice", } ) From 5477e5b4789052ccc595785778139b74121a35ca Mon Sep 17 00:00:00 2001 From: Francesco Foresti Date: Wed, 21 Dec 2022 10:48:09 +0000 Subject: [PATCH 10/25] Added translation using Weblate (Italian) --- sale_commission_salesman/i18n/it.po | 74 +++++++++++++++++++++++++++++ 1 file changed, 74 insertions(+) create mode 100644 sale_commission_salesman/i18n/it.po diff --git a/sale_commission_salesman/i18n/it.po b/sale_commission_salesman/i18n/it.po new file mode 100644 index 000000000..2fecdc9d6 --- /dev/null +++ b/sale_commission_salesman/i18n/it.po @@ -0,0 +1,74 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * sale_commission_salesman +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 14.0\n" +"Report-Msgid-Bugs-To: \n" +"PO-Revision-Date: 2022-12-21 13:44+0000\n" +"Last-Translator: Francesco Foresti \n" +"Language-Team: none\n" +"Language: it\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 4.14.1\n" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_res_partner +msgid "Contact" +msgstr "Contatto" + +#. module: sale_commission_salesman +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner__salesman_as_agent +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_users__salesman_as_agent +msgid "Convert salesman into agent" +msgstr "" + +#. module: sale_commission_salesman +#: model:ir.model.fields,field_description:sale_commission_salesman.field_account_move_line__display_name +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner__display_name +#: model:ir.model.fields,field_description:sale_commission_salesman.field_sale_order_line__display_name +msgid "Display Name" +msgstr "" + +#. module: sale_commission_salesman +#: model:ir.model.fields,field_description:sale_commission_salesman.field_account_move_line__id +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner__id +#: model:ir.model.fields,field_description:sale_commission_salesman.field_sale_order_line__id +msgid "ID" +msgstr "" + +#. module: sale_commission_salesman +#: model:ir.model.fields,help:sale_commission_salesman.field_res_partner__salesman_as_agent +#: model:ir.model.fields,help:sale_commission_salesman.field_res_users__salesman_as_agent +msgid "" +"If the user linked to this partner is put as salesman and no other " +"commission rule is triggered, this agent will be added as the commission " +"agent" +msgstr "" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_account_move_line +msgid "Journal Item" +msgstr "" + +#. module: sale_commission_salesman +#: model:ir.model.fields,field_description:sale_commission_salesman.field_account_move_line____last_update +#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner____last_update +#: model:ir.model.fields,field_description:sale_commission_salesman.field_sale_order_line____last_update +msgid "Last Modified on" +msgstr "" + +#. module: sale_commission_salesman +#: model:ir.model,name:sale_commission_salesman.model_sale_order_line +msgid "Sales Order Line" +msgstr "" + +#. module: sale_commission_salesman +#: code:addons/sale_commission_salesman/models/res_partner.py:0 +#, python-format +msgid "You can't have a salesman auto-agent without commission." +msgstr "" From a2319962fef30fce28646ba16ef158278e43f7a2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luis=20Ernesto=20Garc=C3=ADa=20Medina?= Date: Thu, 23 Feb 2023 17:40:35 -0600 Subject: [PATCH 11/25] [MIG] sale_commission_salesman: Migration to 15.0 --- sale_commission_salesman/README.rst | 15 +- sale_commission_salesman/__manifest__.py | 2 +- .../i18n/sale_commission_salesman.pot | 23 +- .../models/account_move.py | 3 +- sale_commission_salesman/models/sale_order.py | 3 +- sale_commission_salesman/readme/ROADMAP.rst | 1 + .../static/description/icon.png | Bin 17671 -> 7968 bytes .../static/description/icon.svg | 2882 +---------------- .../static/description/index.html | 37 +- .../tests/test_sale_commission_salesman.py | 6 +- .../views/res_partner_views.xml | 2 +- 11 files changed, 193 insertions(+), 2781 deletions(-) create mode 100644 sale_commission_salesman/readme/ROADMAP.rst diff --git a/sale_commission_salesman/README.rst b/sale_commission_salesman/README.rst index 2caa26fb2..6a9a73ee8 100644 --- a/sale_commission_salesman/README.rst +++ b/sale_commission_salesman/README.rst @@ -14,13 +14,13 @@ Sales commissions from salesman :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fcommission-lightgray.png?logo=github - :target: https://github.com/OCA/commission/tree/14.0/sale_commission_salesman + :target: https://github.com/OCA/commission/tree/15.0/sale_commission_salesman :alt: OCA/commission .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/commission-14-0/commission-14-0-sale_commission_salesman + :target: https://translation.odoo-community.org/projects/commission-15-0/commission-15-0-sale_commission_salesman :alt: Translate me on Weblate .. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/165/14.0 + :target: https://runbot.odoo-community.org/runbot/165/15.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -58,13 +58,18 @@ To use this module, you need to: #. Add a line in the quotation, and you will see the salesman populated as commission agent. +Known issues / Roadmap +====================== + +- This module can be split into 2: account_commission_salesman and sale_commission_salesman. + 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 `_. +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -101,6 +106,6 @@ 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/commission `_ project on GitHub. +This module is part of the `OCA/commission `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/sale_commission_salesman/__manifest__.py b/sale_commission_salesman/__manifest__.py index 3dd37f0cf..6a44af52b 100644 --- a/sale_commission_salesman/__manifest__.py +++ b/sale_commission_salesman/__manifest__.py @@ -3,7 +3,7 @@ { "name": "Sales commissions from salesman", - "version": "14.0.1.0.0", + "version": "15.0.1.0.0", "author": "Tecnativa, " "Odoo Community Association (OCA)", "category": "Sales", "website": "https://github.com/OCA/commission", diff --git a/sale_commission_salesman/i18n/sale_commission_salesman.pot b/sale_commission_salesman/i18n/sale_commission_salesman.pot index 646cfc674..6a81efd62 100644 --- a/sale_commission_salesman/i18n/sale_commission_salesman.pot +++ b/sale_commission_salesman/i18n/sale_commission_salesman.pot @@ -4,7 +4,7 @@ # msgid "" msgstr "" -"Project-Id-Version: Odoo Server 14.0\n" +"Project-Id-Version: Odoo Server 15.0\n" "Report-Msgid-Bugs-To: \n" "Last-Translator: \n" "Language-Team: \n" @@ -24,20 +24,6 @@ msgstr "" msgid "Convert salesman into agent" msgstr "" -#. module: sale_commission_salesman -#: model:ir.model.fields,field_description:sale_commission_salesman.field_account_move_line__display_name -#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner__display_name -#: model:ir.model.fields,field_description:sale_commission_salesman.field_sale_order_line__display_name -msgid "Display Name" -msgstr "" - -#. module: sale_commission_salesman -#: model:ir.model.fields,field_description:sale_commission_salesman.field_account_move_line__id -#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner__id -#: model:ir.model.fields,field_description:sale_commission_salesman.field_sale_order_line__id -msgid "ID" -msgstr "" - #. module: sale_commission_salesman #: model:ir.model.fields,help:sale_commission_salesman.field_res_partner__salesman_as_agent #: model:ir.model.fields,help:sale_commission_salesman.field_res_users__salesman_as_agent @@ -52,13 +38,6 @@ msgstr "" msgid "Journal Item" msgstr "" -#. module: sale_commission_salesman -#: model:ir.model.fields,field_description:sale_commission_salesman.field_account_move_line____last_update -#: model:ir.model.fields,field_description:sale_commission_salesman.field_res_partner____last_update -#: model:ir.model.fields,field_description:sale_commission_salesman.field_sale_order_line____last_update -msgid "Last Modified on" -msgstr "" - #. module: sale_commission_salesman #: model:ir.model,name:sale_commission_salesman.model_sale_order_line msgid "Sales Order Line" diff --git a/sale_commission_salesman/models/account_move.py b/sale_commission_salesman/models/account_move.py index 4238c982a..ea33b7203 100644 --- a/sale_commission_salesman/models/account_move.py +++ b/sale_commission_salesman/models/account_move.py @@ -11,7 +11,7 @@ def _compute_agent_ids(self): """Add salesman agent if configured so and no other commission already populated. """ - super()._compute_agent_ids() + result = super()._compute_agent_ids() for record in self.filtered( lambda x: x.move_id.partner_id and x.move_id.move_type[:3] == "out" @@ -21,3 +21,4 @@ def _compute_agent_ids(self): partner = self.move_id.invoice_user_id.partner_id if partner.agent and partner.salesman_as_agent: record.agent_ids = [(0, 0, self._prepare_agent_vals(partner))] + return result diff --git a/sale_commission_salesman/models/sale_order.py b/sale_commission_salesman/models/sale_order.py index 37b9581da..822df325e 100644 --- a/sale_commission_salesman/models/sale_order.py +++ b/sale_commission_salesman/models/sale_order.py @@ -11,8 +11,9 @@ def _compute_agent_ids(self): """Add salesman agent if configured so and no other commission already populated. """ - super()._compute_agent_ids() + result = super()._compute_agent_ids() for record in self.filtered(lambda x: x.order_id.partner_id): partner = record.order_id.user_id.partner_id if not record.agent_ids and partner.agent and partner.salesman_as_agent: record.agent_ids = [(0, 0, record._prepare_agent_vals(partner))] + return result diff --git a/sale_commission_salesman/readme/ROADMAP.rst b/sale_commission_salesman/readme/ROADMAP.rst new file mode 100644 index 000000000..dd5698294 --- /dev/null +++ b/sale_commission_salesman/readme/ROADMAP.rst @@ -0,0 +1 @@ +- This module can be split into 2: account_commission_salesman and sale_commission_salesman. diff --git a/sale_commission_salesman/static/description/icon.png b/sale_commission_salesman/static/description/icon.png index 7ce73f84986909d76a2189c08edbbd3583680187..3be6cf23a07ae5c37aec612c151b1dd74f292b52 100644 GIT binary patch literal 7968 zcmX9@byQSe7ah7r7+`>*gpr1!1nKS?NeQJJ>Fyp%x{(l2LO@y&5QYW;2c$uyySu{= zf8QVX-M!vAcfWJi-S4jb&Wq7_srUq+3LgLfJW*DX(|Vla{taC0$7@xGw8Z0t=b~ib z4gk&I4)Hz_^j^*ywmtv$TW+^hiJ-rihxPWJ8=W-eA-&Tck22VztJz|%@) zIcXiA+PcRe@oCr}k4fJTNks}n~B!eEAAS&%R&tC@eeG1S+QgEEhR z7^!&sJ}1llk&YmWPkX@i&OJQ6QD;*5CVZtx|Ka9u zNaSssJP0a!@J6fewl?X-4wr>c6$K!0&0Pl9QeL4tB<)+FrS3+kIq>*K>xgBOgXsZ0 zHe@%>U<^p}1A)phj1LuIWKR!X99~#x7VaT83m5BjPqn&uuqR)J5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ZoW>SG0`Te^JcP+s;V~1=2SYBQx09aaD!ph1D0l;8zj({(s-+z@} zfBg~x$8h{OaN)w`+5GOu>gww5Tn`*LV5QAp!AD02?G*q=j;z_)v%t}#M-BKbhQnh9 z0B - - + inkscape:export-xdpi="192" + inkscape:export-ydpi="192" + inkscape:version="1.1.2 (0a00cf5339, 2022-02-04)" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:xlink="http://www.w3.org/1999/xlink" + xmlns="http://www.w3.org/2000/svg" + xmlns:svg="http://www.w3.org/2000/svg"> + + + id="defs7"> + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + id="filter3869" + x="-0.028125" + y="-0.031229825" + width="1.0679687" + height="1.0754721"> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + fill="none" + fill-rule="nonzero" + stroke="none" + stroke-width="1" + stroke-linecap="butt" + stroke-linejoin="miter" + stroke-miterlimit="10" + stroke-dasharray="" + stroke-dashoffset="0" + font-family="none" + font-weight="none" + font-size="none" + text-anchor="none" + style="mix-blend-mode: normal" + id="g15"> + + + + + + + + + + - - - - image/svg+xml - - - - - Openclipart - - - Pile of Golden Coins - 2010-04-09T03:27:45 - A pile of hypothetical golden coins, drawn in Inkscape. - https://openclipart.org/detail/43969/pile-of-golden-coins-by-j_alves - - - J_Alves - - - - - coin - currency - gold - money - thaler - - - - - - - - - - diff --git a/sale_commission_salesman/static/description/index.html b/sale_commission_salesman/static/description/index.html index 27104d0bc..ee60fe610 100644 --- a/sale_commission_salesman/static/description/index.html +++ b/sale_commission_salesman/static/description/index.html @@ -367,7 +367,7 @@

Sales commissions from salesman

!! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> -

Beta License: AGPL-3 OCA/commission Translate me on Weblate Try me on Runbot

+

Beta License: AGPL-3 OCA/commission Translate me on Weblate Try me on Runbot

This module extends the functionality of sale_commission to allow you to auto-populate salesmen as commission agents without setting explicitly them on the customer.

@@ -378,12 +378,13 @@

Sales commissions from salesman

  • Configuration
  • Usage
  • -
  • Bug Tracker
  • -
  • Credits @@ -410,24 +411,30 @@

    Usage

    commission agent.
  • +
    +

    Known issues / Roadmap

    +
      +
    • This module can be split into 2: account_commission_salesman and sale_commission_salesman.
    • +
    +
    -

    Bug Tracker

    +

    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.

    +feedback.

    Do not contact contributors directly about support or help with technical issues.

    -

    Credits

    +

    Credits

    -

    Authors

    +

    Authors

    • Tecnativa
    -

    Contributors

    +

    Contributors

    -

    Other credits

    +

    Other credits

    -

    Maintainers

    +

    Maintainers

    This module is maintained by the OCA.

    Odoo Community Association

    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/commission project on GitHub.

    +

    This module is part of the OCA/commission project on GitHub.

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

    diff --git a/sale_commission_salesman/tests/test_sale_commission_salesman.py b/sale_commission_salesman/tests/test_sale_commission_salesman.py index 377cefde4..86bd5f290 100644 --- a/sale_commission_salesman/tests/test_sale_commission_salesman.py +++ b/sale_commission_salesman/tests/test_sale_commission_salesman.py @@ -2,17 +2,17 @@ # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). from odoo import exceptions -from odoo.tests.common import Form, SavepointCase +from odoo.tests import Form, TransactionCase -class TestSaleCommissionSalesman(SavepointCase): +class TestSaleCommissionSalesman(TransactionCase): @classmethod def setUpClass(cls): super().setUpClass() cls.product = cls.env["product.product"].create( {"name": "Test Product 1", "list_price": 100} ) - SaleCommission = cls.env["sale.commission"] + SaleCommission = cls.env["commission"] cls.commission_1 = SaleCommission.create( {"name": "1% commission", "fix_qty": 1.0} ) diff --git a/sale_commission_salesman/views/res_partner_views.xml b/sale_commission_salesman/views/res_partner_views.xml index 055161624..28a8bc2a8 100644 --- a/sale_commission_salesman/views/res_partner_views.xml +++ b/sale_commission_salesman/views/res_partner_views.xml @@ -4,7 +4,7 @@ res.partner - + From 0059c97dd1b840d73a6f6ef1d1be05b792bef98d Mon Sep 17 00:00:00 2001 From: "Omar (Comunitea)" Date: Thu, 25 May 2023 01:20:37 +0200 Subject: [PATCH 12/25] [MIG] sale_commission_salesman: Migration to 16.0 --- sale_commission_salesman/__manifest__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sale_commission_salesman/__manifest__.py b/sale_commission_salesman/__manifest__.py index 6a44af52b..7d186350b 100644 --- a/sale_commission_salesman/__manifest__.py +++ b/sale_commission_salesman/__manifest__.py @@ -3,7 +3,7 @@ { "name": "Sales commissions from salesman", - "version": "15.0.1.0.0", + "version": "16.0.1.0.0", "author": "Tecnativa, " "Odoo Community Association (OCA)", "category": "Sales", "website": "https://github.com/OCA/commission", From d50affc473f91b050b29967e57463d96f9144cf7 Mon Sep 17 00:00:00 2001 From: oca-ci Date: Tue, 22 Aug 2023 10:50:31 +0000 Subject: [PATCH 13/25] [UPD] Update sale_commission_salesman.pot --- sale_commission_salesman/i18n/sale_commission_salesman.pot | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sale_commission_salesman/i18n/sale_commission_salesman.pot b/sale_commission_salesman/i18n/sale_commission_salesman.pot index 6a81efd62..5e0a280ea 100644 --- a/sale_commission_salesman/i18n/sale_commission_salesman.pot +++ b/sale_commission_salesman/i18n/sale_commission_salesman.pot @@ -4,7 +4,7 @@ # msgid "" msgstr "" -"Project-Id-Version: Odoo Server 15.0\n" +"Project-Id-Version: Odoo Server 16.0\n" "Report-Msgid-Bugs-To: \n" "Last-Translator: \n" "Language-Team: \n" @@ -44,6 +44,7 @@ msgid "Sales Order Line" msgstr "" #. module: sale_commission_salesman +#. odoo-python #: code:addons/sale_commission_salesman/models/res_partner.py:0 #, python-format msgid "You can't have a salesman auto-agent without commission." From 663d92c9dfa568a47399f015c91c9ab0ee5232f1 Mon Sep 17 00:00:00 2001 From: OCA-git-bot Date: Tue, 22 Aug 2023 10:54:00 +0000 Subject: [PATCH 14/25] [UPD] README.rst --- sale_commission_salesman/README.rst | 10 +++++----- sale_commission_salesman/static/description/index.html | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/sale_commission_salesman/README.rst b/sale_commission_salesman/README.rst index 6a9a73ee8..856167439 100644 --- a/sale_commission_salesman/README.rst +++ b/sale_commission_salesman/README.rst @@ -14,13 +14,13 @@ Sales commissions from salesman :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fcommission-lightgray.png?logo=github - :target: https://github.com/OCA/commission/tree/15.0/sale_commission_salesman + :target: https://github.com/OCA/commission/tree/16.0/sale_commission_salesman :alt: OCA/commission .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/commission-15-0/commission-15-0-sale_commission_salesman + :target: https://translation.odoo-community.org/projects/commission-16-0/commission-16-0-sale_commission_salesman :alt: Translate me on Weblate .. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/165/15.0 + :target: https://runbot.odoo-community.org/runbot/165/16.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -69,7 +69,7 @@ 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 `_. +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -106,6 +106,6 @@ 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/commission `_ project on GitHub. +This module is part of the `OCA/commission `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/sale_commission_salesman/static/description/index.html b/sale_commission_salesman/static/description/index.html index ee60fe610..a8c3de65a 100644 --- a/sale_commission_salesman/static/description/index.html +++ b/sale_commission_salesman/static/description/index.html @@ -367,7 +367,7 @@

    Sales commissions from salesman

    !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> -

    Beta License: AGPL-3 OCA/commission Translate me on Weblate Try me on Runbot

    +

    Beta License: AGPL-3 OCA/commission Translate me on Weblate Try me on Runbot

    This module extends the functionality of sale_commission to allow you to auto-populate salesmen as commission agents without setting explicitly them on the customer.

    @@ -422,7 +422,7 @@

    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.

    +feedback.

    Do not contact contributors directly about support or help with technical issues.

    @@ -455,7 +455,7 @@

    Maintainers

    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/commission project on GitHub.

    +

    This module is part of the OCA/commission project on GitHub.

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

    From e233cac4145653faa9608b920743572637ea97c6 Mon Sep 17 00:00:00 2001 From: OCA-git-bot Date: Sun, 3 Sep 2023 11:59:46 +0000 Subject: [PATCH 15/25] [UPD] README.rst --- sale_commission_salesman/README.rst | 15 +++--- .../static/description/index.html | 50 ++++++++++--------- 2 files changed, 35 insertions(+), 30 deletions(-) diff --git a/sale_commission_salesman/README.rst b/sale_commission_salesman/README.rst index 856167439..3dcabc55d 100644 --- a/sale_commission_salesman/README.rst +++ b/sale_commission_salesman/README.rst @@ -2,10 +2,13 @@ Sales commissions from salesman =============================== -.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! +.. + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! source digest: sha256:63e532cf8e93589c8c91d5903713b79d7d760883004843c2471c51c0ca350e3f + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! .. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png :target: https://odoo-community.org/page/development-status @@ -19,11 +22,11 @@ Sales commissions from salesman .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png :target: https://translation.odoo-community.org/projects/commission-16-0/commission-16-0-sale_commission_salesman :alt: Translate me on Weblate -.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/165/16.0 - :alt: Try me on Runbot +.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png + :target: https://runboat.odoo-community.org/builds?repo=OCA/commission&target_branch=16.0 + :alt: Try me on Runboat -|badge1| |badge2| |badge3| |badge4| |badge5| +|badge1| |badge2| |badge3| |badge4| |badge5| This module extends the functionality of `sale_commission` to allow you to auto-populate salesmen as commission agents without setting explicitly them @@ -68,7 +71,7 @@ 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 +If you spotted it first, help us to smash it by providing a detailed and welcomed `feedback `_. Do not contact contributors directly about support or help with technical issues. diff --git a/sale_commission_salesman/static/description/index.html b/sale_commission_salesman/static/description/index.html index a8c3de65a..2c635dd2f 100644 --- a/sale_commission_salesman/static/description/index.html +++ b/sale_commission_salesman/static/description/index.html @@ -1,20 +1,20 @@ - + - + Sales commissions from salesman