diff --git a/account_commission/README.rst b/account_commission/README.rst index 712ee6a..0706f01 100644 --- a/account_commission/README.rst +++ b/account_commission/README.rst @@ -2,10 +2,13 @@ Account commissions =================== -.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! +.. + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! source digest: sha256:0e0fd65289aeddebd4759567566b4e2b2221c76b50dedc95e7da15c899e13fec + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! .. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png :target: https://odoo-community.org/page/development-status @@ -19,11 +22,11 @@ Account commissions .. |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-account_commission :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 - :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=15.0 + :alt: Try me on Runboat -|badge1| |badge2| |badge3| |badge4| |badge5| +|badge1| |badge2| |badge3| |badge4| |badge5| This module adds the function to calculate commissions in invoices (account moves). @@ -44,7 +47,9 @@ For selecting invoice status in commissions: #. Edit or create a new record to select the invoice status for settling the commissions. * **Invoice Based**: Commissions are settled when the invoice is issued. - * **Payment Based**: Commissions are settled when the invoice is paid. + * **Payment Based**: Commissions are settled when the invoice is paid or refunded. + Note that when refunding an invoice, the corresponding reversed commission will + be settled as well, resulting in a 0 net commission between both operations. Usage ===== @@ -92,7 +97,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. @@ -117,11 +122,13 @@ Contributors * Oihane Crucelaegui * Nicola Malcontenti * Aitor Bouzas +* Alexei Rivera * `Tecnativa `__: * Pedro M. Baeza * Manuel Calero + * Sergio Teruel * `Quartile `__: diff --git a/account_commission/__manifest__.py b/account_commission/__manifest__.py index c87663d..8fc90a1 100644 --- a/account_commission/__manifest__.py +++ b/account_commission/__manifest__.py @@ -3,7 +3,7 @@ # Copyright 2014-2022 Tecnativa - Pedro M. Baeza { "name": "Account commissions", - "version": "15.0.2.1.0", + "version": "15.0.3.3.2", "author": "Tecnativa, Odoo Community Association (OCA)", "category": "Sales Management", "license": "AGPL-3", diff --git a/account_commission/i18n/account_commission.pot b/account_commission/i18n/account_commission.pot new file mode 100644 index 0000000..725fcd9 --- /dev/null +++ b/account_commission/i18n/account_commission.pot @@ -0,0 +1,575 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * account_commission +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 15.0\n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: \n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__quantity +msgid "# of Qty" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.commission_make_invoice_form +msgid "(keep empty for invoicing all the pending settlements)" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Settlement invoice:" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__agent_id +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__agent_id +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Agent" +msgstr "" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_account_invoice_line_agent +msgid "Agent detail of commission line in invoice lines" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_bank_statement_line__partner_agent_ids +#: model:ir.model.fields,field_description:account_commission.field_account_move__partner_agent_ids +#: model:ir.model.fields,field_description:account_commission.field_account_payment__partner_agent_ids +msgid "Agents" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_move_line__agent_ids +msgid "Agents & commissions" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_account_move_line__agent_ids +msgid "Agents/Commissions related to the invoice line." +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__amount +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Amount" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_move_line__any_settled +msgid "Any Settled" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__balance +msgid "Balance" +msgstr "" + +#. module: account_commission +#: code:addons/account_commission/models/commission_settlement.py:0 +#, python-format +msgid "Cannot cancel an invoiced settlement." +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__categ_id +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Category of Product" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_move_line__commission_free +msgid "Comm. free" +msgstr "" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__commission_id +#: model:ir.model.fields,field_description:account_commission.field_account_move_line__commission_status +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__commission_id +msgid "Commission" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__amount +msgid "Commission Amount" +msgstr "" + +#. module: account_commission +#: model:ir.actions.act_window,name:account_commission.action_invoice_commission_analysis_report +#: model:ir.ui.menu,name:account_commission.menu_invoice_commissions_analysis +msgid "Commission Analysis" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_bank_statement_line__commission_total +#: model:ir.model.fields,field_description:account_commission.field_account_move__commission_total +#: model:ir.model.fields,field_description:account_commission.field_account_payment__commission_total +#: model:ir.ui.menu,name:account_commission.menu_invoicing_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_move_line_form +msgid "Commissions" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__company_id +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__company_id +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__company_id +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Company" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_commission_make_invoice__company_id +msgid "Company related to this journal" +msgstr "" + +#. module: account_commission +#: model:ir.actions.act_window,name:account_commission.action_commission_make_invoices +#: model:ir.ui.menu,name:account_commission.menu_invoicing_settlements_make_invoice +msgid "Create Commission Invoices" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.commission_make_invoice_form +msgid "Create invoices" +msgstr "" + +#. module: account_commission +#: code:addons/account_commission/wizards/wizard_invoice.py:0 +#, python-format +msgid "Created Invoices" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__create_uid +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__create_uid +msgid "Created by" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__create_date +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__create_date +msgid "Created on" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__currency_id +msgid "Currency" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Customer" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__date +msgid "Date" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Description" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__display_name +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__display_name +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__display_name +msgid "Display Name" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Draft" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Extended Filters" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__from_settlement +msgid "From Settlement" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_settlement__invoice_id +msgid "Generated Invoice" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_settlement__invoice_line_ids +msgid "Generated invoice lines" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Group By" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__grouped +msgid "Group invoices" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__id +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__id +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__id +msgid "ID" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__invoice_id +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Invoice" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_settlement_line__invoice_agent_line_id +msgid "Invoice Agent Line" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields.selection,name:account_commission.selection__commission__invoice_state__open +msgid "Invoice Based" +msgstr "" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_invoice_commission_analysis_report +msgid "Invoice Commission Analysis Report" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__date_invoice +msgid "Invoice Date" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__invoice_line_id +msgid "Invoice Line" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Invoice Month" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission__invoice_state +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__invoice_state +msgid "Invoice Status" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__invoice_date +msgid "Invoice date" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields.selection,name:account_commission.selection__commission_settlement__state__except_invoice +msgid "Invoice exception" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields.selection,name:account_commission.selection__commission_settlement__state__invoiced +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Invoiced" +msgstr "" + +#. module: account_commission +#: model:ir.actions.act_window,name:account_commission.action_invoicing_commission_settlement +#: model:ir.ui.menu,name:account_commission.menu_invoicing_settlements +msgid "Invoices Settlements" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__journal_id +msgid "Journal" +msgstr "" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_account_move +msgid "Journal Entry" +msgstr "" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_account_move_line +msgid "Journal Item" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent____last_update +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice____last_update +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report____last_update +msgid "Last Modified on" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__write_uid +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__write_uid +msgid "Last Updated by" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__write_date +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__write_date +msgid "Last Updated on" +msgstr "" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_commission_settlement_line +msgid "Line of a commission settlement" +msgstr "" + +#. module: account_commission +#: code:addons/account_commission/models/commission_settlement.py:0 +#: model_terms:ir.ui.view,arch_db:account_commission.view_settlement_form +#, python-format +msgid "Make invoice" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.commission_make_invoice_form +msgid "Make invoices" +msgstr "" + +#. module: account_commission +#: model:res.groups,name:account_commission.group_invoicing_commission +msgid "Manage invoices commissions" +msgstr "" + +#. module: account_commission +#: code:addons/account_commission/wizards/wizard_invoice.py:0 +#, python-format +msgid "No valid settlements to invoice." +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Not Settled" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__object_id +msgid "Parent" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__partner_id +msgid "Partner" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields.selection,name:account_commission.selection__commission__invoice_state__paid +msgid "Payment Based" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__percentage +msgid "Percentage of commission" +msgstr "" + +#. module: account_commission +#: code:addons/account_commission/models/commission_settlement.py:0 +#, python-format +msgid "Period: from %(date_from)s to %(date_to)s" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_move_line__product_id +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__product_id +msgid "Product" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__product_id +msgid "Product for invoicing" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Quantity" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_move_form +msgid "Regenerate agents" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_settlement_form +msgid "Reset to draft" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields.selection,name:account_commission.selection__commission_make_settle__settlement_type__sale_invoice +#: model:ir.model.fields.selection,name:account_commission.selection__commission_settlement__settlement_type__sale_invoice +msgid "Sales Invoices" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_commission__invoice_state +msgid "" +"Select the invoice status for settling the commissions:\n" +"* 'Invoice Based': Commissions are settled when the invoice is issued.\n" +"* 'Payment Based': Commissions are settled when the invoice is paid (or refunded)." +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__settled +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__settled +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Settled" +msgstr "" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_commission_settlement +#: model:ir.model.fields,field_description:account_commission.field_account_move_line__settlement_id +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__settlement_ids +msgid "Settlement" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_bank_statement_line__settlement_count +#: model:ir.model.fields,field_description:account_commission.field_account_move__settlement_count +#: model:ir.model.fields,field_description:account_commission.field_account_payment__settlement_count +msgid "Settlement Count" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__settlement_line_ids +msgid "Settlement Line" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_make_settle__settlement_type +#: model:ir.model.fields,field_description:account_commission.field_commission_settlement__settlement_type +msgid "Settlement Type" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_account_move_line__settlement_id +msgid "Settlement that generates this invoice line" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_bank_statement_line__settlement_ids +#: model:ir.model.fields,field_description:account_commission.field_account_move__settlement_ids +#: model:ir.model.fields,field_description:account_commission.field_account_payment__settlement_ids +#: model_terms:ir.ui.view,arch_db:account_commission.commission_make_invoice_form +#: model_terms:ir.ui.view,arch_db:account_commission.view_in_invoice_bill_tree_inherit +#: model_terms:ir.ui.view,arch_db:account_commission.view_move_form +msgid "Settlements" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_settlement_line__invoice_line_id +msgid "Source invoice line" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_settlement__state +msgid "State" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Status" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__price_subtotal +msgid "Subtotal" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_account_invoice_line_agent__invoice_id +msgid "The move of this entry line." +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_commission_settlement__settlement_type +msgid "" +"The source of the settlement, e.g. 'Sales invoice', 'Sales order', 'Purchase" +" order'..." +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "This Year" +msgstr "" + +#. module: account_commission +#: model_terms:ir.actions.act_window,help:account_commission.action_invoice_commission_analysis_report +msgid "" +"This report performs analysis on your commissions added in invoice lines. " +"You can check the amount and lines that will be settled by date, product, " +"product category, aget, etc. Use this report to perform analysis on invoice " +"lines agents not beeing settled yet." +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__price_unit +msgid "Unit Price" +msgstr "" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__uom_id +msgid "Unit of Measure" +msgstr "" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_commission_make_invoice +msgid "Wizard for making an invoice from a settlement" +msgstr "" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_commission_make_settle +msgid "Wizard for settling commissions" +msgstr "" + +#. module: account_commission +#: code:addons/account_commission/models/account_move.py:0 +#, python-format +msgid "You can't cancel an invoice with settled lines" +msgstr "" + +#. module: account_commission +#: code:addons/account_commission/models/commission_settlement.py:0 +#, python-format +msgid "You can't delete invoiced settlements." +msgstr "" + +#. module: account_commission +#: code:addons/account_commission/models/account_move.py:0 +#, python-format +msgid "You can't modify a settled line" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.commission_make_invoice_form +msgid "_Cancel" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_graph +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_pivot +msgid "invoice Commission Analysis" +msgstr "" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "invoices Commission Analysis" +msgstr "" diff --git a/account_commission/i18n/es.po b/account_commission/i18n/es.po new file mode 100644 index 0000000..11d3320 --- /dev/null +++ b/account_commission/i18n/es.po @@ -0,0 +1,590 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * account_commission +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 15.0\n" +"Report-Msgid-Bugs-To: \n" +"POT-Creation-Date: \n" +"PO-Revision-Date: 2024-03-20 21:36+0000\n" +"Last-Translator: Ivorra78 \n" +"Language-Team: none\n" +"Language: es\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=2; plural=n != 1;\n" +"X-Generator: Weblate 4.17\n" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__quantity +msgid "# of Qty" +msgstr "# de Cantd" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.commission_make_invoice_form +msgid "(keep empty for invoicing all the pending settlements)" +msgstr "(dejar vacío para facturar todas las liquidaciones pendientes)" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Settlement invoice:" +msgstr "Factura de liquidación:" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__agent_id +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__agent_id +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Agent" +msgstr "Agente" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_account_invoice_line_agent +msgid "Agent detail of commission line in invoice lines" +msgstr "Detalle de agente de líneas de comisión en las líneas de factura" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_bank_statement_line__partner_agent_ids +#: model:ir.model.fields,field_description:account_commission.field_account_move__partner_agent_ids +#: model:ir.model.fields,field_description:account_commission.field_account_payment__partner_agent_ids +msgid "Agents" +msgstr "Agentes" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_move_line__agent_ids +msgid "Agents & commissions" +msgstr "Agentes & comisiones" + +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_account_move_line__agent_ids +msgid "Agents/Commissions related to the invoice line." +msgstr "Agentes/Comisiones relacionadas a la línea de factura." + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__amount +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Amount" +msgstr "Importe" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_move_line__any_settled +msgid "Any Settled" +msgstr "Cualquiera Liquidada" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__balance +msgid "Balance" +msgstr "Balance" + +#. module: account_commission +#: code:addons/account_commission/models/commission_settlement.py:0 +#, python-format +msgid "Cannot cancel an invoiced settlement." +msgstr "No se puede anular una liquidación facturada." + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__categ_id +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Category of Product" +msgstr "Categoría de Producto" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_move_line__commission_free +msgid "Comm. free" +msgstr "Libre de comisión" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__commission_id +#: model:ir.model.fields,field_description:account_commission.field_account_move_line__commission_status +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__commission_id +msgid "Commission" +msgstr "Comisión" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__amount +msgid "Commission Amount" +msgstr "Importe de comisión" + +#. module: account_commission +#: model:ir.actions.act_window,name:account_commission.action_invoice_commission_analysis_report +#: model:ir.ui.menu,name:account_commission.menu_invoice_commissions_analysis +msgid "Commission Analysis" +msgstr "Análisis de comisión" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_bank_statement_line__commission_total +#: model:ir.model.fields,field_description:account_commission.field_account_move__commission_total +#: model:ir.model.fields,field_description:account_commission.field_account_payment__commission_total +#: model:ir.ui.menu,name:account_commission.menu_invoicing_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_move_line_form +msgid "Commissions" +msgstr "Comisiones" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__company_id +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__company_id +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__company_id +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Company" +msgstr "Compañía" + +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_commission_make_invoice__company_id +msgid "Company related to this journal" +msgstr "Compañía relacionada a este diario" + +#. module: account_commission +#: model:ir.actions.act_window,name:account_commission.action_commission_make_invoices +#: model:ir.ui.menu,name:account_commission.menu_invoicing_settlements_make_invoice +msgid "Create Commission Invoices" +msgstr "Crear facturas de comisiones" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.commission_make_invoice_form +msgid "Create invoices" +msgstr "Crear Facturas" + +#. module: account_commission +#: code:addons/account_commission/wizards/wizard_invoice.py:0 +#, python-format +msgid "Created Invoices" +msgstr "Facturas creadas" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__create_uid +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__create_uid +msgid "Created by" +msgstr "Creado por" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__create_date +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__create_date +msgid "Created on" +msgstr "Creado el" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__currency_id +msgid "Currency" +msgstr "Moneda" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Customer" +msgstr "Cliente" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__date +msgid "Date" +msgstr "Fecha" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Description" +msgstr "Descripción" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__display_name +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__display_name +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__display_name +msgid "Display Name" +msgstr "Nombre a mostrar" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Draft" +msgstr "Borrador" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Extended Filters" +msgstr "Filtros avanzados" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__from_settlement +msgid "From Settlement" +msgstr "De Liquidación" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_settlement__invoice_id +msgid "Generated Invoice" +msgstr "Factura generada" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_settlement__invoice_line_ids +msgid "Generated invoice lines" +msgstr "Líneas de factura generadas" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Group By" +msgstr "Agrupar por" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__grouped +msgid "Group invoices" +msgstr "Agrupar facturas" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__id +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__id +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__id +msgid "ID" +msgstr "ID" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__invoice_id +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Invoice" +msgstr "Factura" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_settlement_line__invoice_agent_line_id +msgid "Invoice Agent Line" +msgstr "Línea de factura de Agente" + +#. module: account_commission +#: model:ir.model.fields.selection,name:account_commission.selection__commission__invoice_state__open +msgid "Invoice Based" +msgstr "Basado en factura" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_invoice_commission_analysis_report +msgid "Invoice Commission Analysis Report" +msgstr "Informe analítico de facturas de comisión" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__date_invoice +msgid "Invoice Date" +msgstr "Fecha de factura" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__invoice_line_id +msgid "Invoice Line" +msgstr "Línea de factura" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Invoice Month" +msgstr "Mes de facturación" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission__invoice_state +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__invoice_state +msgid "Invoice Status" +msgstr "Estado de la factura" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__invoice_date +msgid "Invoice date" +msgstr "Fecha de factura" + +#. module: account_commission +#: model:ir.model.fields.selection,name:account_commission.selection__commission_settlement__state__except_invoice +msgid "Invoice exception" +msgstr "Excepción de factura" + +#. module: account_commission +#: model:ir.model.fields.selection,name:account_commission.selection__commission_settlement__state__invoiced +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Invoiced" +msgstr "Facturado" + +#. module: account_commission +#: model:ir.actions.act_window,name:account_commission.action_invoicing_commission_settlement +#: model:ir.ui.menu,name:account_commission.menu_invoicing_settlements +msgid "Invoices Settlements" +msgstr "Liquidación de Facturas" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__journal_id +msgid "Journal" +msgstr "Diario" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_account_move +msgid "Journal Entry" +msgstr "Entrada Diaria" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_account_move_line +msgid "Journal Item" +msgstr "Artículo Diario" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent____last_update +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice____last_update +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report____last_update +msgid "Last Modified on" +msgstr "Última modificación en" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__write_uid +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__write_uid +msgid "Last Updated by" +msgstr "Última actualización por" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__write_date +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__write_date +msgid "Last Updated on" +msgstr "Última actualización el" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_commission_settlement_line +msgid "Line of a commission settlement" +msgstr "Línea de liquidación de una comisión" + +#. module: account_commission +#: code:addons/account_commission/models/commission_settlement.py:0 +#: model_terms:ir.ui.view,arch_db:account_commission.view_settlement_form +#, python-format +msgid "Make invoice" +msgstr "Hacer factura" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.commission_make_invoice_form +msgid "Make invoices" +msgstr "Hacer facturas" + +#. module: account_commission +#: model:res.groups,name:account_commission.group_invoicing_commission +msgid "Manage invoices commissions" +msgstr "Gestionar las comisiones de facturas" + +#. module: account_commission +#: code:addons/account_commission/wizards/wizard_invoice.py:0 +#, python-format +msgid "No valid settlements to invoice." +msgstr "No hay liquidaciones válidas para facturar." + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Not Settled" +msgstr "No liquidado" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__object_id +msgid "Parent" +msgstr "Padre" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__partner_id +msgid "Partner" +msgstr "Socio" + +#. module: account_commission +#: model:ir.model.fields.selection,name:account_commission.selection__commission__invoice_state__paid +msgid "Payment Based" +msgstr "Pago basado en" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__percentage +msgid "Percentage of commission" +msgstr "Porcentaje de comisión" + +#. module: account_commission +#: code:addons/account_commission/models/commission_settlement.py:0 +#, python-format +msgid "Period: from %(date_from)s to %(date_to)s" +msgstr "Período: de %(date_from)s a %(date_to)s" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_move_line__product_id +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__product_id +msgid "Product" +msgstr "Producto" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__product_id +msgid "Product for invoicing" +msgstr "Producto a facturar" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Quantity" +msgstr "Cantidad" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_move_form +msgid "Regenerate agents" +msgstr "Regenerar agentes" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_settlement_form +msgid "Reset to draft" +msgstr "Devolver a borrador" + +#. module: account_commission +#: model:ir.model.fields.selection,name:account_commission.selection__commission_make_settle__settlement_type__sale_invoice +#: model:ir.model.fields.selection,name:account_commission.selection__commission_settlement__settlement_type__sale_invoice +msgid "Sales Invoices" +msgstr "Facturas de Venta" + +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_commission__invoice_state +msgid "" +"Select the invoice status for settling the commissions:\n" +"* 'Invoice Based': Commissions are settled when the invoice is issued.\n" +"* 'Payment Based': Commissions are settled when the invoice is paid (or " +"refunded)." +msgstr "" +"Seleccione el estado de la factura para liquidar las comisiones:\n" +"* 'Basado en factura': Las comisiones se liquidan cuando se emite la factura." +"\n" +"* Pago\": Las comisiones se liquidan cuando se paga (o reembolsa) la factura." + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__settled +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__settled +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Settled" +msgstr "Establecido" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_commission_settlement +#: model:ir.model.fields,field_description:account_commission.field_account_move_line__settlement_id +#: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__settlement_ids +msgid "Settlement" +msgstr "Liquidación" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_bank_statement_line__settlement_count +#: model:ir.model.fields,field_description:account_commission.field_account_move__settlement_count +#: model:ir.model.fields,field_description:account_commission.field_account_payment__settlement_count +msgid "Settlement Count" +msgstr "Recuento de liquidación" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__settlement_line_ids +msgid "Settlement Line" +msgstr "Línea de liquidación" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_make_settle__settlement_type +#: model:ir.model.fields,field_description:account_commission.field_commission_settlement__settlement_type +msgid "Settlement Type" +msgstr "Tipo de liquidación" + +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_account_move_line__settlement_id +msgid "Settlement that generates this invoice line" +msgstr "Liquidación que genera esta línea de factura" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_account_bank_statement_line__settlement_ids +#: model:ir.model.fields,field_description:account_commission.field_account_move__settlement_ids +#: model:ir.model.fields,field_description:account_commission.field_account_payment__settlement_ids +#: model_terms:ir.ui.view,arch_db:account_commission.commission_make_invoice_form +#: model_terms:ir.ui.view,arch_db:account_commission.view_in_invoice_bill_tree_inherit +#: model_terms:ir.ui.view,arch_db:account_commission.view_move_form +msgid "Settlements" +msgstr "Liquidaciones" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_settlement_line__invoice_line_id +msgid "Source invoice line" +msgstr "Origen de línea de factura" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_commission_settlement__state +msgid "State" +msgstr "Estado" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "Status" +msgstr "Estado" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__price_subtotal +msgid "Subtotal" +msgstr "Sub total" + +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_account_invoice_line_agent__invoice_id +msgid "The move of this entry line." +msgstr "El movimiento de esta línea de entrada." + +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_commission_settlement__settlement_type +msgid "" +"The source of the settlement, e.g. 'Sales invoice', 'Sales order', 'Purchase " +"order'..." +msgstr "" +"El origen de esta liquidación, por ej. 'Factura de venta','Pedido de " +"venta','Pedido de compra'..." + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "This Year" +msgstr "Este Año" + +#. module: account_commission +#: model_terms:ir.actions.act_window,help:account_commission.action_invoice_commission_analysis_report +msgid "" +"This report performs analysis on your commissions added in invoice lines. " +"You can check the amount and lines that will be settled by date, product, " +"product category, aget, etc. Use this report to perform analysis on invoice " +"lines agents not beeing settled yet." +msgstr "" +"Este informe realiza un análisis de sus comisiones añadidas en las líneas de " +"factura. Puede comprobar el importe y las líneas que se liquidarán por " +"fecha, producto, categoría de producto, edad, etc. Utilice este informe para " +"analizar las líneas de factura que aún no han sido liquidadas." + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__price_unit +msgid "Unit Price" +msgstr "Precio unitario" + +#. module: account_commission +#: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__uom_id +msgid "Unit of Measure" +msgstr "Unidad de Medida" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_commission_make_invoice +msgid "Wizard for making an invoice from a settlement" +msgstr "Asistente para hacer una factura a partir de una liquidación" + +#. module: account_commission +#: model:ir.model,name:account_commission.model_commission_make_settle +msgid "Wizard for settling commissions" +msgstr "Asistente para liquidación de comisiones" + +#. module: account_commission +#: code:addons/account_commission/models/account_move.py:0 +#, python-format +msgid "You can't cancel an invoice with settled lines" +msgstr "No se puede cancelar una factura con líneas liquidadas" + +#. module: account_commission +#: code:addons/account_commission/models/commission_settlement.py:0 +#, python-format +msgid "You can't delete invoiced settlements." +msgstr "No se pueden borrar liquidaciones facturadas." + +#. module: account_commission +#: code:addons/account_commission/models/account_move.py:0 +#, python-format +msgid "You can't modify a settled line" +msgstr "No se puede modificar una línea establecida" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.commission_make_invoice_form +msgid "_Cancel" +msgstr "_Cancelar" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_graph +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_pivot +msgid "invoice Commission Analysis" +msgstr "Análisis de comisión facturada" + +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search +msgid "invoices Commission Analysis" +msgstr "Análisis de Comisiones facturadas" diff --git a/account_commission/i18n/ja.po b/account_commission/i18n/ja.po index 5e978c8..09e9bc3 100644 --- a/account_commission/i18n/ja.po +++ b/account_commission/i18n/ja.po @@ -26,6 +26,11 @@ msgstr "# 数量" msgid "(keep empty for invoicing all the pending settlements)" msgstr "(全ての未清算分の請求書を作成するためには空欄にしてください)" +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Settlement invoice:" +msgstr "" + #. module: account_commission #: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__agent_id #: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__agent_id @@ -57,6 +62,7 @@ msgstr "請求書明細に関連するエージェント/コミッション。" #. module: account_commission #: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__amount +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document msgid "Amount" msgstr "金額" @@ -163,6 +169,7 @@ msgid "Currency" msgstr "通貨" #. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document #: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search msgid "Customer" msgstr "顧客" @@ -172,6 +179,11 @@ msgstr "顧客" msgid "Date" msgstr "日付" +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Description" +msgstr "" + #. module: account_commission #: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__display_name #: model:ir.model.fields,field_description:account_commission.field_commission_make_invoice__display_name @@ -223,7 +235,7 @@ msgstr "ID" #. module: account_commission #: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__invoice_id -#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document msgid "Invoice" msgstr "請求書" @@ -265,7 +277,6 @@ msgstr "請求書ステータス" #. module: account_commission #: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__invoice_date -#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement msgid "Invoice date" msgstr "請求日" @@ -274,11 +285,6 @@ msgstr "請求日" msgid "Invoice exception" msgstr "請求書例外" -#. module: account_commission -#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement -msgid "Invoice line" -msgstr "請求書明細" - #. module: account_commission #: model:ir.model.fields.selection,name:account_commission.selection__commission_settlement__state__invoiced #: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search @@ -395,6 +401,11 @@ msgstr "プロダクト" msgid "Product for invoicing" msgstr "請求用プロダクト" +#. module: account_commission +#: model_terms:ir.ui.view,arch_db:account_commission.report_settlement_document +msgid "Quantity" +msgstr "" + #. module: account_commission #: model_terms:ir.ui.view,arch_db:account_commission.view_move_form msgid "Regenerate agents" @@ -411,6 +422,15 @@ msgstr "ドラフトに再設定" msgid "Sales Invoices" msgstr "販売請求書" +#. module: account_commission +#: model:ir.model.fields,help:account_commission.field_commission__invoice_state +msgid "" +"Select the invoice status for settling the commissions:\n" +"* 'Invoice Based': Commissions are settled when the invoice is issued.\n" +"* 'Payment Based': Commissions are settled when the invoice is paid (or " +"refunded)." +msgstr "" + #. module: account_commission #: model:ir.model.fields,field_description:account_commission.field_account_invoice_line_agent__settled #: model:ir.model.fields,field_description:account_commission.field_invoice_commission_analysis_report__settled @@ -486,8 +506,8 @@ msgstr "この明細の仕訳" #. module: account_commission #: model:ir.model.fields,help:account_commission.field_commission_settlement__settlement_type msgid "" -"The source of the settlement, e.g. 'Sales invoice', 'Sales order', 'Purchase" -" order'..." +"The source of the settlement, e.g. 'Sales invoice', 'Sales order', 'Purchase " +"order'..." msgstr "精算元 例:「顧客請求書」、「販売オーダ」、「購買オーダ」..." #. module: account_commission @@ -561,3 +581,6 @@ msgstr "コミッション請求分析" #: model_terms:ir.ui.view,arch_db:account_commission.view_invoice_commission_analysis_search msgid "invoices Commission Analysis" msgstr "コミッション請求分析" + +#~ msgid "Invoice line" +#~ msgstr "請求書明細" diff --git a/account_commission/migrations/15.0.2.0.0/post-migration.py b/account_commission/migrations/15.0.2.0.0/post-migration.py new file mode 100644 index 0000000..c259a68 --- /dev/null +++ b/account_commission/migrations/15.0.2.0.0/post-migration.py @@ -0,0 +1,19 @@ +# Copyright 2024 Tecnativa - Pedro M. Baeza +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). +from openupgradelib import openupgrade + + +@openupgrade.migrate() +def migrate(env, version): + """Fill new invoice_agent_line_id many2one from the old many2many agent_line + equivalent table. This table always contain only one record on standard use. + """ + openupgrade.logged_query( + env.cr, + """ + UPDATE commission_settlement_line csl + SET invoice_agent_line_id = agent_line_id + FROM settlement_agent_line_rel rel + WHERE rel.settlement_id = csl.id + """, + ) diff --git a/account_commission/models/account_move.py b/account_commission/models/account_move.py index 019fe62..faea90f 100644 --- a/account_commission/models/account_move.py +++ b/account_commission/models/account_move.py @@ -114,6 +114,13 @@ def fields_view_get( res["arch"] = etree.tostring(invoice_xml) return res + def unlink(self): + """Put 'invoiced' settlements associated to the invoices back in settled state.""" + self.invoice_line_ids.settlement_id.filtered( + lambda s: s.state == "invoiced" + ).write({"state": "settled"}) + return super().unlink() + class AccountMoveLine(models.Model): _inherit = [ @@ -136,22 +143,17 @@ def _compute_any_settled(self): for record in self: record.any_settled = any(record.mapped("agent_ids.settled")) + def _filter_commission_applicable_lines(self): + return self.filtered( + lambda x: x.move_id.partner_id + and x.move_id.move_type[:3] == "out" + and not x.exclude_from_invoice_tab + ) + @api.depends("move_id.partner_id") def _compute_agent_ids(self): - for res in self: - settlement_lines = self.env["commission.settlement.line"].search( - [("invoice_line_id", "=", res.id)] - ) - for line in settlement_lines: - line.date = False - line.agent_id = False - line.settled_amount = 0.00 - line.currency_id = False - line.commission_id = False self.agent_ids = False # for resetting previous agents - for record in self.filtered( - lambda x: x.move_id.partner_id and x.move_id.move_type[:3] == "out" - ): + for record in self._filter_commission_applicable_lines(): if not record.commission_free and record.product_id: record.agent_ids = record._prepare_agents_vals_partner( record.move_id.partner_id, settlement_type="sale_invoice" @@ -198,7 +200,6 @@ class AccountInvoiceLineAgent(models.Model): ) currency_id = fields.Many2one( related="object_id.currency_id", - readonly=True, ) @api.depends( @@ -254,5 +255,5 @@ def _skip_settlement(self): self.ensure_one() return ( self.commission_id.invoice_state == "paid" - and self.invoice_id.payment_state not in ["in_payment", "paid"] + and self.invoice_id.payment_state not in ["in_payment", "paid", "reversed"] ) or self.invoice_id.state != "posted" diff --git a/account_commission/models/commission.py b/account_commission/models/commission.py index 5fb1849..964bf63 100644 --- a/account_commission/models/commission.py +++ b/account_commission/models/commission.py @@ -10,4 +10,7 @@ class Commission(models.Model): [("open", "Invoice Based"), ("paid", "Payment Based")], string="Invoice Status", default="open", + help="Select the invoice status for settling the commissions:\n" + "* 'Invoice Based': Commissions are settled when the invoice is issued.\n" + "* 'Payment Based': Commissions are settled when the invoice is paid (or refunded).", ) diff --git a/account_commission/models/commission_settlement.py b/account_commission/models/commission_settlement.py index 1f36422..65be536 100644 --- a/account_commission/models/commission_settlement.py +++ b/account_commission/models/commission_settlement.py @@ -87,13 +87,14 @@ def _prepare_invoice(self, journal, product, date=False): partner = self._get_invoice_partner() move_form.partner_id = partner move_form.journal_id = journal + move_form.currency_id = self.currency_id for settlement in self: with move_form.invoice_line_ids.new() as line_form: line_form.product_id = product line_form.quantity = -1 if settlement.total < 0 else 1 line_form.price_unit = abs(settlement.total) # Put period string - partner = self.agent_id + partner = settlement.agent_id lang = self.env["res.lang"].search( [ ( @@ -118,7 +119,7 @@ def _prepare_invoice(self, journal, product, date=False): return vals def _get_invoice_grouping_keys(self): - return ["company_id", "agent_id"] + return ["company_id", "currency_id", "agent_id"] def make_invoices(self, journal, product, date=False, grouped=False): invoice_vals_list = [] @@ -157,7 +158,9 @@ def make_invoices(self, journal, product, date=False, grouped=False): class SettlementLine(models.Model): _inherit = "commission.settlement.line" - invoice_agent_line_id = fields.Many2one(comodel_name="account.invoice.line.agent") + invoice_agent_line_id = fields.Many2one( + comodel_name="account.invoice.line.agent", index=True + ) invoice_line_id = fields.Many2one( comodel_name="account.move.line", store=True, diff --git a/account_commission/readme/CONFIGURE.rst b/account_commission/readme/CONFIGURE.rst index 78d9705..04e0739 100644 --- a/account_commission/readme/CONFIGURE.rst +++ b/account_commission/readme/CONFIGURE.rst @@ -3,4 +3,6 @@ For selecting invoice status in commissions: #. Edit or create a new record to select the invoice status for settling the commissions. * **Invoice Based**: Commissions are settled when the invoice is issued. - * **Payment Based**: Commissions are settled when the invoice is paid. + * **Payment Based**: Commissions are settled when the invoice is paid or refunded. + Note that when refunding an invoice, the corresponding reversed commission will + be settled as well, resulting in a 0 net commission between both operations. diff --git a/account_commission/readme/CONTRIBUTORS.rst b/account_commission/readme/CONTRIBUTORS.rst index 77b7518..720c33d 100644 --- a/account_commission/readme/CONTRIBUTORS.rst +++ b/account_commission/readme/CONTRIBUTORS.rst @@ -7,11 +7,13 @@ * Oihane Crucelaegui * Nicola Malcontenti * Aitor Bouzas +* Alexei Rivera * `Tecnativa `__: * Pedro M. Baeza * Manuel Calero + * Sergio Teruel * `Quartile `__: diff --git a/account_commission/static/description/index.html b/account_commission/static/description/index.html index 5cfa876..bd62469 100644 --- a/account_commission/static/description/index.html +++ b/account_commission/static/description/index.html @@ -1,20 +1,20 @@ - - + Account commissions