├── .copier-answers.yml
├── .coveragerc
├── .github
└── workflows
│ └── pre-commit.yml
├── .gitignore
├── .pre-commit-config.yaml
├── CONTRIBUTING.md
├── LICENSE
├── README.md
├── account_background_post
├── README.rst
├── __init__.py
├── __manifest__.py
├── data
│ └── ir_cron.xml
├── i18n
│ ├── account_background_post.pot
│ └── es.po
├── models
│ ├── __init__.py
│ └── account_move.py
├── views
│ └── account_move_views.xml
└── wizards
│ ├── __init__.py
│ ├── validate_account_move.py
│ └── validate_account_move_views.xml
├── account_invoice_commission
├── README.rst
├── __init__.py
├── __manifest__.py
├── i18n
│ ├── de.po
│ ├── es.po
│ ├── pt_BR.po
│ └── ru.po
├── models
│ ├── __init__.py
│ ├── account_commission_rule.py
│ ├── account_move.py
│ └── account_move_line.py
├── security
│ └── ir.model.access.csv
└── views
│ ├── account_commission_rule_view.xml
│ └── account_move_view.xml
├── account_invoice_control
├── README.rst
├── __init__.py
├── __manifest__.py
├── i18n
│ └── es.po
├── models
│ ├── __init__.py
│ └── account_move.py
├── security
│ └── account_invoice_control_security.xml
└── views
│ └── account_move_views.xml
├── account_invoice_line_number
├── README.rst
├── __init__.py
├── __manifest__.py
├── i18n
│ ├── de.po
│ ├── es.po
│ └── ru.po
├── models
│ ├── __init__.py
│ ├── account_move.py
│ └── account_move_line.py
└── views
│ └── account_move_view.xml
├── account_invoice_partial
├── README.rst
├── __init__.py
├── __manifest__.py
├── i18n
│ ├── de.po
│ ├── es.po
│ ├── pt_BR.po
│ └── ru.po
├── security
│ └── ir.model.access.csv
├── views
│ └── account_move_views.xml
└── wizards
│ ├── __init__.py
│ ├── account_invoice_partial_wizard.py
│ └── account_invoice_partial_wizard_views.xml
├── account_invoice_prices_update
├── README.rst
├── __init__.py
├── __manifest__.py
├── i18n
│ └── es.po
├── security
│ └── ir.model.access.csv
├── views
│ └── account_move_views.xml
└── wizards
│ ├── __init__.py
│ ├── account_invoice_prices_update_wizard.py
│ └── update_prices_wizard_views.xml
├── account_invoice_tax
├── README.rst
├── __init__.py
├── __manifest__.py
├── i18n
│ ├── account_invoice_tax.pot
│ ├── de.po
│ ├── es.po
│ └── ru.po
├── security
│ └── ir.model.access.csv
├── static
│ └── src
│ │ └── xml
│ │ └── tax_totals.xml
├── views
│ └── account_move_view.xml
└── wizards
│ ├── __init__.py
│ ├── account_invoice_tax.py
│ └── account_invoice_tax_view.xml
├── pyproject.toml
├── requirements.txt
└── website_sale_account_invoice_commission
├── README.rst
├── __init__.py
├── __manifest__.py
├── i18n
├── es.po
└── ru.po
├── models
├── __init__.py
└── account_commission_rule.py
└── views
└── account_commission_rule_views.xml
/.copier-answers.yml:
--------------------------------------------------------------------------------
1 | # Do NOT update manually; changes here will be overwritten by Copier
2 | _commit: 00cee12
3 | _src_path: https://github.com/ingadhoc/addons-repo-template.git
4 | description: Odoo Invoicing Extension Addons
5 | is_private: false
6 | name: ADHOC Account Invoicing
7 | odoo_version: 18.0
8 | pre_commit_ignore: []
9 | slug: ''
10 |
11 |
--------------------------------------------------------------------------------
/.coveragerc:
--------------------------------------------------------------------------------
1 | # Config file .coveragerc
2 |
3 | [report]
4 | include =
5 | */ingadhoc/odoo-addons/*
6 |
7 | omit =
8 | */scenario/*
9 | */scenarios/*
10 | */test/*
11 | */tests/*
12 | *__init__.py
13 | *__openerp__.py
14 |
15 | # Regexes for lines to exclude from consideration
16 | exclude_lines =
17 | # Have to re-enable the standard pragma
18 | pragma: no cover
19 | # Don't complain about null context checking
20 | if context is None:
21 |
--------------------------------------------------------------------------------
/.github/workflows/pre-commit.yml:
--------------------------------------------------------------------------------
1 | # ⚠️ DO NOT EDIT THIS FILE, IT IS GENERATED BY COPIER ⚠️
2 | # Changes here will be lost on a future update.
3 | # See: https://github.com/ingadhoc/addons-repo-template
4 |
5 | name: pre-commit
6 |
7 | on:
8 | push:
9 | branches: "[0-9][0-9].0"
10 | pull_request_target:
11 |
12 | jobs:
13 | pre-commit:
14 | runs-on: ubuntu-latest
15 | steps:
16 | -
17 | name: Checkout
18 | uses: actions/checkout@v4
19 | with:
20 | ref: ${{ github.event_name == 'pull_request_target' && github.event.pull_request.head.sha || github.ref }}
21 | -
22 | id: setup-python
23 | name: Setup Python
24 | uses: actions/setup-python@v5
25 | with:
26 | python-version: "3.10"
27 | cache: "pip"
28 | -
29 | name: Pre-commit cache
30 | uses: actions/cache@v4
31 | with:
32 | path: ~/.cache/pre-commit
33 | key: pre-commit|${{ steps.setup-python.outputs.python-version }}|${{ hashFiles('.pre-commit-config.yaml') }}
34 | -
35 | id: precommit
36 | name: Pre-commit
37 | uses: pre-commit/action@v3.0.1
38 | -
39 | name: Create commit status
40 | if: github.event_name == 'pull_request_target'
41 | run: |
42 | curl -L \
43 | -X POST \
44 | -H "Accept: application/vnd.github+json" \
45 | -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \
46 | -H "X-GitHub-Api-Version: 2022-11-28" \
47 | https://api.github.com/repos/${{ github.repository }}/statuses/${{ github.event.pull_request.head.sha }} \
48 | -d '{"state":"${{ steps.precommit.outcome }}","context":"mergebot/pre-commit"}' \
49 | --fail
50 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # ⚠️ DO NOT EDIT THIS FILE, IT IS GENERATED BY COPIER ⚠️
2 | # Changes here will be lost on a future update.
3 | # See: https://github.com/ingadhoc/addons-repo-template
4 |
5 | # Byte-compiled / optimized / DLL files
6 | __pycache__/
7 | *.py[cod]
8 |
9 | # C extensions
10 | *.so
11 |
12 | # Distribution / packaging
13 | .Python
14 | env/
15 | bin/
16 | build/
17 | develop-eggs/
18 | dist/
19 | eggs/
20 | lib/
21 | lib64/
22 | parts/
23 | sdist/
24 | var/
25 | *.egg-info/
26 | .installed.cfg
27 | *.egg
28 |
29 | # Installer logs
30 | pip-log.txt
31 | pip-delete-this-directory.txt
32 |
33 | # Unit test / coverage reports
34 | htmlcov/
35 | .tox/
36 | .coverage
37 | .cache
38 | nosetests.xml
39 | coverage.xml
40 |
41 | # Translations
42 | *.mo
43 |
44 | # Ensure we never commit pgdumps
45 | *.dump
46 | *.sql
47 | *.pg
48 | *.pg.gpg
49 |
50 | # Mr Developer
51 | .mr.developer.cfg
52 | .project
53 | .pydevproject
54 |
55 | # Rope
56 | .ropeproject
57 |
58 | # Django stuff:
59 | *.log
60 |
61 | # Sphinx documentation
62 | docs/_build/
63 |
--------------------------------------------------------------------------------
/.pre-commit-config.yaml:
--------------------------------------------------------------------------------
1 | # ⚠️ DO NOT EDIT THIS FILE, IT IS GENERATED BY COPIER ⚠️
2 | # Changes here will be lost on a future update.
3 | # See: https://github.com/ingadhoc/addons-repo-template
4 |
5 | exclude: |
6 | (?x)
7 |
8 | # We don't want to mess with tool-generated files
9 | .svg$|/tests/([^/]+/)?cassettes/|^.copier-answers.yml$|^.github/|^eslint.config.cjs|^prettier.config.cjs|
10 | # Library files can have extraneous formatting (even minimized)
11 | /static/(src/)?lib/|
12 | # Ignore build and dist directories in addons
13 | /build/|/dist/|
14 | # Ignore test files in addons
15 | /tests/samples/.*|
16 | # You don't usually want a bot to modify your legal texts
17 | (LICENSE.*|COPYING.*)
18 |
19 | # Keep in sync with .github/workflows/pre-commit.yml
20 | default_language_version:
21 | python: python3
22 |
23 | repos:
24 |
25 | - repo: https://github.com/pre-commit/pre-commit-hooks
26 | rev: v5.0.0
27 | hooks:
28 | - id: check-added-large-files
29 | - id: check-case-conflict
30 | - id: check-docstring-first
31 | - id: check-executables-have-shebangs
32 | - id: check-merge-conflict
33 | - id: check-symlinks
34 | - id: check-xml
35 | - id: check-yaml
36 | - id: debug-statements
37 | - id: end-of-file-fixer
38 | - id: mixed-line-ending
39 | args: ["--fix=lf"]
40 | - id: trailing-whitespace
41 | # exclude autogenerated files
42 | exclude: \.pot?$
43 |
44 | - repo: https://github.com/OCA/odoo-pre-commit-hooks
45 | rev: v0.0.35
46 | hooks:
47 | - id: oca-checks-odoo-module
48 | args:
49 | - --disable=xml-dangerous-qweb-replace-low-priority,xml-view-dangerous-replace-low-priority,xml-oe-structure-missing-id
50 | - id: oca-checks-po
51 | args:
52 | - --disable=po-pretty-format
53 |
54 | - repo: https://github.com/astral-sh/ruff-pre-commit
55 | rev: v0.6.8
56 | hooks:
57 | - id: ruff
58 | args: [--fix, --exit-non-zero-on-fix]
59 | - id: ruff-format
60 |
61 | - repo: https://github.com/OCA/pylint-odoo
62 | rev: v9.1.3
63 | hooks:
64 | - id: pylint_odoo
65 |
66 | - repo: https://github.com/rstcheck/rstcheck
67 | rev: v6.2.1
68 | hooks:
69 | - id: rstcheck
70 |
--------------------------------------------------------------------------------
/CONTRIBUTING.md:
--------------------------------------------------------------------------------
1 | # ADHOC Guidelines
2 |
3 | Please follow the official guide from [Odoo Argentina](https://github.com/ingadhoc/odoo-argentina/wiki).
4 |
5 | ## Project Specific Guidelines
6 |
7 | This project does not have specific coding guidelines.
8 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | [](https://coveralls.io/r/ingadhoc/?branch=18.0)
2 | [](https://codeclimate.com/github/ingadhoc/)
3 |
4 | # ADHOC Account Invoicing
5 |
6 | Odoo Invoicing Extension Addons
7 |
8 | ----
9 |
10 |
11 | **Adhoc SA** - www.adhoc.com.ar
12 | .
13 |
--------------------------------------------------------------------------------
/account_background_post/README.rst:
--------------------------------------------------------------------------------
1 | .. |company| replace:: ADHOC SA
2 |
3 | .. |company_logo| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-logo.png
4 | :alt: ADHOC SA
5 | :target: https://www.adhoc.com.ar
6 |
7 | .. |icon| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-icon.png
8 |
9 | .. image:: https://img.shields.io/badge/license-AGPL--3-blue.png
10 | :target: https://www.gnu.org/licenses/agpl
11 | :alt: License: AGPL-3
12 |
13 | =======================
14 | Account Background Post
15 | =======================
16 |
17 | This module let the user to improve the use of the post entries action on the invoices list view.
18 |
19 | 1. Let the user to post the entries in Background. This new option on the wizard will mark the invoices to be validated so they can be validated in Background, if we found and error with one of them, we leave a message in the invoice notifying the internal users and unmark the invoice so the validate process can continue with other invoices.
20 |
21 | 2. If the user want to validate the invoices at the current moment not in Background, we do the next two changes:
22 |
23 | 2.1 We only let the user to validate small batch of invoices. By default only 20 invoices. If the user try to select more than 20 invoices then we force him to use Post in Background option.
24 |
25 | 2.2 If they select less than 20 then we let them validate the invoices but we validate each one by one, formerly this method was trying to validate all the invoices at once and if there was some error on one of the invoices then we fail all the info of the correctly validated ones.
26 |
27 | IMPORTANT: Batch size by default is 20, but if the user want to use another size they can define a system parameter with name "account_background_post.batch_size" to force a different batch size.
28 |
29 | Installation
30 | ============
31 |
32 | To install this module, you need to:
33 |
34 | #. Only need to install the module
35 |
36 | Configuration
37 | =============
38 |
39 | To configure this module, you need to:
40 |
41 | #. Nothing to configure
42 |
43 | Usage
44 | =====
45 |
46 | To use this module, you need to:
47 |
48 | #. Go the invoices list view and select a batch of invoices.
49 | #. Go to action menu and click on post entries option.
50 | #. Use Post in Background or Post Journal Entries depending of what they need to know.
51 |
52 | .. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
53 | :alt: Try me on Runbot
54 | :target: http://runbot.adhoc.com.ar/
55 |
56 | Bug Tracker
57 | ===========
58 |
59 | Bugs are tracked on `GitHub Issues
60 | `_. In case of trouble, please
61 | check there if your issue has already been reported. If you spotted it first,
62 | help us smashing it by providing a detailed and welcomed feedback.
63 |
64 | Credits
65 | =======
66 |
67 | Images
68 | ------
69 |
70 | * |company| |icon|
71 |
72 | Contributors
73 | ------------
74 |
75 | Maintainer
76 | ----------
77 |
78 | |company_logo|
79 |
80 | This module is maintained by the |company|.
81 |
82 | To contribute to this module, please visit https://www.adhoc.com.ar.
83 |
--------------------------------------------------------------------------------
/account_background_post/__init__.py:
--------------------------------------------------------------------------------
1 | from . import models
2 | from . import wizards
3 |
--------------------------------------------------------------------------------
/account_background_post/__manifest__.py:
--------------------------------------------------------------------------------
1 | {
2 | "name": "Account Background Post",
3 | "version": "18.0.1.0.0",
4 | "author": "ADHOC SA",
5 | "depends": [
6 | "account",
7 | ],
8 | "data": [
9 | "views/account_move_views.xml",
10 | "wizards/validate_account_move_views.xml",
11 | "data/ir_cron.xml",
12 | ],
13 | "license": "AGPL-3",
14 | "installable": True,
15 | "auto_install": False,
16 | "application": False,
17 | }
18 |
--------------------------------------------------------------------------------
/account_background_post/data/ir_cron.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Background Post Invoices: cron
6 |
7 | code
8 | model._cron_background_post_invoices()
9 |
10 | 10
11 | minutes
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/account_background_post/i18n/account_background_post.pot:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_background_post
4 | #
5 | msgid ""
6 | msgstr ""
7 | "Project-Id-Version: Odoo Server 16.0+e\n"
8 | "Report-Msgid-Bugs-To: \n"
9 | "POT-Creation-Date: 2023-09-28 00:38+0000\n"
10 | "PO-Revision-Date: 2023-09-28 00:38+0000\n"
11 | "Last-Translator: \n"
12 | "Language-Team: \n"
13 | "MIME-Version: 1.0\n"
14 | "Content-Type: text/plain; charset=UTF-8\n"
15 | "Content-Transfer-Encoding: \n"
16 | "Plural-Forms: \n"
17 |
18 | #. module: account_background_post
19 | #: model:ir.model.fields,field_description:account_background_post.field_account_bank_statement_line__background_post
20 | #: model:ir.model.fields,field_description:account_background_post.field_account_move__background_post
21 | #: model:ir.model.fields,field_description:account_background_post.field_account_payment__background_post
22 | msgid "Background Post"
23 | msgstr ""
24 |
25 | #. module: account_background_post
26 | #: model:ir.actions.server,name:account_background_post.ir_cron_background_post_invoices_ir_actions_server
27 | #: model:ir.cron,cron_name:account_background_post.ir_cron_background_post_invoices
28 | msgid "Background Post Invoices: cron"
29 | msgstr ""
30 |
31 | #. module: account_background_post
32 | #: model:ir.model.fields,field_description:account_background_post.field_validate_account_move__batch_size
33 | msgid "Batch Size"
34 | msgstr ""
35 |
36 | #. module: account_background_post
37 | #: model:ir.model.fields,field_description:account_background_post.field_validate_account_move__count_inv
38 | msgid "Count Inv"
39 | msgstr ""
40 |
41 | #. module: account_background_post
42 | #: model:ir.model.fields,field_description:account_background_post.field_validate_account_move__force_background
43 | msgid "Force Background"
44 | msgstr ""
45 |
46 | #. module: account_background_post
47 | #: model:ir.model.fields,help:account_background_post.field_account_bank_statement_line__background_post
48 | #: model:ir.model.fields,help:account_background_post.field_account_move__background_post
49 | #: model:ir.model.fields,help:account_background_post.field_account_payment__background_post
50 | msgid "If True then this invoice will be validated in the background by cron."
51 | msgstr ""
52 |
53 | #. module: account_background_post
54 | #: model:ir.model,name:account_background_post.model_account_move
55 | msgid "Journal Entry"
56 | msgstr ""
57 |
58 | #. module: account_background_post
59 | #. odoo-python
60 | #: code:addons/account_background_post/wizards/validate_account_move.py:0
61 | #, python-format
62 | msgid "Missing 'active_model' in context."
63 | msgstr ""
64 |
65 | #. module: account_background_post
66 | #: model:ir.model.fields,field_description:account_background_post.field_validate_account_move__move_ids
67 | msgid "Move"
68 | msgstr ""
69 |
70 | #. module: account_background_post
71 | #: model_terms:ir.ui.view,arch_db:account_background_post.validate_account_move_view
72 | msgid "Only use this option to post a small batch of invoices"
73 | msgstr ""
74 |
75 | #. module: account_background_post
76 | #: model_terms:ir.ui.view,arch_db:account_background_post.validate_account_move_view
77 | msgid "Post in Background"
78 | msgstr ""
79 |
80 | #. module: account_background_post
81 | #: model:ir.model.fields,help:account_background_post.field_validate_account_move__count_inv
82 | msgid ""
83 | "Technical field to know the number of invoices selected from the wizard"
84 | msgstr ""
85 |
86 | #. module: account_background_post
87 | #. odoo-python
88 | #: code:addons/account_background_post/wizards/validate_account_move.py:0
89 | #, python-format
90 | msgid "There are no journal items in the draft state to post."
91 | msgstr ""
92 |
93 | #. module: account_background_post
94 | #: model_terms:ir.ui.view,arch_db:account_background_post.view_account_invoice_filter
95 | msgid "To validate in background"
96 | msgstr ""
97 |
98 | #. module: account_background_post
99 | #: model:ir.model,name:account_background_post.model_validate_account_move
100 | msgid "Validate Account Move"
101 | msgstr ""
102 |
103 | #. module: account_background_post
104 | #. odoo-python
105 | #: code:addons/account_background_post/models/account_move.py:0
106 | #, python-format
107 | msgid "We tried to validate this invoice on the background but got this error"
108 | msgstr ""
109 |
110 | #. module: account_background_post
111 | #: model_terms:ir.ui.view,arch_db:account_background_post.validate_account_move_view
112 | msgid ""
113 | "With this, all the invoices selected to be validated will be marked and they"
114 | " will be validated one by one. If an error is found when validating any "
115 | "invoice, the automatic validation of the same will be unmarked and it will "
116 | "be notified via messaging"
117 | msgstr ""
118 |
119 | #. module: account_background_post
120 | #. odoo-python
121 | #: code:addons/account_background_post/wizards/validate_account_move.py:0
122 | #, python-format
123 | msgid ""
124 | "You can only validate on batches of size < %s invoices. If you need to "
125 | "validate more invoices please use the validate on background option"
126 | msgstr ""
127 |
--------------------------------------------------------------------------------
/account_background_post/i18n/es.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_background_post
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2024
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 18.0+e\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2025-03-12 20:37+0000\n"
13 | "PO-Revision-Date: 2024-11-14 20:12+0000\n"
14 | "Last-Translator: Juan José Scarafía , 2024\n"
15 | "Language-Team: Spanish (https://app.transifex.com/adhoc/teams/46451/es/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: es\n"
20 | "Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n"
21 |
22 | #. module: account_background_post
23 | #: model:ir.model.fields,field_description:account_background_post.field_account_bank_statement_line__background_post
24 | #: model:ir.model.fields,field_description:account_background_post.field_account_move__background_post
25 | msgid "Background Post"
26 | msgstr "Validación en Background"
27 |
28 | #. module: account_background_post
29 | #: model:ir.actions.server,name:account_background_post.ir_cron_background_post_invoices_ir_actions_server
30 | msgid "Background Post Invoices: cron"
31 | msgstr "Facturas Validación en Background: cron"
32 |
33 | #. module: account_background_post
34 | #: model:ir.model.fields,field_description:account_background_post.field_validate_account_move__batch_size
35 | msgid "Batch Size"
36 | msgstr "Tamaño del Lote"
37 |
38 | #. module: account_background_post
39 | #: model:ir.model.fields,field_description:account_background_post.field_validate_account_move__count_inv
40 | msgid "Count Inv"
41 | msgstr "Cantidad de Facturas"
42 |
43 | #. module: account_background_post
44 | #: model:ir.model.fields,field_description:account_background_post.field_validate_account_move__force_background
45 | msgid "Force Background"
46 | msgstr "Forzar Background"
47 |
48 | #. module: account_background_post
49 | #: model:ir.model.fields,help:account_background_post.field_account_bank_statement_line__background_post
50 | #: model:ir.model.fields,help:account_background_post.field_account_move__background_post
51 | msgid "If True then this invoice will be validated in the background by cron."
52 | msgstr "Si es Verdadero esta factura sera validada en background por el cron."
53 |
54 | #. module: account_background_post
55 | #: model:ir.model,name:account_background_post.model_account_move
56 | msgid "Journal Entry"
57 | msgstr "Asiento contable"
58 |
59 | #. module: account_background_post
60 | #: model:ir.model.fields,field_description:account_background_post.field_validate_account_move__move_ids
61 | msgid "Move"
62 | msgstr "Movimiento "
63 |
64 | #. module: account_background_post
65 | #: model_terms:ir.ui.view,arch_db:account_background_post.validate_account_move_view
66 | msgid "Only use this option to post a small batch of invoices"
67 | msgstr "Solo use esta opción para validar pequeños lotes de facturas"
68 |
69 | #. module: account_background_post
70 | #: model_terms:ir.ui.view,arch_db:account_background_post.validate_account_move_view
71 | msgid "Post in Background"
72 | msgstr "Validar en Background"
73 |
74 | #. module: account_background_post
75 | #: model:ir.model.fields,help:account_background_post.field_validate_account_move__count_inv
76 | msgid ""
77 | "Technical field to know the number of invoices selected from the wizard"
78 | msgstr ""
79 | "Campo técnico para saber el numero de facturas seleccionadas para el "
80 | "asistente"
81 |
82 | #. module: account_background_post
83 | #: model_terms:ir.ui.view,arch_db:account_background_post.view_account_invoice_filter
84 | msgid "To validate in background"
85 | msgstr "Para validar en background"
86 |
87 | #. module: account_background_post
88 | #: model:ir.model,name:account_background_post.model_validate_account_move
89 | msgid "Validate Account Move"
90 | msgstr "Validar asiento contable"
91 |
92 | #. module: account_background_post
93 | #. odoo-python
94 | #: code:addons/account_background_post/models/account_move.py:0
95 | msgid "We tried to validate this invoice on the background but got this error"
96 | msgstr ""
97 | "Intentamos validar esta factura en background pero recibimos este error"
98 |
99 | #. module: account_background_post
100 | #: model_terms:ir.ui.view,arch_db:account_background_post.validate_account_move_view
101 | msgid ""
102 | "With this, all the invoices selected to be validated will be marked and they"
103 | " will be validated one by one. If an error is found when validating any "
104 | "invoice, the automatic validation of the same will be unmarked and it will "
105 | "be notified via messaging"
106 | msgstr ""
107 | "Con esto, todas las facturas seleccionadas para ser validadas serán marcadas"
108 | " y ellas será validades una por una. Si ocurre algún error, la validación "
109 | "automática será desactivada para dicha factura y notificaremos vía "
110 | "mensajería del problema"
111 |
112 | #. module: account_background_post
113 | #. odoo-python
114 | #: code:addons/account_background_post/wizards/validate_account_move.py:0
115 | msgid ""
116 | "You can only validate on batches of size < %s invoices. If you need to "
117 | "validate more invoices please use the validate on background option"
118 | msgstr ""
119 | "Solo puedes validar en lotes de < %s facturas. Si necesita validar mas "
120 | "facturas por favor usar la opción \"Validar en Background\"."
121 |
--------------------------------------------------------------------------------
/account_background_post/models/__init__.py:
--------------------------------------------------------------------------------
1 | from . import account_move
2 |
--------------------------------------------------------------------------------
/account_background_post/models/account_move.py:
--------------------------------------------------------------------------------
1 | from odoo import _, api, fields, models
2 | from odoo.tools import plaintext2html
3 |
4 |
5 | class AccountMove(models.Model):
6 | _inherit = "account.move"
7 |
8 | background_post = fields.Boolean(
9 | help="If True then this invoice will be validated in the background by cron.", copy=False, tracking=True
10 | )
11 |
12 | def get_internal_partners(self):
13 | res = self.env["res.partner"]
14 | for partner in self.message_partner_ids:
15 | if partner.user_ids and all(user._is_internal() for user in partner.user_ids):
16 | res |= partner
17 | return res
18 |
19 | @api.model
20 | def _cron_background_post_invoices(self, batch_size=20):
21 | """Busca las facturas que estan marcadas por ser validadas en background y las valida.
22 |
23 | Ponemos un batch size para mejorar la performance ya que odoo econimiza muchas queries al tener
24 | un prefetch_ids de 20 en vez de 1. pero ademas, iteramos y no mandamos el atcion_post a todos los
25 | records juntos para no tener problemas frente a facturas con error y envio de emails o cosas similares
26 | """
27 | moves = self.search([("background_post", "=", True), ("state", "=", "draft")])
28 |
29 | for move in moves[:batch_size]:
30 | try:
31 | move.action_post()
32 | move._cr.commit()
33 | except Exception as exp:
34 | self.env.cr.rollback()
35 | move.background_post = False
36 | move.message_post(
37 | body=_("We tried to validate this invoice on the background but got this error")
38 | + ": \n\n"
39 | + plaintext2html(str(exp), "em"),
40 | partner_ids=move.get_internal_partners().ids,
41 | body_is_html=True,
42 | )
43 | if len(moves) > batch_size:
44 | self.env.ref("account_background_post.ir_cron_background_post_invoices")._trigger()
45 |
46 | def _post(self, soft=True):
47 | posted = super()._post(soft=soft)
48 | posted.filtered("background_post").background_post = False
49 | return posted
50 |
--------------------------------------------------------------------------------
/account_background_post/views/account_move_views.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | account.move.list.inherit
5 | account.move
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 | account.invoice.select.inherit
16 | account.move
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/account_background_post/wizards/__init__.py:
--------------------------------------------------------------------------------
1 | from . import validate_account_move
2 |
--------------------------------------------------------------------------------
/account_background_post/wizards/validate_account_move.py:
--------------------------------------------------------------------------------
1 | import logging
2 |
3 | from odoo import _, fields, models
4 | from odoo.exceptions import UserError
5 |
6 | _logger = logging.getLogger(__name__)
7 |
8 |
9 | class ValidateAccountMove(models.TransientModel):
10 | _inherit = "validate.account.move"
11 |
12 | move_ids = fields.Many2many("account.move")
13 | count_inv = fields.Integer(help="Technical field to know the number of invoices selected from the wizard")
14 | batch_size = fields.Integer(compute="_compute_batch_size")
15 | force_background = fields.Integer(compute="_compute_force_background")
16 |
17 | def _compute_batch_size(self):
18 | self.batch_size = self.env["ir.config_parameter"].sudo().get_param("account_background_post.batch_size", 20)
19 |
20 | def _compute_force_background(self):
21 | for rec in self:
22 | rec.force_background = rec.count_inv > rec.batch_size
23 |
24 | def default_get(self, fields):
25 | res = super().default_get(fields)
26 | if res:
27 | res["count_inv"] = len(res["move_ids"])
28 | return res
29 |
30 | def action_background_post(self):
31 | self.move_ids.background_post = True
32 | self.env.ref("account_background_post.ir_cron_background_post_invoices")._trigger()
33 |
34 | def validate_move(self):
35 | """Sobre escribimos este método para el caso de varias invoices para hacer:
36 |
37 | 1. Que en lugar de hacer un _post hacemos un _action_post. esto porque odoo hace cosas como lanzar acciones y correr validaciones solo cuando corremos el action_post. y nosotros queremos que esas se apliquen. eso incluye el envio de email cuando validamos la factura.
38 |
39 | 2. que se valida cada factura una a uno y no todas jutnas. esto para evitar problemas que puedan surgier
40 | por errores, que no se puedan ejecutar los commits que tenemos para guardar el estado de factura electronica y tambien para asegurar que tras cada fatura se envie su email, asi si hay un error posterior las facturas que fueron validadas aseguremos que hayan sido totalmente procesadas.
41 |
42 | 3. Limitamos sui el usuario quiere validar mas facturas que el batch size definido directamente
43 | le pedimos que las valide en background."""
44 |
45 | if len(self) == 1:
46 | return super().validate_move()
47 |
48 | if self.count_inv > self.batch_size:
49 | raise UserError(
50 | _(
51 | "You can only validate on batches of size < %s invoices. If you need to validate"
52 | " more invoices please use the validate on background option",
53 | self.batch_size,
54 | )
55 | )
56 |
57 | for move in self.move_ids:
58 | _logger.info("Validating invoice %s", move.id)
59 | move.action_post()
60 | move._cr.commit()
61 |
62 | return {"type": "ir.actions.act_window_close"}
63 |
--------------------------------------------------------------------------------
/account_background_post/wizards/validate_account_move_views.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Post Journal Entries
6 | validate.account.move
7 |
8 |
9 |
10 |
11 | 1
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
22 |
23 |
24 |
25 |
26 | Only use this option to post a small batch of invoices
27 | force_background
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
--------------------------------------------------------------------------------
/account_invoice_commission/README.rst:
--------------------------------------------------------------------------------
1 | .. |company| replace:: ADHOC SA
2 |
3 | .. |company_logo| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-logo.png
4 | :alt: ADHOC SA
5 | :target: https://www.adhoc.com.ar
6 |
7 | .. |icon| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-icon.png
8 |
9 | .. image:: https://img.shields.io/badge/license-AGPL--3-blue.png
10 | :target: https://www.gnu.org/licenses/agpl
11 | :alt: License: AGPL-3
12 |
13 | ===================
14 | Commission Invoices
15 | ===================
16 |
17 | Simple module that links a commission invoice (supplier invoice) to the commissioned invoices (customer invoices)
18 |
19 | - Allows to set Rules Commission.
20 |
21 | - Creates a tab in Commission Invoices (supplier invoice) that allows users to add Commisioned Invoices (customer invoice) based on settled rules commission.
22 |
23 | - Creates a tab in Commissioned Invoices that shows the applied Commision Invoices.
24 |
25 |
26 | Installation
27 | ============
28 |
29 | To install this module, you need to:
30 |
31 | #. Just install this module.
32 |
33 |
34 | Configuration
35 | =============
36 |
37 | To configure this module, you need to:
38 |
39 | #. No configuration nedeed.
40 |
41 |
42 | Usage
43 | =====
44 |
45 | To use this module, you need to:
46 |
47 | #. Go to ...
48 |
49 | .. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
50 | :alt: Try me on Runbot
51 | :target: http://runbot.adhoc.com.ar/
52 |
53 | Bug Tracker
54 | ===========
55 |
56 | Bugs are tracked on `GitHub Issues
57 | `_. In case of trouble, please
58 | check there if your issue has already been reported. If you spotted it first,
59 | help us smashing it by providing a detailed and welcomed feedback.
60 |
61 | Credits
62 | =======
63 |
64 | Images
65 | ------
66 |
67 | * |company| |icon|
68 |
69 | Contributors
70 | ------------
71 |
72 | Maintainer
73 | ----------
74 |
75 | |company_logo|
76 |
77 | This module is maintained by the |company|.
78 |
79 | To contribute to this module, please visit https://www.adhoc.com.ar.
80 |
--------------------------------------------------------------------------------
/account_invoice_commission/__init__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from . import models
6 |
--------------------------------------------------------------------------------
/account_invoice_commission/__manifest__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | #
3 | # Copyright (C) 2015 ADHOC SA (http://www.adhoc.com.ar)
4 | # All Rights Reserved.
5 | #
6 | # This program is free software: you can redistribute it and/or modify
7 | # it under the terms of the GNU Affero General Public License as
8 | # published by the Free Software Foundation, either version 3 of the
9 | # License, or (at your option) any later version.
10 | #
11 | # This program is distributed in the hope that it will be useful,
12 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | # GNU Affero General Public License for more details.
15 | #
16 | # You should have received a copy of the GNU Affero General Public License
17 | # along with this program. If not, see .
18 | #
19 | ##############################################################################
20 | {
21 | "name": "Commission Invoices",
22 | "version": "18.0.1.2.0",
23 | "category": "Accounting",
24 | "sequence": 14,
25 | "summary": "",
26 | "author": "ADHOC SA",
27 | "website": "www.adhoc.com.ar",
28 | "license": "AGPL-3",
29 | "images": [],
30 | "depends": [
31 | "account",
32 | ],
33 | "data": [
34 | "views/account_move_view.xml",
35 | "views/account_commission_rule_view.xml",
36 | "security/ir.model.access.csv",
37 | ],
38 | "demo": [],
39 | "test": [],
40 | "installable": True,
41 | "auto_install": False,
42 | "application": False,
43 | }
44 |
--------------------------------------------------------------------------------
/account_invoice_commission/i18n/de.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_commission
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2020
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 13.0\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2021-01-07 17:47+0000\n"
13 | "PO-Revision-Date: 2020-07-15 16:43+0000\n"
14 | "Last-Translator: Juan José Scarafía , 2020\n"
15 | "Language-Team: German (https://www.transifex.com/adhoc/teams/46451/de/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: de\n"
20 | "Plural-Forms: nplurals=2; plural=(n != 1);\n"
21 |
22 | #. module: account_invoice_commission
23 | #: model:ir.model,name:account_invoice_commission.model_account_commission_rule
24 | msgid "Account Commission Rule"
25 | msgstr ""
26 |
27 | #. module: account_invoice_commission
28 | #: model:ir.model.fields,help:account_invoice_commission.field_account_move__commission_invoice_ids
29 | msgid "Commision invoices where this invoice is commissioned"
30 | msgstr "Rechnungen, die in dieser Provisionsabrechnungen berücksichtigt sind"
31 |
32 | #. module: account_invoice_commission
33 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_move_form
34 | msgid "Commission"
35 | msgstr "Provision"
36 |
37 | #. module: account_invoice_commission
38 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__commission_amount
39 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move_line__commission_amount
40 | msgid "Commission Amount"
41 | msgstr "Provisionsbetrag"
42 |
43 | #. module: account_invoice_commission
44 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__commission_invoice_ids
45 | msgid "Commission Invoices"
46 | msgstr "Provisionsabrechnungen"
47 |
48 | #. module: account_invoice_commission
49 | #: model:ir.actions.act_window,name:account_invoice_commission.action_commission_rule_form
50 | #: model:ir.ui.menu,name:account_invoice_commission.menu_action_commission_rule_form
51 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.account_commission_rule_tree
52 | msgid "Commission Rules"
53 | msgstr "Provisionierungsregeln"
54 |
55 | #. module: account_invoice_commission
56 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__commissioned_invoice_ids
57 | msgid "Commissioned invoices"
58 | msgstr "Provisionierte Rechnungen"
59 |
60 | #. module: account_invoice_commission
61 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_move_form
62 | msgid "Commissions"
63 | msgstr "Provisionen"
64 |
65 | #. module: account_invoice_commission
66 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__create_uid
67 | msgid "Created by"
68 | msgstr "Angelegt durch"
69 |
70 | #. module: account_invoice_commission
71 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__create_date
72 | msgid "Created on"
73 | msgstr "Angelegt am"
74 |
75 | #. module: account_invoice_commission
76 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__customer_id
77 | msgid "Customer"
78 | msgstr "Kunde"
79 |
80 | #. module: account_invoice_commission
81 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__display_name
82 | msgid "Display Name"
83 | msgstr "Anzeigebezeichnung"
84 |
85 | #. module: account_invoice_commission
86 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__date_end
87 | msgid "End Date"
88 | msgstr "Enddatum"
89 |
90 | #. module: account_invoice_commission
91 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__date_end
92 | msgid "Ending valid for this rule"
93 | msgstr "Gültigkeitsende dieser Regel"
94 |
95 | #. module: account_invoice_commission
96 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__sequence
97 | msgid ""
98 | "Gives the order in which the rules items will be checked. The evaluation "
99 | "gives highest priority to lowest sequence and stops as soon as a matching "
100 | "item is found."
101 | msgstr ""
102 | "Liefert die Reihenfolge, in der die Positionen dieser Regeln geprüft werden."
103 | " Die Auswertung liefert die höhere Priorität für kleiner Folgenwerte und "
104 | "wird mit erster Übereinstimmung beendet."
105 |
106 | #. module: account_invoice_commission
107 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__id
108 | msgid "ID"
109 | msgstr "ID"
110 |
111 | #. module: account_invoice_commission
112 | #: model:ir.model,name:account_invoice_commission.model_account_move
113 | msgid "Journal Entries"
114 | msgstr ""
115 |
116 | #. module: account_invoice_commission
117 | #: model:ir.model,name:account_invoice_commission.model_account_move_line
118 | msgid "Journal Item"
119 | msgstr ""
120 |
121 | #. module: account_invoice_commission
122 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule____last_update
123 | msgid "Last Modified on"
124 | msgstr "Zuletzt verändert am"
125 |
126 | #. module: account_invoice_commission
127 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__date_last_payment
128 | msgid "Last Payment Date"
129 | msgstr "Letztes Zahldatum"
130 |
131 | #. module: account_invoice_commission
132 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__write_uid
133 | msgid "Last Updated by"
134 | msgstr "Zuletzt aktualisiert durch"
135 |
136 | #. module: account_invoice_commission
137 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__write_date
138 | msgid "Last Updated on"
139 | msgstr "Zuletzt aktualisiert am"
140 |
141 | #. module: account_invoice_commission
142 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__min_amount
143 | msgid "Min Amount"
144 | msgstr "Mindestbetrag"
145 |
146 | #. module: account_invoice_commission
147 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__min_amount
148 | msgid "Minimun Amount on company currency of the invoice to be evaluated"
149 | msgstr "Mindestbetrag der ausgewerteten Rechnung in Hauswährung"
150 |
151 | #. module: account_invoice_commission
152 | #: code:addons/account_invoice_commission/models/account_commission_rule.py:0
153 | #, python-format
154 | msgid ""
155 | "No commission rule found for product id \"%s\", partner id \"%s\" date "
156 | "\"%s\" and customer \"%s\""
157 | msgstr ""
158 | "Keine Provisionsregel für Product ID \"%s\", Partner ID \"%s\", Datum \"%s\""
159 | " und Kunde \"%s\""
160 |
161 | #. module: account_invoice_commission
162 | #: code:addons/account_invoice_commission/models/account_commission_rule.py:0
163 | #, python-format
164 | msgid "No commission rule found partner id \"%s\" date \"%s\" and customer \"%s\""
165 | msgstr ""
166 |
167 | #. module: account_invoice_commission
168 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_account_invoice_filter
169 | msgid "Not Commissioned"
170 | msgstr "Nicht provisioniert"
171 |
172 | #. module: account_invoice_commission
173 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__partner_id
174 | msgid "Partner"
175 | msgstr "Partner"
176 |
177 | #. module: account_invoice_commission
178 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__partner_user_id
179 | msgid "Partner User"
180 | msgstr "Partner-Nutzer"
181 |
182 | #. module: account_invoice_commission
183 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__percent_commission
184 | msgid "Percentage Commission"
185 | msgstr "Provisionssatz"
186 |
187 | #. module: account_invoice_commission
188 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__categ_id
189 | msgid "Product Category"
190 | msgstr "Produktkategorie"
191 |
192 | #. module: account_invoice_commission
193 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__product_tmpl_id
194 | msgid "Product Template"
195 | msgstr "Produktvorlage"
196 |
197 | #. module: account_invoice_commission
198 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__sequence
199 | msgid "Sequence"
200 | msgstr "Reihenfolge"
201 |
202 | #. module: account_invoice_commission
203 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__categ_id
204 | msgid ""
205 | "Specify a product category if this rule only applies to products belonging "
206 | "to this category or its children categories. Keep empty otherwise."
207 | msgstr ""
208 | "Geben Sie eine Produktkategorie an, wenn diese Regel nur auf Produkte dieser"
209 | " Kategorie oder deren Unterklassen anzuwenden ist. Ansonsten leer lassen."
210 |
211 | #. module: account_invoice_commission
212 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__product_tmpl_id
213 | msgid ""
214 | "Specify a template if this rule only applies to one product template. Keep "
215 | "empty otherwise."
216 | msgstr ""
217 | "Geben Sie eine Vorlage an, wenn diese Regel nur auf eine Produktvorlage "
218 | "anzuwenden ist. Ansonsten leer lassen."
219 |
220 | #. module: account_invoice_commission
221 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__date_start
222 | msgid "Start Date"
223 | msgstr "Anfangsdatum"
224 |
225 | #. module: account_invoice_commission
226 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__date_start
227 | msgid "Starting date for this rule"
228 | msgstr "Anfangsdatum für die Gültigkeit dieser Regel"
229 |
230 | #. module: account_invoice_commission
231 | #: model:ir.model.fields,help:account_invoice_commission.field_account_move__commissioned_invoice_ids
232 | msgid "The invoices that this commission invoice is commissioning"
233 | msgstr "Die Rechnungen, die diese Provisionsabrechnung abrechnet"
234 |
235 | #. module: account_invoice_commission
236 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_invoice_tree
237 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_move_form
238 | msgid "Total"
239 | msgstr "Gesamt"
240 |
--------------------------------------------------------------------------------
/account_invoice_commission/i18n/es.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_commission
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2024
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 18.0+e\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2024-11-20 15:10+0000\n"
13 | "PO-Revision-Date: 2024-11-14 20:11+0000\n"
14 | "Last-Translator: Juan José Scarafía , 2024\n"
15 | "Language-Team: Spanish (https://app.transifex.com/adhoc/teams/46451/es/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: es\n"
20 | "Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n"
21 |
22 | #. module: account_invoice_commission
23 | #: model:ir.model,name:account_invoice_commission.model_account_commission_rule
24 | msgid "Account Commission Rule"
25 | msgstr "Regla de Comisión de Cuenta"
26 |
27 | #. module: account_invoice_commission
28 | #: model:ir.model.fields,help:account_invoice_commission.field_account_bank_statement_line__commission_invoice_ids
29 | #: model:ir.model.fields,help:account_invoice_commission.field_account_move__commission_invoice_ids
30 | msgid "Commision invoices where this invoice is commissioned"
31 | msgstr "Facturas de comisiones donde se liquida esta factura."
32 |
33 | #. module: account_invoice_commission
34 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_move_form
35 | msgid "Commission"
36 | msgstr "Comisión"
37 |
38 | #. module: account_invoice_commission
39 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_bank_statement_line__commission_amount
40 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__commission_amount
41 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move_line__commission_amount
42 | msgid "Commission Amount"
43 | msgstr "Importe de la Comisión"
44 |
45 | #. module: account_invoice_commission
46 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_bank_statement_line__commission_invoice_ids
47 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__commission_invoice_ids
48 | msgid "Commission Invoices"
49 | msgstr "Facturas de comisiones"
50 |
51 | #. module: account_invoice_commission
52 | #: model:ir.actions.act_window,name:account_invoice_commission.action_commission_rule_form
53 | #: model:ir.ui.menu,name:account_invoice_commission.menu_action_commission_rule_form
54 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.account_commission_rule_tree
55 | msgid "Commission Rules"
56 | msgstr "Reglas de Comisión"
57 |
58 | #. module: account_invoice_commission
59 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_bank_statement_line__commissioned_invoice_ids
60 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__commissioned_invoice_ids
61 | msgid "Commissioned invoices"
62 | msgstr "Facturas comisionadas"
63 |
64 | #. module: account_invoice_commission
65 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_move_form
66 | msgid "Commissions"
67 | msgstr "Comisiones"
68 |
69 | #. module: account_invoice_commission
70 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__create_uid
71 | msgid "Created by"
72 | msgstr "Creado por"
73 |
74 | #. module: account_invoice_commission
75 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__create_date
76 | msgid "Created on"
77 | msgstr "Creado el"
78 |
79 | #. module: account_invoice_commission
80 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__customer_id
81 | msgid "Customer"
82 | msgstr "Cliente"
83 |
84 | #. module: account_invoice_commission
85 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__display_name
86 | msgid "Display Name"
87 | msgstr "Nombre a Mostrar"
88 |
89 | #. module: account_invoice_commission
90 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__date_end
91 | msgid "End Date"
92 | msgstr "Fecha de Fin"
93 |
94 | #. module: account_invoice_commission
95 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__date_end
96 | msgid "Ending valid for this rule"
97 | msgstr "Final válido para esta regla."
98 |
99 | #. module: account_invoice_commission
100 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__sequence
101 | msgid ""
102 | "Gives the order in which the rules items will be checked. The evaluation "
103 | "gives highest priority to lowest sequence and stops as soon as a matching "
104 | "item is found."
105 | msgstr ""
106 | "Da el orden en que se verifican los elementos de las reglas. La evaluación "
107 | "otorga la mayor prioridad a la secuencia más baja y se detiene tan pronto "
108 | "como se encuentra un elemento coincidente."
109 |
110 | #. module: account_invoice_commission
111 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__id
112 | msgid "ID"
113 | msgstr "ID (identificación)"
114 |
115 | #. module: account_invoice_commission
116 | #: model:ir.model,name:account_invoice_commission.model_account_move
117 | msgid "Journal Entry"
118 | msgstr "Asiento contable"
119 |
120 | #. module: account_invoice_commission
121 | #: model:ir.model,name:account_invoice_commission.model_account_move_line
122 | msgid "Journal Item"
123 | msgstr "Apunte contable"
124 |
125 | #. module: account_invoice_commission
126 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_bank_statement_line__date_last_payment
127 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__date_last_payment
128 | msgid "Last Payment Date"
129 | msgstr "Última Fecha de Pago"
130 |
131 | #. module: account_invoice_commission
132 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__write_uid
133 | msgid "Last Updated by"
134 | msgstr "Última actualización por"
135 |
136 | #. module: account_invoice_commission
137 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__write_date
138 | msgid "Last Updated on"
139 | msgstr "Última actualización el"
140 |
141 | #. module: account_invoice_commission
142 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__min_amount
143 | msgid "Min Amount"
144 | msgstr "Cantidad mínima"
145 |
146 | #. module: account_invoice_commission
147 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__min_amount
148 | msgid "Minimun Amount on company currency of the invoice to be evaluated"
149 | msgstr "Importe mínimo en la moneda de la compañía de la factura a evaluar."
150 |
151 | #. module: account_invoice_commission
152 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_account_invoice_filter
153 | msgid "Not Commissioned"
154 | msgstr "No Comisionado"
155 |
156 | #. module: account_invoice_commission
157 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__partner_id
158 | msgid "Partner"
159 | msgstr "Empresa"
160 |
161 | #. module: account_invoice_commission
162 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_bank_statement_line__partner_user_id
163 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__partner_user_id
164 | msgid "Partner User"
165 | msgstr "Usuario de la empresa"
166 |
167 | #. module: account_invoice_commission
168 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__percent_commission
169 | msgid "Percentage Commission"
170 | msgstr "Porcentaje de Comision"
171 |
172 | #. module: account_invoice_commission
173 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__categ_id
174 | msgid "Product Category"
175 | msgstr "Categoría de Producto"
176 |
177 | #. module: account_invoice_commission
178 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__product_tmpl_id
179 | msgid "Product Template"
180 | msgstr "Plantilla de Producto"
181 |
182 | #. module: account_invoice_commission
183 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__sequence
184 | msgid "Sequence"
185 | msgstr "Secuencia"
186 |
187 | #. module: account_invoice_commission
188 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__categ_id
189 | msgid ""
190 | "Specify a product category if this rule only applies to products belonging "
191 | "to this category or its children categories. Keep empty otherwise."
192 | msgstr ""
193 | "Especifique una categoría de producto si esta regla solo se aplica a los "
194 | "productos que pertenecen a esta categoría o sus categorías secundarias. De "
195 | "lo contrario, mantenga vacío."
196 |
197 | #. module: account_invoice_commission
198 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__product_tmpl_id
199 | msgid ""
200 | "Specify a template if this rule only applies to one product template. Keep "
201 | "empty otherwise."
202 | msgstr ""
203 | "Especifique una plantilla si esta regla solo se aplica a una plantilla de "
204 | "producto. De lo contrario, mantenga vacío."
205 |
206 | #. module: account_invoice_commission
207 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__date_start
208 | msgid "Start Date"
209 | msgstr "Fecha de inicio"
210 |
211 | #. module: account_invoice_commission
212 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__date_start
213 | msgid "Starting date for this rule"
214 | msgstr "Fecha de inicio para esta regla"
215 |
216 | #. module: account_invoice_commission
217 | #: model:ir.model.fields,help:account_invoice_commission.field_account_bank_statement_line__commissioned_invoice_ids
218 | #: model:ir.model.fields,help:account_invoice_commission.field_account_move__commissioned_invoice_ids
219 | msgid "The invoices that this commission invoice is commissioning"
220 | msgstr "Facturas comisionadas en esta factura de comisión"
221 |
222 | #. module: account_invoice_commission
223 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_invoice_tree
224 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_move_form
225 | msgid "Total"
226 | msgstr ""
227 |
--------------------------------------------------------------------------------
/account_invoice_commission/i18n/pt_BR.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_commission
4 | #
5 | # Translators:
6 | # Carlos Palmarante , 2019
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 11.0\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2019-04-05 14:50+0000\n"
13 | "PO-Revision-Date: 2018-04-04 17:38+0000\n"
14 | "Last-Translator: Carlos Palmarante , 2019\n"
15 | "Language-Team: Portuguese (Brazil) (https://www.transifex.com/adhoc/teams/46451/pt_BR/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: pt_BR\n"
20 | "Plural-Forms: nplurals=2; plural=(n > 1);\n"
21 |
22 | #. module: account_invoice_commission
23 | #: model:ir.model.fields,help:account_invoice_commission.field_account_invoice_commission_invoice_ids
24 | msgid "Commision invoices where this invoice is commissioned"
25 | msgstr ""
26 |
27 | #. module: account_invoice_commission
28 | #: model:ir.ui.view,arch_db:account_invoice_commission.invoice_supplier_form
29 | msgid "Commission"
30 | msgstr ""
31 |
32 | #. module: account_invoice_commission
33 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_invoice_commission_amount
34 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_invoice_line_commission_amount
35 | msgid "Commission Amount"
36 | msgstr ""
37 |
38 | #. module: account_invoice_commission
39 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_invoice_commission_invoice_ids
40 | msgid "Commission Invoices"
41 | msgstr ""
42 |
43 | #. module: account_invoice_commission
44 | #: model:ir.actions.act_window,name:account_invoice_commission.action_commission_rule_form
45 | #: model:ir.ui.menu,name:account_invoice_commission.menu_action_commission_rule_form
46 | #: model:ir.ui.view,arch_db:account_invoice_commission.account_commission_rule_tree
47 | msgid "Commission Rules"
48 | msgstr ""
49 |
50 | #. module: account_invoice_commission
51 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_invoice_commissioned_invoice_ids
52 | msgid "Commissioned invoices"
53 | msgstr ""
54 |
55 | #. module: account_invoice_commission
56 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_create_uid
57 | msgid "Created by"
58 | msgstr ""
59 |
60 | #. module: account_invoice_commission
61 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_create_date
62 | msgid "Created on"
63 | msgstr ""
64 |
65 | #. module: account_invoice_commission
66 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_customer_id
67 | msgid "Customer"
68 | msgstr ""
69 |
70 | #. module: account_invoice_commission
71 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_display_name
72 | msgid "Display Name"
73 | msgstr ""
74 |
75 | #. module: account_invoice_commission
76 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_date_end
77 | msgid "End Date"
78 | msgstr ""
79 |
80 | #. module: account_invoice_commission
81 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule_date_end
82 | msgid "Ending valid for this rule"
83 | msgstr ""
84 |
85 | #. module: account_invoice_commission
86 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule_sequence
87 | msgid ""
88 | "Gives the order in which the rules items will be checked. The evaluation "
89 | "gives highest priority to lowest sequence and stops as soon as a matching "
90 | "item is found."
91 | msgstr ""
92 |
93 | #. module: account_invoice_commission
94 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_id
95 | msgid "ID"
96 | msgstr ""
97 |
98 | #. module: account_invoice_commission
99 | #: model:ir.model,name:account_invoice_commission.model_account_invoice
100 | msgid "Invoice"
101 | msgstr "Fatura"
102 |
103 | #. module: account_invoice_commission
104 | #: model:ir.model,name:account_invoice_commission.model_account_invoice_line
105 | msgid "Invoice Line"
106 | msgstr ""
107 |
108 | #. module: account_invoice_commission
109 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule___last_update
110 | msgid "Last Modified on"
111 | msgstr ""
112 |
113 | #. module: account_invoice_commission
114 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_invoice_date_last_payment
115 | msgid "Last Payment Date"
116 | msgstr ""
117 |
118 | #. module: account_invoice_commission
119 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_write_uid
120 | msgid "Last Updated by"
121 | msgstr ""
122 |
123 | #. module: account_invoice_commission
124 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_write_date
125 | msgid "Last Updated on"
126 | msgstr ""
127 |
128 | #. module: account_invoice_commission
129 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_min_amount
130 | msgid "Min Amount"
131 | msgstr ""
132 |
133 | #. module: account_invoice_commission
134 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule_min_amount
135 | msgid "Minimun Amount on company currency of the invoice to be evaluated"
136 | msgstr ""
137 |
138 | #. module: account_invoice_commission
139 | #: code:addons/account_invoice_commission/models/account_commission_rule.py:112
140 | #, python-format
141 | msgid ""
142 | "No commission rule found for product id \"%s\", partner id \"%s\" date "
143 | "\"%s\" and customer \"%s\""
144 | msgstr ""
145 |
146 | #. module: account_invoice_commission
147 | #: model:ir.ui.view,arch_db:account_invoice_commission.view_account_invoice_filter
148 | msgid "Not Commissioned"
149 | msgstr ""
150 |
151 | #. module: account_invoice_commission
152 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_partner_id
153 | msgid "Partner"
154 | msgstr ""
155 |
156 | #. module: account_invoice_commission
157 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_invoice_partner_user_id
158 | msgid "Partner User"
159 | msgstr ""
160 |
161 | #. module: account_invoice_commission
162 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_percent_commission
163 | msgid "Percentage Commission"
164 | msgstr ""
165 |
166 | #. module: account_invoice_commission
167 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_categ_id
168 | msgid "Product Category"
169 | msgstr ""
170 |
171 | #. module: account_invoice_commission
172 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_product_tmpl_id
173 | msgid "Product Template"
174 | msgstr ""
175 |
176 | #. module: account_invoice_commission
177 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_sequence
178 | msgid "Sequence"
179 | msgstr ""
180 |
181 | #. module: account_invoice_commission
182 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule_categ_id
183 | msgid ""
184 | "Specify a product category if this rule only applies to products belonging "
185 | "to this category or its children categories. Keep empty otherwise."
186 | msgstr ""
187 |
188 | #. module: account_invoice_commission
189 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule_product_tmpl_id
190 | msgid ""
191 | "Specify a template if this rule only applies to one product template. Keep "
192 | "empty otherwise."
193 | msgstr ""
194 |
195 | #. module: account_invoice_commission
196 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule_date_start
197 | msgid "Start Date"
198 | msgstr ""
199 |
200 | #. module: account_invoice_commission
201 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule_date_start
202 | msgid "Starting date for this rule"
203 | msgstr ""
204 |
205 | #. module: account_invoice_commission
206 | #: model:ir.model.fields,help:account_invoice_commission.field_account_invoice_commissioned_invoice_ids
207 | msgid "The invoices that this commission invoice is commissioning"
208 | msgstr ""
209 |
210 | #. module: account_invoice_commission
211 | #: model:ir.ui.view,arch_db:account_invoice_commission.invoice_form
212 | #: model:ir.ui.view,arch_db:account_invoice_commission.invoice_tree
213 | msgid "Total"
214 | msgstr ""
215 |
216 | #. module: account_invoice_commission
217 | #: model:ir.model,name:account_invoice_commission.model_account_commission_rule
218 | msgid "account.commission.rule"
219 | msgstr ""
220 |
--------------------------------------------------------------------------------
/account_invoice_commission/i18n/ru.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_commission
4 | #
5 | # Translators:
6 | # Irina Fedulova , 2020
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 13.0\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2021-01-07 17:47+0000\n"
13 | "PO-Revision-Date: 2020-07-15 16:43+0000\n"
14 | "Last-Translator: Irina Fedulova , 2020\n"
15 | "Language-Team: Russian (https://www.transifex.com/adhoc/teams/46451/ru/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: ru\n"
20 | "Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n"
21 |
22 | #. module: account_invoice_commission
23 | #: model:ir.model,name:account_invoice_commission.model_account_commission_rule
24 | msgid "Account Commission Rule"
25 | msgstr ""
26 |
27 | #. module: account_invoice_commission
28 | #: model:ir.model.fields,help:account_invoice_commission.field_account_move__commission_invoice_ids
29 | msgid "Commision invoices where this invoice is commissioned"
30 | msgstr ""
31 |
32 | #. module: account_invoice_commission
33 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_move_form
34 | msgid "Commission"
35 | msgstr ""
36 |
37 | #. module: account_invoice_commission
38 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__commission_amount
39 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move_line__commission_amount
40 | msgid "Commission Amount"
41 | msgstr ""
42 |
43 | #. module: account_invoice_commission
44 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__commission_invoice_ids
45 | msgid "Commission Invoices"
46 | msgstr ""
47 |
48 | #. module: account_invoice_commission
49 | #: model:ir.actions.act_window,name:account_invoice_commission.action_commission_rule_form
50 | #: model:ir.ui.menu,name:account_invoice_commission.menu_action_commission_rule_form
51 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.account_commission_rule_tree
52 | msgid "Commission Rules"
53 | msgstr ""
54 |
55 | #. module: account_invoice_commission
56 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__commissioned_invoice_ids
57 | msgid "Commissioned invoices"
58 | msgstr ""
59 |
60 | #. module: account_invoice_commission
61 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_move_form
62 | msgid "Commissions"
63 | msgstr ""
64 |
65 | #. module: account_invoice_commission
66 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__create_uid
67 | msgid "Created by"
68 | msgstr "Создано"
69 |
70 | #. module: account_invoice_commission
71 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__create_date
72 | msgid "Created on"
73 | msgstr "Создано"
74 |
75 | #. module: account_invoice_commission
76 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__customer_id
77 | msgid "Customer"
78 | msgstr "Покупатель"
79 |
80 | #. module: account_invoice_commission
81 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__display_name
82 | msgid "Display Name"
83 | msgstr "Показать имя"
84 |
85 | #. module: account_invoice_commission
86 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__date_end
87 | msgid "End Date"
88 | msgstr "Дата окончания"
89 |
90 | #. module: account_invoice_commission
91 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__date_end
92 | msgid "Ending valid for this rule"
93 | msgstr ""
94 |
95 | #. module: account_invoice_commission
96 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__sequence
97 | msgid ""
98 | "Gives the order in which the rules items will be checked. The evaluation "
99 | "gives highest priority to lowest sequence and stops as soon as a matching "
100 | "item is found."
101 | msgstr ""
102 |
103 | #. module: account_invoice_commission
104 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__id
105 | msgid "ID"
106 | msgstr "ID"
107 |
108 | #. module: account_invoice_commission
109 | #: model:ir.model,name:account_invoice_commission.model_account_move
110 | msgid "Journal Entries"
111 | msgstr ""
112 |
113 | #. module: account_invoice_commission
114 | #: model:ir.model,name:account_invoice_commission.model_account_move_line
115 | msgid "Journal Item"
116 | msgstr ""
117 |
118 | #. module: account_invoice_commission
119 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule____last_update
120 | msgid "Last Modified on"
121 | msgstr "Изменено"
122 |
123 | #. module: account_invoice_commission
124 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__date_last_payment
125 | msgid "Last Payment Date"
126 | msgstr "Дата последней оплаты"
127 |
128 | #. module: account_invoice_commission
129 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__write_uid
130 | msgid "Last Updated by"
131 | msgstr "Обновлено"
132 |
133 | #. module: account_invoice_commission
134 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__write_date
135 | msgid "Last Updated on"
136 | msgstr "Обновлено"
137 |
138 | #. module: account_invoice_commission
139 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__min_amount
140 | msgid "Min Amount"
141 | msgstr "Мин. сумма"
142 |
143 | #. module: account_invoice_commission
144 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__min_amount
145 | msgid "Minimun Amount on company currency of the invoice to be evaluated"
146 | msgstr ""
147 |
148 | #. module: account_invoice_commission
149 | #: code:addons/account_invoice_commission/models/account_commission_rule.py:0
150 | #, python-format
151 | msgid ""
152 | "No commission rule found for product id \"%s\", partner id \"%s\" date "
153 | "\"%s\" and customer \"%s\""
154 | msgstr ""
155 |
156 | #. module: account_invoice_commission
157 | #: code:addons/account_invoice_commission/models/account_commission_rule.py:0
158 | #, python-format
159 | msgid "No commission rule found partner id \"%s\" date \"%s\" and customer \"%s\""
160 | msgstr ""
161 |
162 | #. module: account_invoice_commission
163 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_account_invoice_filter
164 | msgid "Not Commissioned"
165 | msgstr ""
166 |
167 | #. module: account_invoice_commission
168 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__partner_id
169 | msgid "Partner"
170 | msgstr "Партнер"
171 |
172 | #. module: account_invoice_commission
173 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_move__partner_user_id
174 | msgid "Partner User"
175 | msgstr ""
176 |
177 | #. module: account_invoice_commission
178 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__percent_commission
179 | msgid "Percentage Commission"
180 | msgstr ""
181 |
182 | #. module: account_invoice_commission
183 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__categ_id
184 | msgid "Product Category"
185 | msgstr "Категория товара"
186 |
187 | #. module: account_invoice_commission
188 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__product_tmpl_id
189 | msgid "Product Template"
190 | msgstr "Шаблон товара"
191 |
192 | #. module: account_invoice_commission
193 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__sequence
194 | msgid "Sequence"
195 | msgstr ""
196 |
197 | #. module: account_invoice_commission
198 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__categ_id
199 | msgid ""
200 | "Specify a product category if this rule only applies to products belonging "
201 | "to this category or its children categories. Keep empty otherwise."
202 | msgstr ""
203 |
204 | #. module: account_invoice_commission
205 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__product_tmpl_id
206 | msgid ""
207 | "Specify a template if this rule only applies to one product template. Keep "
208 | "empty otherwise."
209 | msgstr ""
210 |
211 | #. module: account_invoice_commission
212 | #: model:ir.model.fields,field_description:account_invoice_commission.field_account_commission_rule__date_start
213 | msgid "Start Date"
214 | msgstr "Дата начала"
215 |
216 | #. module: account_invoice_commission
217 | #: model:ir.model.fields,help:account_invoice_commission.field_account_commission_rule__date_start
218 | msgid "Starting date for this rule"
219 | msgstr "Дата вступления в силу этого правила"
220 |
221 | #. module: account_invoice_commission
222 | #: model:ir.model.fields,help:account_invoice_commission.field_account_move__commissioned_invoice_ids
223 | msgid "The invoices that this commission invoice is commissioning"
224 | msgstr ""
225 |
226 | #. module: account_invoice_commission
227 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_invoice_tree
228 | #: model_terms:ir.ui.view,arch_db:account_invoice_commission.view_move_form
229 | msgid "Total"
230 | msgstr "Всего"
231 |
--------------------------------------------------------------------------------
/account_invoice_commission/models/__init__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from . import account_move
6 | from . import account_move_line
7 | from . import account_commission_rule
8 |
--------------------------------------------------------------------------------
/account_invoice_commission/models/account_commission_rule.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from odoo import fields, models
6 |
7 |
8 | class AccountCommissionRule(models.Model):
9 | _name = "account.commission.rule"
10 | _order = "sequence"
11 | _description = "Account Commission Rule"
12 |
13 | sequence = fields.Integer(
14 | required=True,
15 | default=10,
16 | help="Gives the order in which the rules items will be checked. "
17 | "The evaluation gives highest priority to lowest sequence and stops "
18 | "as soon as a matching item is found.",
19 | )
20 | date_start = fields.Date(
21 | "Start Date",
22 | help="Starting date for this rule",
23 | )
24 | date_end = fields.Date("End Date", help="Ending valid for this rule")
25 | partner_id = fields.Many2one(
26 | "res.partner",
27 | ondelete="cascade",
28 | auto_join=True,
29 | )
30 | customer_id = fields.Many2one(
31 | "res.partner",
32 | auto_join=True,
33 | ondelete="cascade",
34 | context={"res_partner_search_mode": "customer"},
35 | )
36 | # con prod template ya esta bien, no hace falta product
37 | product_tmpl_id = fields.Many2one(
38 | "product.template",
39 | "Product Template",
40 | auto_join=True,
41 | ondelete="cascade",
42 | help="Specify a template if this rule only applies to one product " "template. Keep empty otherwise.",
43 | )
44 | categ_id = fields.Many2one(
45 | "product.category",
46 | "Product Category",
47 | auto_join=True,
48 | ondelete="cascade",
49 | help="Specify a product category if this rule only applies to "
50 | "products belonging to this category or its children categories. "
51 | "Keep empty otherwise.",
52 | )
53 | min_amount = fields.Float(
54 | help="Minimun Amount on company currency of the invoice to be " "evaluated",
55 | default=0.0,
56 | )
57 | percent_commission = fields.Float("Percentage Commission")
58 |
59 | def _get_rule_domain(self, date, product, partner_id, customer, amount):
60 | domain = [
61 | "|",
62 | ("date_start", "=", False),
63 | ("date_start", "<=", date),
64 | "|",
65 | ("date_end", "=", False),
66 | ("date_end", ">=", date),
67 | "|",
68 | ("min_amount", "=", 0.0),
69 | ("min_amount", "<=", amount),
70 | ("partner_id", "in", [False, partner_id]),
71 | ("customer_id", "in", [False, customer.id]),
72 | ]
73 | # para lineas sin producto buscamos solamente las de false
74 | if not product:
75 | domain += [("product_tmpl_id", "=", False), ("categ_id", "=", False)]
76 | else:
77 | domain += [
78 | ("product_tmpl_id", "in", [False, product.product_tmpl_id.id]),
79 | "|",
80 | ("categ_id", "=", False),
81 | ("categ_id", "parent_of", product.categ_id.id),
82 | ]
83 | return domain
84 |
85 | def _get_rule(self, date, product, partner_id, customer, amount):
86 | domain = self._get_rule_domain(date, product, partner_id, customer, amount)
87 | return self.search(domain, limit=1)
88 |
--------------------------------------------------------------------------------
/account_invoice_commission/models/account_move.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | import logging
6 |
7 | from odoo import api, fields, models
8 |
9 | _logger = logging.getLogger(__name__)
10 |
11 |
12 | class AccountMove(models.Model):
13 | _inherit = "account.move"
14 |
15 | commission_amount = fields.Monetary(
16 | compute="_compute_commission_amount",
17 | currency_field="company_currency_id",
18 | )
19 | commission_invoice_ids = fields.Many2many(
20 | "account.move",
21 | "account_invoice_commission_inv_rel",
22 | "commissioned_id",
23 | "commission_id",
24 | string="Commission Invoices",
25 | domain=[("move_type", "in", ("in_invoice", "in_refund"))],
26 | readonly=True,
27 | help="Commision invoices where this invoice is commissioned",
28 | copy=False,
29 | )
30 | commissioned_invoice_ids = fields.Many2many(
31 | "account.move",
32 | "account_invoice_commission_inv_rel",
33 | "commission_id",
34 | "commissioned_id",
35 | # 'commission_invoice_id',
36 | domain=[("move_type", "in", ("out_invoice", "out_refund"))],
37 | string="Commissioned invoices",
38 | readonly=True,
39 | help="The invoices that this commission invoice is commissioning",
40 | copy=False,
41 | )
42 | # este campo lo agregamos aca y no en account_usability para no perjudicar
43 | # a quien no usa comisiones en temas de performance
44 | date_last_payment = fields.Date(
45 | compute="_compute_date_last_payment",
46 | string="Last Payment Date",
47 | store=True,
48 | )
49 | partner_user_id = fields.Many2one(
50 | "res.users",
51 | compute="_compute_partner_user",
52 | )
53 |
54 | @api.depends("partner_id.user_ids")
55 | def _compute_partner_user(self):
56 | for rec in self:
57 | users = rec.partner_id.user_ids
58 | rec.partner_user_id = users and users[0] or False
59 |
60 | # dependemos de amount_residual que depende de line_ids.amount_residual porque no hay ningun campo almacenado que
61 | # vaya derecho contra las lineas de pago, toda esa logica ya la tiene implementada el campo
62 | @api.depends("amount_residual")
63 | def _compute_date_last_payment(self):
64 | for rec in self.filtered(lambda x: x.move_type != "entry" and x.state == "posted"):
65 | payments = rec._get_reconciled_payments()
66 | rec.date_last_payment = payments and payments[-1].date
67 |
68 | @api.depends("invoice_line_ids.commission_amount")
69 | @api.depends_context("commissioned_partner_id")
70 | def _compute_commission_amount(self):
71 | commissioned_partner_id = self._context.get("commissioned_partner_id")
72 | if commissioned_partner_id:
73 | _logger.info("Computing commission amount")
74 | for rec in self:
75 | rec.commission_amount = sum(rec.mapped("invoice_line_ids.commission_amount"))
76 | else:
77 | self.commission_amount = 0.0
78 |
79 | def web_read(self, specification):
80 | """Esto lo agregamos para propagar el contexto del commissioned_partner_id
81 | La idea es que si esta presente el campo commissioned_invoice_ids agregamos en el contexto
82 | el commissioned_partner_id y llamamos a super de web_read pisando estos valores."""
83 | res = super().web_read(specification)
84 | for vals, rec in zip(res, self):
85 | partner_id = vals.get("partner_id")
86 | if (
87 | partner_id
88 | and isinstance(partner_id, dict)
89 | and partner_id.get("id")
90 | and "commissioned_invoice_ids" in specification
91 | ):
92 | vals["commissioned_invoice_ids"] = (
93 | super(AccountMove, rec)
94 | .with_context(commissioned_partner_id=vals["partner_id"]["id"])
95 | .web_read({"commissioned_invoice_ids": specification["commissioned_invoice_ids"]})[0][
96 | "commissioned_invoice_ids"
97 | ]
98 | )
99 | return res
100 |
--------------------------------------------------------------------------------
/account_invoice_commission/models/account_move_line.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | import logging
6 |
7 | from odoo import fields, models
8 |
9 | _logger = logging.getLogger(__name__)
10 |
11 |
12 | class AccountMoveLine(models.Model):
13 | _inherit = "account.move.line"
14 |
15 | commission_amount = fields.Monetary(
16 | compute="_compute_commission_amount",
17 | currency_field="company_currency_id",
18 | )
19 |
20 | def _compute_commission_amount(self):
21 | commissioned_partner_id = self._context.get("commissioned_partner_id")
22 | if commissioned_partner_id:
23 | today = fields.Date.context_today(self)
24 | rules = self.env["account.commission.rule"]
25 | _logger.info("Computing commission amount line")
26 | for rec in self:
27 | date = rec.move_id.invoice_date or today
28 | rule = rules._get_rule(
29 | date,
30 | rec.product_id,
31 | commissioned_partner_id,
32 | rec.move_id.commercial_partner_id,
33 | -rec.balance,
34 | )
35 | if rule:
36 | rec.commission_amount = rule.percent_commission * -rec.balance / 100.0
37 | else:
38 | rec.commission_amount = 0.0
39 | else:
40 | self.commission_amount = 0.0
41 |
--------------------------------------------------------------------------------
/account_invoice_commission/security/ir.model.access.csv:
--------------------------------------------------------------------------------
1 | id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
2 | access_account_commission_rule_employee,access_account_commission_rule_employee,model_account_commission_rule,base.group_user,1,0,0,0
3 | access_account_commission_rule_manager,access_account_commission_rule_manager,model_account_commission_rule,account.group_account_manager,1,1,1,1
4 |
--------------------------------------------------------------------------------
/account_invoice_commission/views/account_commission_rule_view.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | account.commission.rule.list
5 | account.commission.rule
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 | Commission Rules
23 | account.commission.rule
24 | list,form
25 |
26 |
27 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/account_invoice_commission/views/account_move_view.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | account.move.form
6 | account.move
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 | account.invoice.list
29 | account.move
30 | primary
31 | 90
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 | account.invoice.select
42 | account.move
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
--------------------------------------------------------------------------------
/account_invoice_control/README.rst:
--------------------------------------------------------------------------------
1 | .. |company| replace:: ADHOC SA
2 |
3 | .. |company_logo| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-logo.png
4 | :alt: ADHOC SA
5 | :target: https://www.adhoc.com.ar
6 |
7 | .. |icon| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-icon.png
8 |
9 | .. image:: https://img.shields.io/badge/license-AGPL--3-blue.png
10 | :target: https://www.gnu.org/licenses/agpl
11 | :alt: License: AGPL-3
12 |
13 | ==========================
14 | Invoice origin and control
15 | ==========================
16 |
17 | * It also creates a new users group "Restrict Edit Invoice", users in that group can not edit lines of invoices generated from Sale Orders
18 |
19 | Installation
20 | ============
21 |
22 | To install this module, you need to:
23 |
24 | #. Only need to install the module
25 |
26 | Configuration
27 | =============
28 |
29 | To configure this module, you need to:
30 |
31 | #. Set "Restrict Edit Invoice" to the users you want to restrict
32 |
33 | Usage
34 | =====
35 |
36 | To use this module, you need to:
37 |
38 | #. Go to ...
39 |
40 | .. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
41 | :alt: Try me on Runbot
42 | :target: http://runbot.adhoc.com.ar/
43 |
44 | Bug Tracker
45 | ===========
46 |
47 | Bugs are tracked on `GitHub Issues
48 | `_. In case of trouble, please
49 | check there if your issue has already been reported. If you spotted it first,
50 | help us smashing it by providing a detailed and welcomed feedback.
51 |
52 | Credits
53 | =======
54 |
55 | Images
56 | ------
57 |
58 | * |company| |icon|
59 |
60 | Contributors
61 | ------------
62 |
63 | Maintainer
64 | ----------
65 |
66 | |company_logo|
67 |
68 | This module is maintained by the |company|.
69 |
70 | To contribute to this module, please visit https://www.adhoc.com.ar.
71 |
--------------------------------------------------------------------------------
/account_invoice_control/__init__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from . import models
6 |
--------------------------------------------------------------------------------
/account_invoice_control/__manifest__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | #
3 | # Copyright (C) 2015 ADHOC SA (http://www.adhoc.com.ar)
4 | # All Rights Reserved.
5 | #
6 | # This program is free software: you can redistribute it and/or modify
7 | # it under the terms of the GNU Affero General Public License as
8 | # published by the Free Software Foundation, either version 3 of the
9 | # License, or (at your option) any later version.
10 | #
11 | # This program is distributed in the hope that it will be useful,
12 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | # GNU Affero General Public License for more details.
15 | #
16 | # You should have received a copy of the GNU Affero General Public License
17 | # along with this program. If not, see .
18 | #
19 | ##############################################################################
20 | {
21 | "name": "Account Invoice Control",
22 | "author": "ADHOC SA",
23 | "version": "18.0.1.0.0",
24 | "license": "AGPL-3",
25 | "category": "Accounting & Finance",
26 | "depends": [
27 | "sale_ux",
28 | ],
29 | "data": [
30 | "security/account_invoice_control_security.xml",
31 | "views/account_move_views.xml",
32 | ],
33 | "website": "www.adhoc.com.ar",
34 | "installable": True,
35 | }
36 |
--------------------------------------------------------------------------------
/account_invoice_control/i18n/es.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_control
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2024
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 18.0+e\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2024-11-29 11:09+0000\n"
13 | "PO-Revision-Date: 2024-11-29 11:09+0000\n"
14 | "Last-Translator: Juan José Scarafía , 2024\n"
15 | "Language-Team: Spanish (https://app.transifex.com/adhoc/teams/46451/es/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: es\n"
20 | "Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n"
21 |
22 | #. module: account_invoice_control
23 | #: model:ir.model,name:account_invoice_control.model_account_move
24 | msgid "Journal Entry"
25 | msgstr "Asiento contable"
26 |
27 | #. module: account_invoice_control
28 | #: model:ir.model.fields,field_description:account_invoice_control.field_account_bank_statement_line__restrict_edit_invoice
29 | #: model:ir.model.fields,field_description:account_invoice_control.field_account_move__restrict_edit_invoice
30 | #: model:res.groups,name:account_invoice_control.group_restrict_edit_invoice
31 | msgid "Restrict Edit Invoice"
32 | msgstr "Restringir Edición en las Facturas"
33 |
--------------------------------------------------------------------------------
/account_invoice_control/models/__init__.py:
--------------------------------------------------------------------------------
1 | from . import account_move
2 |
--------------------------------------------------------------------------------
/account_invoice_control/models/account_move.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from odoo import fields, models
6 |
7 |
8 | class AccountMove(models.Model):
9 | _inherit = "account.move"
10 |
11 | restrict_edit_invoice = fields.Boolean(compute="_compute_restrict_edit_invoice")
12 |
13 | def _compute_restrict_edit_invoice(self):
14 | if self.env.user.has_group("account_invoice_control.group_restrict_edit_invoice"):
15 | self.restrict_edit_invoice = True
16 | else:
17 | self.restrict_edit_invoice = False
18 |
--------------------------------------------------------------------------------
/account_invoice_control/security/account_invoice_control_security.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Restrict Edit Invoice
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/account_invoice_control/views/account_move_views.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | account.move.form.inherit
6 | account.move
7 |
8 | 30
9 |
10 |
14 |
15 | state != 'draft' or (has_sales and restrict_edit_invoice)
16 |
17 |
18 | state != 'draft' or (has_sales and restrict_edit_invoice)
19 |
20 |
21 | state != 'draft' or (has_sales and restrict_edit_invoice)
22 |
23 |
24 | state != 'draft' or (has_sales and restrict_edit_invoice)
25 |
26 |
27 | state != 'draft' or (has_sales and restrict_edit_invoice)
28 |
29 |
30 | state != 'draft' or (has_sales and restrict_edit_invoice)
31 |
32 |
33 | state != 'draft' or (has_sales and restrict_edit_invoice)
34 |
35 |
36 | state != 'draft' or (has_sales and restrict_edit_invoice)
37 |
38 |
39 | state != 'draft' or (has_sales and restrict_edit_invoice)
40 |
41 |
42 | state != 'draft' or (has_sales and restrict_edit_invoice)
43 |
44 |
45 | state != 'draft' or (has_sales and restrict_edit_invoice)
46 |
47 |
48 | state != 'draft' or (has_sales and restrict_edit_invoice)
49 |
50 |
51 |
52 |
53 |
54 |
--------------------------------------------------------------------------------
/account_invoice_line_number/README.rst:
--------------------------------------------------------------------------------
1 | .. |company| replace:: ADHOC SA
2 |
3 | .. |company_logo| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-logo.png
4 | :alt: ADHOC SA
5 | :target: https://www.adhoc.com.ar
6 |
7 | .. |icon| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-icon.png
8 |
9 | .. image:: https://img.shields.io/badge/license-AGPL--3-blue.png
10 | :target: https://www.gnu.org/licenses/agpl
11 | :alt: License: AGPL-3
12 |
13 | ===========================
14 | Account Invoice Line Number
15 | ===========================
16 |
17 | This module add automatic numeration for invoice lines.
18 |
19 | Installation
20 | ============
21 |
22 | To install this module, you need to:
23 |
24 | #. Just install the module.
25 |
26 | Configuration
27 | =============
28 |
29 | To configure this module, you need to:
30 |
31 | #. No Configuration need.
32 |
33 | Usage
34 | =====
35 |
36 | To use this module, you need to:
37 |
38 | #. Just use it.
39 |
40 | .. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
41 | :alt: Try me on Runbot
42 | :target: http://runbot.adhoc.com.ar/
43 |
44 | Bug Tracker
45 | ===========
46 |
47 | Bugs are tracked on `GitHub Issues
48 | `_. In case of trouble, please
49 | check there if your issue has already been reported. If you spotted it first,
50 | help us smashing it by providing a detailed and welcomed feedback.
51 |
52 | Credits
53 | =======
54 |
55 | Images
56 | ------
57 |
58 | * |company| |icon|
59 |
60 | Contributors
61 | ------------
62 |
63 | Maintainer
64 | ----------
65 |
66 | |company_logo|
67 |
68 | This module is maintained by the |company|.
69 |
70 | To contribute to this module, please visit https://www.adhoc.com.ar.
71 |
--------------------------------------------------------------------------------
/account_invoice_line_number/__init__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from . import models
6 |
--------------------------------------------------------------------------------
/account_invoice_line_number/__manifest__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | #
3 | # Copyright (C) 2015 ADHOC SA (http://www.adhoc.com.ar)
4 | # All Rights Reserved.
5 | #
6 | # This program is free software: you can redistribute it and/or modify
7 | # it under the terms of the GNU Affero General Public License as
8 | # published by the Free Software Foundation, either version 3 of the
9 | # License, or (at your option) any later version.
10 | #
11 | # This program is distributed in the hope that it will be useful,
12 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | # GNU Affero General Public License for more details.
15 | #
16 | # You should have received a copy of the GNU Affero General Public License
17 | # along with this program. If not, see .
18 | #
19 | ##############################################################################
20 | {
21 | "name": "Account Invoice Line Number",
22 | "version": "15.0.1.1.0",
23 | "category": "Accounting & Finance",
24 | "sequence": 14,
25 | "author": "ADHOC SA",
26 | "website": "www.adhoc.com.ar",
27 | "license": "AGPL-3",
28 | "images": [],
29 | "depends": [
30 | "account",
31 | ],
32 | "data": [
33 | "views/account_move_view.xml",
34 | ],
35 | "demo": [],
36 | "test": [],
37 | "installable": False,
38 | "auto_install": False,
39 | "application": False,
40 | }
41 |
--------------------------------------------------------------------------------
/account_invoice_line_number/i18n/de.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_line_number
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2020
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 13.0\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2021-01-07 17:47+0000\n"
13 | "PO-Revision-Date: 2020-03-11 19:37+0000\n"
14 | "Last-Translator: Juan José Scarafía , 2020\n"
15 | "Language-Team: German (https://www.transifex.com/adhoc/teams/46451/de/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: de\n"
20 | "Plural-Forms: nplurals=2; plural=(n != 1);\n"
21 |
22 | #. module: account_invoice_line_number
23 | #: model:ir.model,name:account_invoice_line_number.model_account_move_line
24 | msgid "Journal Item"
25 | msgstr ""
26 |
27 | #. module: account_invoice_line_number
28 | #: model:ir.model.fields,field_description:account_invoice_line_number.field_account_move_line__number
29 | msgid "Line Nº"
30 | msgstr ""
31 |
32 | #. module: account_invoice_line_number
33 | #: model_terms:ir.ui.view,arch_db:account_invoice_line_number.invoice_form
34 | msgid "nbr"
35 | msgstr "Pos."
36 |
--------------------------------------------------------------------------------
/account_invoice_line_number/i18n/es.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_line_number
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2022
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 15.0+e\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2022-04-25 14:46+0000\n"
13 | "PO-Revision-Date: 2022-04-19 13:54+0000\n"
14 | "Last-Translator: Juan José Scarafía , 2022\n"
15 | "Language-Team: Spanish (https://www.transifex.com/adhoc/teams/133229/es/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: es\n"
20 | "Plural-Forms: nplurals=2; plural=(n != 1);\n"
21 |
22 | #. module: account_invoice_line_number
23 | #: model:ir.model,name:account_invoice_line_number.model_account_move_line
24 | msgid "Journal Item"
25 | msgstr "Apunte contable"
26 |
27 | #. module: account_invoice_line_number
28 | #: model:ir.model.fields,field_description:account_invoice_line_number.field_account_move_line__number
29 | msgid "Line Nº"
30 | msgstr "Línea Nº"
31 |
32 | #. module: account_invoice_line_number
33 | #: model_terms:ir.ui.view,arch_db:account_invoice_line_number.invoice_form
34 | msgid "nbr"
35 | msgstr "num"
36 |
--------------------------------------------------------------------------------
/account_invoice_line_number/i18n/ru.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_line_number
4 | #
5 | # Translators:
6 | # Irina Fedulova , 2020
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 13.0\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2021-01-07 17:47+0000\n"
13 | "PO-Revision-Date: 2020-03-11 19:37+0000\n"
14 | "Last-Translator: Irina Fedulova , 2020\n"
15 | "Language-Team: Russian (https://www.transifex.com/adhoc/teams/46451/ru/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: ru\n"
20 | "Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n"
21 |
22 | #. module: account_invoice_line_number
23 | #: model:ir.model,name:account_invoice_line_number.model_account_move_line
24 | msgid "Journal Item"
25 | msgstr ""
26 |
27 | #. module: account_invoice_line_number
28 | #: model:ir.model.fields,field_description:account_invoice_line_number.field_account_move_line__number
29 | msgid "Line Nº"
30 | msgstr ""
31 |
32 | #. module: account_invoice_line_number
33 | #: model_terms:ir.ui.view,arch_db:account_invoice_line_number.invoice_form
34 | msgid "nbr"
35 | msgstr "nbr"
36 |
--------------------------------------------------------------------------------
/account_invoice_line_number/models/__init__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from . import account_move_line
6 | from . import account_move
7 |
--------------------------------------------------------------------------------
/account_invoice_line_number/models/account_move.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from odoo import fields, models
6 |
7 |
8 | class AccountMove(models.Model):
9 | _inherit = "account.move"
10 |
11 | number_lines = fields.Char(compute="_compute_number_lines")
12 |
13 | def _compute_number_lines(self):
14 | self.number_lines = False
15 | if self and not isinstance(self[0].id, int):
16 | return
17 | for move in self:
18 | number_line_map = {}
19 | for number, line in enumerate(move.invoice_line_ids.sorted("sequence"), 1):
20 | number_line_map.update({line.id: number})
21 |
22 | move.number_lines = number_line_map
23 |
--------------------------------------------------------------------------------
/account_invoice_line_number/models/account_move_line.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from odoo import fields, models
6 |
7 |
8 | class AccountMoveLine(models.Model):
9 | _inherit = "account.move.line"
10 |
11 | number = fields.Integer(string="Line Nº", compute="_compute_number")
12 |
13 | def _compute_number(self):
14 | """No es lo mas elegante pero funciona. Algunos comentarios:
15 | * para evitar computos de mas no dejamos el depends y no se computa con los onchange
16 | * para hacer eso nos fijamos si lo que viene en self son new ids o enteros.
17 | * asignamos self.number porque si no da error, aparentemente por algo del mapped y el order.order_line.number
18 | """
19 | self.number = False
20 | if self and not isinstance(self[0].id, int):
21 | return
22 | # TODO buscar alternativa al eval() ya que puede traer errores de seguridad
23 | mapping = eval(self[0].move_id.number_lines) # pylint: disable=W0123
24 | for line in self:
25 | line.number = mapping.get(line.id)
26 |
--------------------------------------------------------------------------------
/account_invoice_line_number/views/account_move_view.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | account.invoice.form
5 | account.move
6 |
7 |
8 |
9 |
10 |
11 |
14 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/account_invoice_partial/README.rst:
--------------------------------------------------------------------------------
1 | .. |company| replace:: ADHOC SA
2 |
3 | .. |company_logo| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-logo.png
4 | :alt: ADHOC SA
5 | :target: https://www.adhoc.com.ar
6 |
7 | .. |icon| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-icon.png
8 |
9 | .. image:: https://img.shields.io/badge/license-AGPL--3-blue.png
10 | :target: https://www.gnu.org/licenses/agpl
11 | :alt: License: AGPL-3
12 |
13 | =======================
14 | Account Invoice Partial
15 | =======================
16 |
17 | Module that adds a button on the Customer Invoice,
18 | which allows you to select a percentage to be invoiced,
19 | the decimal precision and the rounding method.
20 |
21 |
22 | Installation
23 | ============
24 |
25 | To install this module, you need to:
26 |
27 | #. Just install this module.
28 |
29 |
30 | Configuration
31 | =============
32 |
33 | To configure this module, you need to:
34 |
35 | #. No configuration nedeed.
36 |
37 |
38 | Usage
39 | =====
40 |
41 | To use this module, you need to:
42 |
43 | #. Go to Customer Invoice and use the button "Invoice Percentage"
44 |
45 | .. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
46 | :alt: Try me on Runbot
47 | :target: http://runbot.adhoc.com.ar/
48 |
49 | Bug Tracker
50 | ===========
51 |
52 | Bugs are tracked on `GitHub Issues
53 | `_. In case of trouble, please
54 | check there if your issue has already been reported. If you spotted it first,
55 | help us smashing it by providing a detailed and welcomed feedback.
56 |
57 | Credits
58 | =======
59 |
60 | Images
61 | ------
62 |
63 | * |company| |icon|
64 |
65 | Contributors
66 | ------------
67 |
68 | Maintainer
69 | ----------
70 |
71 | |company_logo|
72 |
73 | This module is maintained by the |company|.
74 |
75 | To contribute to this module, please visit https://www.adhoc.com.ar.
76 |
--------------------------------------------------------------------------------
/account_invoice_partial/__init__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from . import wizards
6 |
--------------------------------------------------------------------------------
/account_invoice_partial/__manifest__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | #
3 | # Copyright (C) 2015 ADHOC SA (http://www.adhoc.com.ar)
4 | # All Rights Reserved.
5 | #
6 | # This program is free software: you can redistribute it and/or modify
7 | # it under the terms of the GNU Affero General Public License as
8 | # published by the Free Software Foundation, either version 3 of the
9 | # License, or (at your option) any later version.
10 | #
11 | # This program is distributed in the hope that it will be useful,
12 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | # GNU Affero General Public License for more details.
15 | #
16 | # You should have received a copy of the GNU Affero General Public License
17 | # along with this program. If not, see .
18 | #
19 | ##############################################################################
20 | {
21 | "name": "Account Invoice Partial",
22 | "version": "18.0.1.0.0",
23 | "category": "Accounting",
24 | "sequence": 14,
25 | "summary": "",
26 | "author": "ADHOC SA",
27 | "website": "www.adhoc.com.ar",
28 | "license": "AGPL-3",
29 | "images": [],
30 | "depends": [
31 | "account",
32 | ],
33 | "data": [
34 | "wizards/account_invoice_partial_wizard_views.xml",
35 | "views/account_move_views.xml",
36 | "security/ir.model.access.csv",
37 | ],
38 | "demo": [],
39 | "installable": True,
40 | "auto_install": False,
41 | "application": False,
42 | }
43 |
--------------------------------------------------------------------------------
/account_invoice_partial/i18n/de.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_partial
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2019
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 12.0\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2019-11-22 15:14+0000\n"
13 | "PO-Revision-Date: 2019-09-19 15:21+0000\n"
14 | "Last-Translator: Juan José Scarafía , 2019\n"
15 | "Language-Team: German (https://www.transifex.com/adhoc/teams/46451/de/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: de\n"
20 | "Plural-Forms: nplurals=2; plural=(n != 1);\n"
21 |
22 | #. module: account_invoice_partial
23 | #: model:ir.model,name:account_invoice_partial.model_account_invoice_partial_wizard
24 | msgid "Account Invoice Partial Wizard"
25 | msgstr ""
26 |
27 | #. module: account_invoice_partial
28 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
29 | msgid "Confirm"
30 | msgstr ""
31 |
32 | #. module: account_invoice_partial
33 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__create_uid
34 | msgid "Created by"
35 | msgstr "Angelegt durch"
36 |
37 | #. module: account_invoice_partial
38 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__create_date
39 | msgid "Created on"
40 | msgstr "Angelegt am"
41 |
42 | #. module: account_invoice_partial
43 | #: selection:account.invoice.partial.wizard,rounding_method:0
44 | msgid "DOWN"
45 | msgstr ""
46 |
47 | #. module: account_invoice_partial
48 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__display_name
49 | msgid "Display Name"
50 | msgstr "Anzeigebezeichnung"
51 |
52 | #. module: account_invoice_partial
53 | #: selection:account.invoice.partial.wizard,rounding_method:0
54 | msgid "HALF-UP"
55 | msgstr ""
56 |
57 | #. module: account_invoice_partial
58 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__id
59 | msgid "ID"
60 | msgstr "ID"
61 |
62 | #. module: account_invoice_partial
63 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__invoice_id
64 | msgid "Invoice"
65 | msgstr "Rechnung"
66 |
67 | #. module: account_invoice_partial
68 | #: model:ir.actions.act_window,name:account_invoice_partial.action_account_invoice_partial_wizard_form
69 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
70 | msgid "Invoice Partial"
71 | msgstr ""
72 |
73 | #. module: account_invoice_partial
74 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.invoice_form
75 | msgid "Invoice Percentage"
76 | msgstr ""
77 |
78 | #. module: account_invoice_partial
79 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard____last_update
80 | msgid "Last Modified on"
81 | msgstr "Zuletzt verändert am"
82 |
83 | #. module: account_invoice_partial
84 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__write_uid
85 | msgid "Last Updated by"
86 | msgstr "Zuletzt aktualisiert durch"
87 |
88 | #. module: account_invoice_partial
89 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__write_date
90 | msgid "Last Updated on"
91 | msgstr "Zuletzt aktualisiert am"
92 |
93 | #. module: account_invoice_partial
94 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__percentage_to_invoice
95 | msgid "Percentage To Invoice"
96 | msgstr ""
97 |
98 | #. module: account_invoice_partial
99 | #: model:ir.model.fields,help:account_invoice_partial.field_account_invoice_partial_wizard__rounding
100 | msgid "Represent the non-zero value smallest coinage (for example, 0.05)."
101 | msgstr ""
102 |
103 | #. module: account_invoice_partial
104 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__rounding_method
105 | msgid "Rounding Method"
106 | msgstr ""
107 |
108 | #. module: account_invoice_partial
109 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__rounding
110 | msgid "Rounding Precision"
111 | msgstr ""
112 |
113 | #. module: account_invoice_partial
114 | #: model:ir.model.fields,help:account_invoice_partial.field_account_invoice_partial_wizard__rounding_method
115 | msgid "The tie-breaking rule used for float rounding operations"
116 | msgstr ""
117 |
118 | #. module: account_invoice_partial
119 | #: selection:account.invoice.partial.wizard,rounding_method:0
120 | msgid "UP"
121 | msgstr ""
122 |
123 | #. module: account_invoice_partial
124 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
125 | msgid "_Cancel"
126 | msgstr ""
127 |
128 | #. module: account_invoice_partial
129 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
130 | msgid "or"
131 | msgstr ""
132 |
--------------------------------------------------------------------------------
/account_invoice_partial/i18n/es.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_partial
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2024
7 | # Rocio Vega, 2025
8 | #
9 | msgid ""
10 | msgstr ""
11 | "Project-Id-Version: Odoo Server 18.0+e\n"
12 | "Report-Msgid-Bugs-To: \n"
13 | "POT-Creation-Date: 2025-02-12 00:31+0000\n"
14 | "PO-Revision-Date: 2024-11-14 20:11+0000\n"
15 | "Last-Translator: Rocio Vega, 2025\n"
16 | "Language-Team: Spanish (https://app.transifex.com/adhoc/teams/46451/es/)\n"
17 | "MIME-Version: 1.0\n"
18 | "Content-Type: text/plain; charset=UTF-8\n"
19 | "Content-Transfer-Encoding: \n"
20 | "Language: es\n"
21 | "Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n"
22 |
23 | #. module: account_invoice_partial
24 | #: model:ir.model,name:account_invoice_partial.model_account_invoice_partial_wizard
25 | msgid "Account Invoice Partial Wizard"
26 | msgstr "Asistente de Facturación Parcial"
27 |
28 | #. module: account_invoice_partial
29 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
30 | msgid "Confirm"
31 | msgstr "Confirmar"
32 |
33 | #. module: account_invoice_partial
34 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__create_uid
35 | msgid "Created by"
36 | msgstr "Creado por"
37 |
38 | #. module: account_invoice_partial
39 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__create_date
40 | msgid "Created on"
41 | msgstr "Creado en"
42 |
43 | #. module: account_invoice_partial
44 | #: model:ir.model.fields.selection,name:account_invoice_partial.selection__account_invoice_partial_wizard__rounding_method__down
45 | msgid "DOWN"
46 | msgstr "ABAJO"
47 |
48 | #. module: account_invoice_partial
49 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__display_name
50 | msgid "Display Name"
51 | msgstr "Nombre a Mostrar"
52 |
53 | #. module: account_invoice_partial
54 | #: model:ir.model.fields.selection,name:account_invoice_partial.selection__account_invoice_partial_wizard__rounding_method__half-up
55 | msgid "HALF-UP"
56 | msgstr "MITAD ARRIBA"
57 |
58 | #. module: account_invoice_partial
59 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__id
60 | msgid "ID"
61 | msgstr "ID (identificación)"
62 |
63 | #. module: account_invoice_partial
64 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__invoice_id
65 | msgid "Invoice"
66 | msgstr "Factura"
67 |
68 | #. module: account_invoice_partial
69 | #: model:ir.actions.act_window,name:account_invoice_partial.action_account_invoice_partial_wizard_form
70 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
71 | msgid "Invoice Partial"
72 | msgstr "Factura Parcial"
73 |
74 | #. module: account_invoice_partial
75 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_move_form
76 | msgid "Invoice Percentage"
77 | msgstr "Facturar porcentaje"
78 |
79 | #. module: account_invoice_partial
80 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__write_uid
81 | msgid "Last Updated by"
82 | msgstr "Última actualización por"
83 |
84 | #. module: account_invoice_partial
85 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__write_date
86 | msgid "Last Updated on"
87 | msgstr "Última actualización el"
88 |
89 | #. module: account_invoice_partial
90 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__percentage_to_invoice
91 | msgid "Percentage To Invoice"
92 | msgstr "Porcentaje a facturar"
93 |
94 | #. module: account_invoice_partial
95 | #: model:ir.model.fields,help:account_invoice_partial.field_account_invoice_partial_wizard__rounding
96 | msgid "Represent the non-zero value smallest coinage (for example, 0.05)."
97 | msgstr ""
98 | "Representa la moneda más pequeña con valor distinto de cero (por ejemplo, "
99 | "0.05)."
100 |
101 | #. module: account_invoice_partial
102 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__rounding_method
103 | msgid "Rounding Method"
104 | msgstr "Método de redondeo"
105 |
106 | #. module: account_invoice_partial
107 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__rounding
108 | msgid "Rounding Precision"
109 | msgstr "Precisión de redondeo"
110 |
111 | #. module: account_invoice_partial
112 | #: model:ir.model.fields,help:account_invoice_partial.field_account_invoice_partial_wizard__rounding_method
113 | msgid "The tie-breaking rule used for float rounding operations"
114 | msgstr ""
115 | "La regla de desempate utilizada para las operaciones de redondeo de "
116 | "decimales"
117 |
118 | #. module: account_invoice_partial
119 | #: model:ir.model.fields.selection,name:account_invoice_partial.selection__account_invoice_partial_wizard__rounding_method__up
120 | msgid "UP"
121 | msgstr "ARRIBA"
122 |
123 | #. module: account_invoice_partial
124 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
125 | msgid "_Cancel"
126 | msgstr "_Cancelar"
127 |
128 | #. module: account_invoice_partial
129 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
130 | msgid "or"
131 | msgstr "o"
132 |
--------------------------------------------------------------------------------
/account_invoice_partial/i18n/pt_BR.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_partial
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2019
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 12.0\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2019-11-22 15:14+0000\n"
13 | "PO-Revision-Date: 2019-09-19 15:21+0000\n"
14 | "Last-Translator: Juan José Scarafía , 2019\n"
15 | "Language-Team: Portuguese (Brazil) (https://www.transifex.com/adhoc/teams/46451/pt_BR/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: pt_BR\n"
20 | "Plural-Forms: nplurals=2; plural=(n > 1);\n"
21 |
22 | #. module: account_invoice_partial
23 | #: model:ir.model,name:account_invoice_partial.model_account_invoice_partial_wizard
24 | msgid "Account Invoice Partial Wizard"
25 | msgstr ""
26 |
27 | #. module: account_invoice_partial
28 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
29 | msgid "Confirm"
30 | msgstr ""
31 |
32 | #. module: account_invoice_partial
33 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__create_uid
34 | msgid "Created by"
35 | msgstr ""
36 |
37 | #. module: account_invoice_partial
38 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__create_date
39 | msgid "Created on"
40 | msgstr ""
41 |
42 | #. module: account_invoice_partial
43 | #: selection:account.invoice.partial.wizard,rounding_method:0
44 | msgid "DOWN"
45 | msgstr ""
46 |
47 | #. module: account_invoice_partial
48 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__display_name
49 | msgid "Display Name"
50 | msgstr ""
51 |
52 | #. module: account_invoice_partial
53 | #: selection:account.invoice.partial.wizard,rounding_method:0
54 | msgid "HALF-UP"
55 | msgstr ""
56 |
57 | #. module: account_invoice_partial
58 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__id
59 | msgid "ID"
60 | msgstr ""
61 |
62 | #. module: account_invoice_partial
63 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__invoice_id
64 | msgid "Invoice"
65 | msgstr "Fatura"
66 |
67 | #. module: account_invoice_partial
68 | #: model:ir.actions.act_window,name:account_invoice_partial.action_account_invoice_partial_wizard_form
69 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
70 | msgid "Invoice Partial"
71 | msgstr ""
72 |
73 | #. module: account_invoice_partial
74 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.invoice_form
75 | msgid "Invoice Percentage"
76 | msgstr ""
77 |
78 | #. module: account_invoice_partial
79 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard____last_update
80 | msgid "Last Modified on"
81 | msgstr ""
82 |
83 | #. module: account_invoice_partial
84 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__write_uid
85 | msgid "Last Updated by"
86 | msgstr ""
87 |
88 | #. module: account_invoice_partial
89 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__write_date
90 | msgid "Last Updated on"
91 | msgstr ""
92 |
93 | #. module: account_invoice_partial
94 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__percentage_to_invoice
95 | msgid "Percentage To Invoice"
96 | msgstr ""
97 |
98 | #. module: account_invoice_partial
99 | #: model:ir.model.fields,help:account_invoice_partial.field_account_invoice_partial_wizard__rounding
100 | msgid "Represent the non-zero value smallest coinage (for example, 0.05)."
101 | msgstr ""
102 |
103 | #. module: account_invoice_partial
104 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__rounding_method
105 | msgid "Rounding Method"
106 | msgstr ""
107 |
108 | #. module: account_invoice_partial
109 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__rounding
110 | msgid "Rounding Precision"
111 | msgstr ""
112 |
113 | #. module: account_invoice_partial
114 | #: model:ir.model.fields,help:account_invoice_partial.field_account_invoice_partial_wizard__rounding_method
115 | msgid "The tie-breaking rule used for float rounding operations"
116 | msgstr ""
117 |
118 | #. module: account_invoice_partial
119 | #: selection:account.invoice.partial.wizard,rounding_method:0
120 | msgid "UP"
121 | msgstr ""
122 |
123 | #. module: account_invoice_partial
124 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
125 | msgid "_Cancel"
126 | msgstr ""
127 |
128 | #. module: account_invoice_partial
129 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
130 | msgid "or"
131 | msgstr ""
132 |
--------------------------------------------------------------------------------
/account_invoice_partial/i18n/ru.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_partial
4 | #
5 | # Translators:
6 | # Irina Fedulova , 2020
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 13.0\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2021-01-07 17:47+0000\n"
13 | "PO-Revision-Date: 2020-07-22 15:13+0000\n"
14 | "Last-Translator: Irina Fedulova , 2020\n"
15 | "Language-Team: Russian (https://www.transifex.com/adhoc/teams/46451/ru/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: ru\n"
20 | "Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n"
21 |
22 | #. module: account_invoice_partial
23 | #: model:ir.model,name:account_invoice_partial.model_account_invoice_partial_wizard
24 | msgid "Account Invoice Partial Wizard"
25 | msgstr ""
26 |
27 | #. module: account_invoice_partial
28 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
29 | msgid "Confirm"
30 | msgstr "Подтвердить"
31 |
32 | #. module: account_invoice_partial
33 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__create_uid
34 | msgid "Created by"
35 | msgstr "Создано"
36 |
37 | #. module: account_invoice_partial
38 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__create_date
39 | msgid "Created on"
40 | msgstr "Создано"
41 |
42 | #. module: account_invoice_partial
43 | #: model:ir.model.fields.selection,name:account_invoice_partial.selection__account_invoice_partial_wizard__rounding_method__down
44 | msgid "DOWN"
45 | msgstr ""
46 |
47 | #. module: account_invoice_partial
48 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__display_name
49 | msgid "Display Name"
50 | msgstr ""
51 |
52 | #. module: account_invoice_partial
53 | #: model:ir.model.fields.selection,name:account_invoice_partial.selection__account_invoice_partial_wizard__rounding_method__half-up
54 | msgid "HALF-UP"
55 | msgstr ""
56 |
57 | #. module: account_invoice_partial
58 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__id
59 | msgid "ID"
60 | msgstr "ID"
61 |
62 | #. module: account_invoice_partial
63 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__invoice_id
64 | msgid "Invoice"
65 | msgstr "Инвойс"
66 |
67 | #. module: account_invoice_partial
68 | #: model:ir.actions.act_window,name:account_invoice_partial.action_account_invoice_partial_wizard_form
69 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
70 | msgid "Invoice Partial"
71 | msgstr ""
72 |
73 | #. module: account_invoice_partial
74 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_move_form
75 | msgid "Invoice Percentage"
76 | msgstr ""
77 |
78 | #. module: account_invoice_partial
79 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard____last_update
80 | msgid "Last Modified on"
81 | msgstr "Изменено"
82 |
83 | #. module: account_invoice_partial
84 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__write_uid
85 | msgid "Last Updated by"
86 | msgstr "Обновлено"
87 |
88 | #. module: account_invoice_partial
89 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__write_date
90 | msgid "Last Updated on"
91 | msgstr "Обновлено"
92 |
93 | #. module: account_invoice_partial
94 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__percentage_to_invoice
95 | msgid "Percentage To Invoice"
96 | msgstr ""
97 |
98 | #. module: account_invoice_partial
99 | #: model:ir.model.fields,help:account_invoice_partial.field_account_invoice_partial_wizard__rounding
100 | msgid "Represent the non-zero value smallest coinage (for example, 0.05)."
101 | msgstr ""
102 |
103 | #. module: account_invoice_partial
104 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__rounding_method
105 | msgid "Rounding Method"
106 | msgstr ""
107 |
108 | #. module: account_invoice_partial
109 | #: model:ir.model.fields,field_description:account_invoice_partial.field_account_invoice_partial_wizard__rounding
110 | msgid "Rounding Precision"
111 | msgstr ""
112 |
113 | #. module: account_invoice_partial
114 | #: model:ir.model.fields,help:account_invoice_partial.field_account_invoice_partial_wizard__rounding_method
115 | msgid "The tie-breaking rule used for float rounding operations"
116 | msgstr ""
117 |
118 | #. module: account_invoice_partial
119 | #: model:ir.model.fields.selection,name:account_invoice_partial.selection__account_invoice_partial_wizard__rounding_method__up
120 | msgid "UP"
121 | msgstr ""
122 |
123 | #. module: account_invoice_partial
124 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
125 | msgid "_Cancel"
126 | msgstr ""
127 |
128 | #. module: account_invoice_partial
129 | #: model_terms:ir.ui.view,arch_db:account_invoice_partial.view_account_invoice_partial_wizard_form
130 | msgid "or"
131 | msgstr "или"
132 |
--------------------------------------------------------------------------------
/account_invoice_partial/security/ir.model.access.csv:
--------------------------------------------------------------------------------
1 | id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
2 | access_account_invoice_partial_wizard,access_account_invoice_partial_wizard,model_account_invoice_partial_wizard,account.group_account_invoice,1,1,1,0
3 |
--------------------------------------------------------------------------------
/account_invoice_partial/views/account_move_views.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | account.move.form
6 | account.move
7 |
8 |
9 |
10 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/account_invoice_partial/wizards/__init__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from . import account_invoice_partial_wizard
6 |
--------------------------------------------------------------------------------
/account_invoice_partial/wizards/account_invoice_partial_wizard.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from odoo import fields, models
6 | from odoo.tools import float_round
7 |
8 |
9 | class AccountInvoicePartialWizard(models.TransientModel):
10 | _name = "account.invoice.partial.wizard"
11 | _description = "Account Invoice Partial Wizard"
12 |
13 | invoice_id = fields.Many2one(
14 | "account.move",
15 | default=lambda x: x._context.get("active_id", False),
16 | )
17 | percentage_to_invoice = fields.Float(
18 | required=True,
19 | )
20 | rounding = fields.Float(
21 | string="Rounding Precision",
22 | required=True,
23 | help="Represent the non-zero value smallest coinage" " (for example, 0.05).",
24 | default=0.01,
25 | )
26 | rounding_method = fields.Selection(
27 | required=True,
28 | selection=[("UP", "UP"), ("DOWN", "DOWN"), ("HALF-UP", "HALF-UP")],
29 | default="HALF-UP",
30 | help="The tie-breaking rule used for float rounding operations",
31 | )
32 |
33 | def compute_new_quantity(self):
34 | self.ensure_one()
35 | for line in self.invoice_id.invoice_line_ids.with_context(check_move_validity=False):
36 | quantity = line.quantity * (self.percentage_to_invoice / 100)
37 | line.quantity = float_round(
38 | quantity, precision_rounding=self.rounding, rounding_method=self.rounding_method
39 | )
40 |
--------------------------------------------------------------------------------
/account_invoice_partial/wizards/account_invoice_partial_wizard_views.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Account Invoice Partial Wizard
5 | account.invoice.partial.wizard
6 |
7 |
20 |
21 |
22 |
23 |
24 | Invoice Partial
25 | account.invoice.partial.wizard
26 | form
27 | new
28 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/account_invoice_prices_update/README.rst:
--------------------------------------------------------------------------------
1 | .. |company| replace:: ADHOC SA
2 |
3 | .. |company_logo| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-logo.png
4 | :alt: ADHOC SA
5 | :target: https://www.adhoc.com.ar
6 |
7 | .. |icon| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-icon.png
8 |
9 | .. image:: https://img.shields.io/badge/license-AGPL--3-blue.png
10 | :target: https://www.gnu.org/licenses/agpl
11 | :alt: License: AGPL-3
12 |
13 | =============================
14 | Account Invoice Prices Update
15 | =============================
16 |
17 | This module adds a wizard to update prices of the products of an invoice according to the price list is chosen in the wizard.
18 |
19 |
20 | Installation
21 | ============
22 |
23 | To install this module, you need to:
24 |
25 | #. Only need to install the module
26 |
27 | Configuration
28 | =============
29 |
30 | To configure this module, you need to:
31 |
32 | #. Nothing to configure
33 |
34 | Usage
35 | =====
36 |
37 | To use this module, you need to:
38 |
39 | #. Go to an "draft" invoice and click the button "Update Pricelist and Prices", then a popup it's open, select the pricelist to update the price in the lines using this listprice.
40 |
41 | .. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
42 | :alt: Try me on Runbot
43 | :target: http://runbot.adhoc.com.ar/
44 |
45 | Bug Tracker
46 | ===========
47 |
48 | Bugs are tracked on `GitHub Issues
49 | `_. In case of trouble, please
50 | check there if your issue has already been reported. If you spotted it first,
51 | help us smashing it by providing a detailed and welcomed feedback.
52 |
53 | Credits
54 | =======
55 |
56 | Images
57 | ------
58 |
59 | * |company| |icon|
60 |
61 | Contributors
62 | ------------
63 |
64 | Maintainer
65 | ----------
66 |
67 | |company_logo|
68 |
69 | This module is maintained by the |company|.
70 |
71 | To contribute to this module, please visit https://www.adhoc.com.ar.
72 |
--------------------------------------------------------------------------------
/account_invoice_prices_update/__init__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from . import wizards
6 |
--------------------------------------------------------------------------------
/account_invoice_prices_update/__manifest__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | #
3 | # Copyright (C) 2015 ADHOC SA (http://www.adhoc.com.ar)
4 | # All Rights Reserved.
5 | #
6 | # This program is free software: you can redistribute it and/or modify
7 | # it under the terms of the GNU Affero General Public License as
8 | # published by the Free Software Foundation, either version 3 of the
9 | # License, or (at your option) any later version.
10 | #
11 | # This program is distributed in the hope that it will be useful,
12 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | # GNU Affero General Public License for more details.
15 | #
16 | # You should have received a copy of the GNU Affero General Public License
17 | # along with this program. If not, see .
18 | #
19 | ##############################################################################
20 | {
21 | "name": "Account Invoice Prices Update",
22 | "version": "18.0.1.0.0",
23 | "author": "ADHOC SA",
24 | "license": "AGPL-3",
25 | "category": "Accounting & Finance",
26 | "website": "www.adhoc.com.ar",
27 | "depends": ["account"],
28 | "data": [
29 | "wizards/update_prices_wizard_views.xml",
30 | "views/account_move_views.xml",
31 | "security/ir.model.access.csv",
32 | ],
33 | "installable": True,
34 | }
35 |
--------------------------------------------------------------------------------
/account_invoice_prices_update/i18n/es.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_prices_update
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2024
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 18.0+e\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2024-11-14 20:13+0000\n"
13 | "PO-Revision-Date: 2024-11-14 20:13+0000\n"
14 | "Last-Translator: Juan José Scarafía , 2024\n"
15 | "Language-Team: Spanish (https://app.transifex.com/adhoc/teams/46451/es/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: es\n"
20 | "Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n"
21 |
22 | #. module: account_invoice_prices_update
23 | #: model:ir.model.fields,field_description:account_invoice_prices_update.field_account_invoice_prices_update_wizard__algolia_search
24 | msgid "Algolia Search"
25 | msgstr ""
26 |
27 | #. module: account_invoice_prices_update
28 | #: model_terms:ir.ui.view,arch_db:account_invoice_prices_update.view_account_invoice_form
29 | msgid "Cancel"
30 | msgstr "Cancelar"
31 |
32 | #. module: account_invoice_prices_update
33 | #: model:ir.model.fields,field_description:account_invoice_prices_update.field_account_invoice_prices_update_wizard__create_uid
34 | msgid "Created by"
35 | msgstr "Creado por"
36 |
37 | #. module: account_invoice_prices_update
38 | #: model:ir.model.fields,field_description:account_invoice_prices_update.field_account_invoice_prices_update_wizard__create_date
39 | msgid "Created on"
40 | msgstr "Creado en"
41 |
42 | #. module: account_invoice_prices_update
43 | #: model:ir.model.fields,field_description:account_invoice_prices_update.field_account_invoice_prices_update_wizard__display_name
44 | msgid "Display Name"
45 | msgstr "Nombre a Mostrar"
46 |
47 | #. module: account_invoice_prices_update
48 | #: model:ir.model.fields,field_description:account_invoice_prices_update.field_account_invoice_prices_update_wizard__id
49 | msgid "ID"
50 | msgstr ""
51 |
52 | #. module: account_invoice_prices_update
53 | #: model:ir.model.fields,field_description:account_invoice_prices_update.field_account_invoice_prices_update_wizard__write_uid
54 | msgid "Last Updated by"
55 | msgstr "Última actualización por"
56 |
57 | #. module: account_invoice_prices_update
58 | #: model:ir.model.fields,field_description:account_invoice_prices_update.field_account_invoice_prices_update_wizard__write_date
59 | msgid "Last Updated on"
60 | msgstr "Última actualización en"
61 |
62 | #. module: account_invoice_prices_update
63 | #: model:ir.model.fields,field_description:account_invoice_prices_update.field_account_invoice_prices_update_wizard__pricelist_id
64 | msgid "Pricelist"
65 | msgstr "Tarifa"
66 |
67 | #. module: account_invoice_prices_update
68 | #: model_terms:ir.ui.view,arch_db:account_invoice_prices_update.view_move_form
69 | msgid "Update Pricelist and Prices"
70 | msgstr "Actualizar Precios de Productos"
71 |
72 | #. module: account_invoice_prices_update
73 | #: model:ir.actions.act_window,name:account_invoice_prices_update.action_update_prices_list
74 | #: model_terms:ir.ui.view,arch_db:account_invoice_prices_update.view_account_invoice_form
75 | msgid "Update Prices"
76 | msgstr "Actualizar Precios"
77 |
78 | #. module: account_invoice_prices_update
79 | #: model_terms:ir.ui.view,arch_db:account_invoice_prices_update.view_account_invoice_form
80 | msgid "Update Prices Wizard"
81 | msgstr "Asistente de Actualización de Precios"
82 |
83 | #. module: account_invoice_prices_update
84 | #: model:ir.model,name:account_invoice_prices_update.model_account_invoice_prices_update_wizard
85 | msgid "account.invoice.prices_update.wizard"
86 | msgstr ""
87 |
88 | #. module: account_invoice_prices_update
89 | #: model_terms:ir.ui.view,arch_db:account_invoice_prices_update.view_account_invoice_form
90 | msgid "or"
91 | msgstr "o"
92 |
--------------------------------------------------------------------------------
/account_invoice_prices_update/security/ir.model.access.csv:
--------------------------------------------------------------------------------
1 | id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
2 | access_account_invoice_prices_update_wizard,access.account.invoice.prices_update,model_account_invoice_prices_update_wizard,account.group_account_invoice,1,1,1,0
3 |
--------------------------------------------------------------------------------
/account_invoice_prices_update/views/account_move_views.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | account.move.view
5 | account.move
6 |
7 |
8 |
9 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/account_invoice_prices_update/wizards/__init__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from . import account_invoice_prices_update_wizard
6 |
--------------------------------------------------------------------------------
/account_invoice_prices_update/wizards/account_invoice_prices_update_wizard.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from odoo import api, fields, models
6 |
7 |
8 | class AccountInvoicePricesUpdateWizard(models.TransientModel):
9 | _name = "account.invoice.prices_update.wizard"
10 | _description = "account.invoice.prices_update.wizard"
11 |
12 | pricelist_id = fields.Many2one(
13 | "product.pricelist",
14 | required=True,
15 | default=lambda self: self._get_pricelist(),
16 | )
17 |
18 | @api.model
19 | def _get_pricelist(self):
20 | invoice_id = self._context.get("active_id", False)
21 | if invoice_id:
22 | invoice = self.env["account.move"].browse(invoice_id)
23 | return invoice.partner_id.property_product_pricelist
24 |
25 | def update_prices(self):
26 | self.ensure_one()
27 | active_id = self._context.get("active_id", False)
28 | invoice = self.env["account.move"].browse(active_id)
29 | invoice.write({"currency_id": self.pricelist_id.currency_id.id})
30 | for line in invoice.invoice_line_ids.filtered("product_id").with_context(check_move_validity=False):
31 | price, discount = self._get_price_discount(self.pricelist_id, line)
32 | line.write(
33 | {
34 | "price_unit": price,
35 | "discount": discount,
36 | }
37 | )
38 | invoice.message_post(body="The pricelist is now: %s" % self.pricelist_id.display_name)
39 | return True
40 |
41 | def _calculate_discount(self, base_price, final_price):
42 | discount = (base_price - final_price) / base_price * 100
43 | if (discount < 0 and base_price > 0) or (discount > 0 and base_price < 0):
44 | discount = 0.0
45 | return discount
46 |
47 | def _get_price_discount(self, pricelist, invoice_line):
48 | price_unit = 0.0
49 | move = invoice_line.move_id
50 | product = invoice_line.product_id
51 | uom = invoice_line.product_uom_id
52 | qty = invoice_line.quantity or 1.0
53 | date = move.invoice_date or fields.Date.today()
54 | (
55 | final_price,
56 | rule_id,
57 | ) = pricelist._get_product_price_rule(
58 | product,
59 | qty,
60 | uom=uom,
61 | date=date,
62 | )
63 | rule_id = self.env["product.pricelist.item"].browse(rule_id)
64 | if rule_id.compute_price != "percentage":
65 | price_unit = self.env["account.tax"]._fix_tax_included_price_company(
66 | final_price,
67 | product.taxes_id,
68 | invoice_line.tax_ids,
69 | invoice_line.company_id,
70 | )
71 | return price_unit, 0.0
72 | else:
73 | base_price = rule_id._compute_base_price(
74 | product,
75 | qty,
76 | uom,
77 | date,
78 | currency=invoice_line.currency_id,
79 | )
80 | price_unit = max(base_price, final_price)
81 | return price_unit, self._calculate_discount(base_price, final_price)
82 |
--------------------------------------------------------------------------------
/account_invoice_prices_update/wizards/update_prices_wizard_views.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | account_update_prices.wizard
6 | account.invoice.prices_update.wizard
7 |
8 |
18 |
19 |
20 |
21 |
22 | Update Prices
23 | ir.actions.act_window
24 | account.invoice.prices_update.wizard
25 | form
26 | new
27 |
28 |
29 |
30 |
--------------------------------------------------------------------------------
/account_invoice_tax/README.rst:
--------------------------------------------------------------------------------
1 | .. |company| replace:: ADHOC SA
2 |
3 | .. |company_logo| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-logo.png
4 | :alt: ADHOC SA
5 | :target: https://www.adhoc.com.ar
6 |
7 | .. |icon| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-icon.png
8 |
9 | .. image:: https://img.shields.io/badge/license-AGPL--3-blue.png
10 | :target: https://www.gnu.org/licenses/agpl
11 | :alt: License: AGPL-3
12 |
13 | ===================
14 | Account Invoice Tax
15 | ===================
16 |
17 | Add new buttons in the Vendor Bills that let us to add/remove taxes to all the lines of a vendor bill.
18 |
19 |
20 | Installation
21 | ============
22 |
23 | To install this module, you need to:
24 |
25 | #. Only need to install the module
26 |
27 | Configuration
28 | =============
29 |
30 | To configure this module, you need to:
31 |
32 | #. Nothing to configure
33 |
34 | Usage
35 | =====
36 |
37 | To use this module, you need to:
38 |
39 | #. Go to an "draft" invoice and click the button "Update Pricelist and Prices", then a popup it's open, select the pricelist to update the price in the lines using this listprice.
40 |
41 | .. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
42 | :alt: Try me on Runbot
43 | :target: http://runbot.adhoc.com.ar/
44 |
45 | Bug Tracker
46 | ===========
47 |
48 | Bugs are tracked on `GitHub Issues
49 | `_. In case of trouble, please
50 | check there if your issue has already been reported. If you spotted it first,
51 | help us smashing it by providing a detailed and welcomed feedback.
52 |
53 | Credits
54 | =======
55 |
56 | Images
57 | ------
58 |
59 | * |company| |icon|
60 |
61 | Contributors
62 | ------------
63 |
64 | Maintainer
65 | ----------
66 |
67 | |company_logo|
68 |
69 | This module is maintained by the |company|.
70 |
71 | To contribute to this module, please visit https://www.adhoc.com.ar.
72 |
--------------------------------------------------------------------------------
/account_invoice_tax/__init__.py:
--------------------------------------------------------------------------------
1 | # Part of Odoo. See LICENSE file for full copyright and licensing details.
2 | from . import wizards
3 |
--------------------------------------------------------------------------------
/account_invoice_tax/__manifest__.py:
--------------------------------------------------------------------------------
1 | {
2 | "name": "Account Invoice Tax",
3 | "version": "18.0.1.1.0",
4 | "author": "ADHOC SA",
5 | "category": "Localization",
6 | "depends": [
7 | "account",
8 | ],
9 | "data": [
10 | "wizards/account_invoice_tax_view.xml",
11 | "views/account_move_view.xml",
12 | "security/ir.model.access.csv",
13 | ],
14 | "assets": {
15 | "web.assets_backend": [
16 | "account_invoice_tax/static/src/xml/**/*",
17 | ],
18 | },
19 | "license": "AGPL-3",
20 | "installable": True,
21 | "auto_install": False,
22 | "application": False,
23 | }
24 |
--------------------------------------------------------------------------------
/account_invoice_tax/i18n/account_invoice_tax.pot:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_tax
4 | #
5 | msgid ""
6 | msgstr ""
7 | "Project-Id-Version: Odoo Server 13.0+e\n"
8 | "Report-Msgid-Bugs-To: \n"
9 | "POT-Creation-Date: 2020-06-26 14:07+0000\n"
10 | "PO-Revision-Date: 2020-06-26 14:07+0000\n"
11 | "Last-Translator: \n"
12 | "Language-Team: \n"
13 | "MIME-Version: 1.0\n"
14 | "Content-Type: text/plain; charset=UTF-8\n"
15 | "Content-Transfer-Encoding: \n"
16 | "Plural-Forms: \n"
17 |
18 | #. module: account_invoice_tax
19 | #: model:ir.model,name:account_invoice_tax.model_account_invoice_tax
20 | msgid "Account Invoice Tax"
21 | msgstr ""
22 |
23 | #. module: account_invoice_tax
24 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_account_invoice_tax
25 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
26 | msgid "Add"
27 | msgstr ""
28 |
29 | #. module: account_invoice_tax
30 | #: model:ir.model.fields.selection,name:account_invoice_tax.selection__account_invoice_tax__type_operation__add
31 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
32 | msgid "Add Tax"
33 | msgstr ""
34 |
35 | #. module: account_invoice_tax
36 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__amount
37 | msgid "Amount"
38 | msgstr ""
39 |
40 | #. module: account_invoice_tax
41 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_account_invoice_tax
42 | msgid "Cancel"
43 | msgstr ""
44 |
45 | #. module: account_invoice_tax
46 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__create_uid
47 | msgid "Created by"
48 | msgstr ""
49 |
50 | #. module: account_invoice_tax
51 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__create_date
52 | msgid "Created on"
53 | msgstr ""
54 |
55 | #. module: account_invoice_tax
56 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__display_name
57 | msgid "Display Name"
58 | msgstr ""
59 |
60 | #. module: account_invoice_tax
61 | #: model:ir.actions.act_window,name:account_invoice_tax.action_view_account_invoice_tax
62 | msgid "Edit tax lines"
63 | msgstr ""
64 |
65 | #. module: account_invoice_tax
66 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__id
67 | msgid "ID"
68 | msgstr ""
69 |
70 | #. module: account_invoice_tax
71 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax____last_update
72 | msgid "Last Modified on"
73 | msgstr ""
74 |
75 | #. module: account_invoice_tax
76 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__write_uid
77 | msgid "Last Updated by"
78 | msgstr ""
79 |
80 | #. module: account_invoice_tax
81 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__write_date
82 | msgid "Last Updated on"
83 | msgstr ""
84 |
85 | #. module: account_invoice_tax
86 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__move_id
87 | msgid "Move"
88 | msgstr ""
89 |
90 | #. module: account_invoice_tax
91 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_account_invoice_tax
92 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
93 | msgid "Remove"
94 | msgstr ""
95 |
96 | #. module: account_invoice_tax
97 | #: model:ir.model.fields.selection,name:account_invoice_tax.selection__account_invoice_tax__type_operation__remove
98 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
99 | msgid "Remove Tax"
100 | msgstr ""
101 |
102 | #. module: account_invoice_tax
103 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__tax_id
104 | msgid "Tax"
105 | msgstr ""
106 |
107 | #. module: account_invoice_tax
108 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__type_operation
109 | msgid "Type Operation"
110 | msgstr ""
111 |
--------------------------------------------------------------------------------
/account_invoice_tax/i18n/de.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_tax
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2020
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 13.0\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2021-01-07 17:47+0000\n"
13 | "PO-Revision-Date: 2020-12-26 18:51+0000\n"
14 | "Last-Translator: Juan José Scarafía , 2020\n"
15 | "Language-Team: German (https://www.transifex.com/adhoc/teams/46451/de/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: de\n"
20 | "Plural-Forms: nplurals=2; plural=(n != 1);\n"
21 |
22 | #. module: account_invoice_tax
23 | #: model:ir.model,name:account_invoice_tax.model_account_invoice_tax
24 | msgid "Account Invoice Tax"
25 | msgstr ""
26 |
27 | #. module: account_invoice_tax
28 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_account_invoice_tax
29 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
30 | msgid "Add"
31 | msgstr ""
32 |
33 | #. module: account_invoice_tax
34 | #: model:ir.model.fields.selection,name:account_invoice_tax.selection__account_invoice_tax__type_operation__add
35 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
36 | msgid "Add Tax"
37 | msgstr ""
38 |
39 | #. module: account_invoice_tax
40 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__amount
41 | msgid "Amount"
42 | msgstr ""
43 |
44 | #. module: account_invoice_tax
45 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_account_invoice_tax
46 | msgid "Cancel"
47 | msgstr ""
48 |
49 | #. module: account_invoice_tax
50 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__create_uid
51 | msgid "Created by"
52 | msgstr "Angelegt durch"
53 |
54 | #. module: account_invoice_tax
55 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__create_date
56 | msgid "Created on"
57 | msgstr "Angelegt am"
58 |
59 | #. module: account_invoice_tax
60 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__display_name
61 | msgid "Display Name"
62 | msgstr "Anzeigebezeichnung"
63 |
64 | #. module: account_invoice_tax
65 | #: model:ir.actions.act_window,name:account_invoice_tax.action_view_account_invoice_tax
66 | msgid "Edit tax lines"
67 | msgstr ""
68 |
69 | #. module: account_invoice_tax
70 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__id
71 | msgid "ID"
72 | msgstr "ID"
73 |
74 | #. module: account_invoice_tax
75 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax____last_update
76 | msgid "Last Modified on"
77 | msgstr "Zuletzt verändert am"
78 |
79 | #. module: account_invoice_tax
80 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__write_uid
81 | msgid "Last Updated by"
82 | msgstr "Zuletzt aktualisiert durch"
83 |
84 | #. module: account_invoice_tax
85 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__write_date
86 | msgid "Last Updated on"
87 | msgstr "Zuletzt aktualisiert am"
88 |
89 | #. module: account_invoice_tax
90 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__move_id
91 | msgid "Move"
92 | msgstr ""
93 |
94 | #. module: account_invoice_tax
95 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_account_invoice_tax
96 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
97 | msgid "Remove"
98 | msgstr ""
99 |
100 | #. module: account_invoice_tax
101 | #: model:ir.model.fields.selection,name:account_invoice_tax.selection__account_invoice_tax__type_operation__remove
102 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
103 | msgid "Remove Tax"
104 | msgstr ""
105 |
106 | #. module: account_invoice_tax
107 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__tax_id
108 | msgid "Tax"
109 | msgstr ""
110 |
111 | #. module: account_invoice_tax
112 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__type_operation
113 | msgid "Type Operation"
114 | msgstr ""
115 |
--------------------------------------------------------------------------------
/account_invoice_tax/i18n/es.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_tax
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2024
7 | # Rocio Vega, 2025
8 | # Camila Vives, 2025
9 | # Gonzalo, 2025
10 | #
11 | msgid ""
12 | msgstr ""
13 | "Project-Id-Version: Odoo Server 18.0+e\n"
14 | "Report-Msgid-Bugs-To: \n"
15 | "POT-Creation-Date: 2025-05-15 16:01+0000\n"
16 | "PO-Revision-Date: 2024-12-23 18:31+0000\n"
17 | "Last-Translator: Gonzalo, 2025\n"
18 | "Language-Team: Spanish (https://app.transifex.com/adhoc/teams/46451/es/)\n"
19 | "MIME-Version: 1.0\n"
20 | "Content-Type: text/plain; charset=UTF-8\n"
21 | "Content-Transfer-Encoding: \n"
22 | "Language: es\n"
23 | "Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n"
24 |
25 | #. module: account_invoice_tax
26 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
27 | msgid "TAX: "
28 | msgstr "IMPUESTO: "
29 |
30 | #. module: account_invoice_tax
31 | #: model:ir.model,name:account_invoice_tax.model_account_invoice_tax
32 | msgid "Account Invoice Tax"
33 | msgstr "Impuesto en Factura"
34 |
35 | #. module: account_invoice_tax
36 | #: model:ir.model,name:account_invoice_tax.model_account_invoice_tax_line
37 | msgid "Account Invoice Tax line"
38 | msgstr "Línea de Impuesto en Factura"
39 |
40 | #. module: account_invoice_tax
41 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
42 | msgid "Add/update"
43 | msgstr "Agregar/Actualizar"
44 |
45 | #. module: account_invoice_tax
46 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
47 | msgid "Add/update fixed Tax"
48 | msgstr "Agregar/Actualizar Impuesto Fijo"
49 |
50 | #. module: account_invoice_tax
51 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax_line__amount
52 | msgid "Amount"
53 | msgstr "Importe"
54 |
55 | #. module: account_invoice_tax
56 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax_line__amount_company_currency
57 | msgid "Amount Company Currency"
58 | msgstr "Importe moneda de la compañía"
59 |
60 | #. module: account_invoice_tax
61 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_account_invoice_tax
62 | msgid "Cancel"
63 | msgstr "Cancelar"
64 |
65 | #. module: account_invoice_tax
66 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__company_id
67 | msgid "Company"
68 | msgstr "Empresa"
69 |
70 | #. module: account_invoice_tax
71 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__create_uid
72 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax_line__create_uid
73 | msgid "Created by"
74 | msgstr "Creado por"
75 |
76 | #. module: account_invoice_tax
77 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__create_date
78 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax_line__create_date
79 | msgid "Created on"
80 | msgstr "Creado el"
81 |
82 | #. module: account_invoice_tax
83 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__display_name
84 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax_line__display_name
85 | msgid "Display Name"
86 | msgstr "Nombre para mostrar"
87 |
88 | #. module: account_invoice_tax
89 | #. odoo-python
90 | #: code:addons/account_invoice_tax/wizards/account_invoice_tax.py:0
91 | #: model:ir.actions.act_window,name:account_invoice_tax.action_view_account_invoice_tax
92 | msgid "Edit tax lines"
93 | msgstr "Editar lineas de impuesto"
94 |
95 | #. module: account_invoice_tax
96 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__id
97 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax_line__id
98 | msgid "ID"
99 | msgstr "ID (identificación)"
100 |
101 | #. module: account_invoice_tax
102 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax_line__invoice_tax_id
103 | msgid "Invoice Tax"
104 | msgstr "Impuesto de Factura"
105 |
106 | #. module: account_invoice_tax
107 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__is_in_company_currency
108 | msgid "Is In Company Currency"
109 | msgstr "Es en moneda de la compañía"
110 |
111 | #. module: account_invoice_tax
112 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__write_uid
113 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax_line__write_uid
114 | msgid "Last Updated by"
115 | msgstr "Última Actualización por"
116 |
117 | #. module: account_invoice_tax
118 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__write_date
119 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax_line__write_date
120 | msgid "Last Updated on"
121 | msgstr "Última Actualización el"
122 |
123 | #. module: account_invoice_tax
124 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__move_id
125 | msgid "Move"
126 | msgstr "Movimiento"
127 |
128 | #. module: account_invoice_tax
129 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax_line__new_tax
130 | msgid "New Tax"
131 | msgstr "Nuevo Impuesto"
132 |
133 | #. module: account_invoice_tax
134 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax_line__tax_id
135 | msgid "Tax"
136 | msgstr "Impuesto"
137 |
138 | #. module: account_invoice_tax
139 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__tax_line_ids
140 | msgid "Tax Line"
141 | msgstr "Línea de Impuesto"
142 |
143 | #. module: account_invoice_tax
144 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_account_invoice_tax
145 | msgid "Update"
146 | msgstr "Actualizar"
147 |
--------------------------------------------------------------------------------
/account_invoice_tax/i18n/ru.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * account_invoice_tax
4 | #
5 | # Translators:
6 | # Irina Fedulova , 2020
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 13.0\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2021-01-07 17:47+0000\n"
13 | "PO-Revision-Date: 2020-12-26 18:51+0000\n"
14 | "Last-Translator: Irina Fedulova , 2020\n"
15 | "Language-Team: Russian (https://www.transifex.com/adhoc/teams/46451/ru/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: ru\n"
20 | "Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n"
21 |
22 | #. module: account_invoice_tax
23 | #: model:ir.model,name:account_invoice_tax.model_account_invoice_tax
24 | msgid "Account Invoice Tax"
25 | msgstr ""
26 |
27 | #. module: account_invoice_tax
28 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_account_invoice_tax
29 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
30 | msgid "Add"
31 | msgstr ""
32 |
33 | #. module: account_invoice_tax
34 | #: model:ir.model.fields.selection,name:account_invoice_tax.selection__account_invoice_tax__type_operation__add
35 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
36 | msgid "Add Tax"
37 | msgstr ""
38 |
39 | #. module: account_invoice_tax
40 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__amount
41 | msgid "Amount"
42 | msgstr ""
43 |
44 | #. module: account_invoice_tax
45 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_account_invoice_tax
46 | msgid "Cancel"
47 | msgstr "Отмена"
48 |
49 | #. module: account_invoice_tax
50 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__create_uid
51 | msgid "Created by"
52 | msgstr "Создано"
53 |
54 | #. module: account_invoice_tax
55 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__create_date
56 | msgid "Created on"
57 | msgstr "Создано"
58 |
59 | #. module: account_invoice_tax
60 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__display_name
61 | msgid "Display Name"
62 | msgstr "Показать имя"
63 |
64 | #. module: account_invoice_tax
65 | #: model:ir.actions.act_window,name:account_invoice_tax.action_view_account_invoice_tax
66 | msgid "Edit tax lines"
67 | msgstr ""
68 |
69 | #. module: account_invoice_tax
70 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__id
71 | msgid "ID"
72 | msgstr "ID"
73 |
74 | #. module: account_invoice_tax
75 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax____last_update
76 | msgid "Last Modified on"
77 | msgstr "Изменено"
78 |
79 | #. module: account_invoice_tax
80 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__write_uid
81 | msgid "Last Updated by"
82 | msgstr "Обновлено"
83 |
84 | #. module: account_invoice_tax
85 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__write_date
86 | msgid "Last Updated on"
87 | msgstr "Обновлено"
88 |
89 | #. module: account_invoice_tax
90 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__move_id
91 | msgid "Move"
92 | msgstr ""
93 |
94 | #. module: account_invoice_tax
95 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_account_invoice_tax
96 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
97 | msgid "Remove"
98 | msgstr ""
99 |
100 | #. module: account_invoice_tax
101 | #: model:ir.model.fields.selection,name:account_invoice_tax.selection__account_invoice_tax__type_operation__remove
102 | #: model_terms:ir.ui.view,arch_db:account_invoice_tax.view_move_form
103 | msgid "Remove Tax"
104 | msgstr ""
105 |
106 | #. module: account_invoice_tax
107 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__tax_id
108 | msgid "Tax"
109 | msgstr ""
110 |
111 | #. module: account_invoice_tax
112 | #: model:ir.model.fields,field_description:account_invoice_tax.field_account_invoice_tax__type_operation
113 | msgid "Type Operation"
114 | msgstr ""
115 |
--------------------------------------------------------------------------------
/account_invoice_tax/security/ir.model.access.csv:
--------------------------------------------------------------------------------
1 | id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
2 | access_account_invoice_tax,access_account_invoice_tax,account_invoice_tax.model_account_invoice_tax,account.group_account_invoice,1,1,1,0
3 | access_account_invoice_tax_line,access_account_invoice_tax_line,account_invoice_tax.model_account_invoice_tax_line,account.group_account_invoice,1,1,1,1
4 |
--------------------------------------------------------------------------------
/account_invoice_tax/static/src/xml/tax_totals.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/account_invoice_tax/views/account_move_view.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | account.move.form
6 | account.move
7 |
8 |
9 |
10 |
11 |
12 | TAX:
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/account_invoice_tax/wizards/__init__.py:
--------------------------------------------------------------------------------
1 | # Part of Odoo. See LICENSE file for full copyright and licensing details.
2 | from . import account_invoice_tax
3 |
--------------------------------------------------------------------------------
/account_invoice_tax/wizards/account_invoice_tax.py:
--------------------------------------------------------------------------------
1 | # Part of Odoo. See LICENSE file for full copyright and licensing details.
2 | from odoo import Command, _, api, fields, models
3 |
4 |
5 | class AccountInvoiceTax(models.TransientModel):
6 | _name = "account.invoice.tax"
7 | _description = "Account Invoice Tax"
8 |
9 | move_id = fields.Many2one("account.move", required=True)
10 | company_id = fields.Many2one(related="move_id.company_id")
11 | tax_line_ids = fields.One2many("account.invoice.tax_line", "invoice_tax_id")
12 |
13 | is_in_company_currency = fields.Boolean(compute="_compute_is_in_company_currency")
14 |
15 | @api.model
16 | def default_get(self, fields):
17 | res = super().default_get(fields)
18 | move_ids = (
19 | self.env["account.move"].browse(self.env.context["active_ids"])
20 | if self.env.context.get("active_model") == "account.move"
21 | else self.env["account.move"]
22 | )
23 | res["move_id"] = move_ids[0].id if move_ids else False
24 | lines = []
25 | for line in move_ids[0].line_ids.filtered(lambda x: x.tax_line_id):
26 | lines.append(
27 | Command.create({"tax_id": line.tax_line_id.id, "amount": line.amount_currency, "new_tax": False})
28 | )
29 | res["tax_line_ids"] = lines
30 |
31 | return res
32 |
33 | def action_update_tax(self):
34 | move = self.move_id
35 | fixed_taxes_bu = {
36 | line.tax_line_id: {
37 | "amount_currency": line.amount_currency,
38 | "debit": line.debit,
39 | "credit": line.credit,
40 | }
41 | for line in self.move_id.line_ids.filtered(
42 | lambda x: x.tax_repartition_line_id.tax_id.amount_type == "fixed"
43 | )
44 | }
45 |
46 | active_tax = self.tax_line_ids.mapped("tax_id")
47 | origin_tax = self.move_id.line_ids.filtered(lambda x: x.tax_line_id).mapped("tax_repartition_line_id.tax_id")
48 | to_remove_tax = origin_tax - active_tax
49 | to_add_tax = active_tax - origin_tax
50 | container = {"records": move, "self": move}
51 |
52 | # change tax list
53 | with move.with_context(check_move_validity=False)._check_balanced(container):
54 | with move._sync_dynamic_lines(container):
55 | if to_remove_tax:
56 | move.invoice_line_ids.filtered(lambda x: x.display_type == "product").write(
57 | {"tax_ids": [Command.unlink(tax_id.id) for tax_id in to_remove_tax]}
58 | )
59 | if to_add_tax:
60 | move.invoice_line_ids.filtered(lambda x: x.display_type == "product").write(
61 | {"tax_ids": [Command.link(tax_id.id) for tax_id in to_add_tax]}
62 | )
63 |
64 | # set amount in the new created tax line. En este momento si queda balanceado y se ajusta la linea AP/AR
65 | container = {"records": move}
66 | with move._check_balanced(container):
67 | with move._sync_dynamic_lines(container):
68 | # restauramos todos los valores de impuestos fixed que se habrian recomputado
69 | # restaured = []
70 | for tax_line in move.line_ids.filtered(
71 | lambda x: x.tax_repartition_line_id.tax_id in fixed_taxes_bu
72 | and x.tax_repartition_line_id.tax_id.amount_type == "fixed"
73 | ):
74 | tax_line.write(fixed_taxes_bu.get(tax_line.tax_line_id))
75 | for tax_line_id in self.tax_line_ids:
76 | # seteamos valor al impuesto segun lo que puso en el wizard
77 | line_with_tax = move.line_ids.filtered(lambda x: x.tax_line_id == tax_line_id.tax_id)
78 | line_with_tax.write(tax_line_id._get_amount_updated_values())
79 |
80 | def add_tax_and_new(self):
81 | self.add_tax()
82 | return {
83 | "type": "ir.actions.act_window",
84 | "name": _("Edit tax lines"),
85 | "res_model": self._name,
86 | "target": "new",
87 | "view_mode": "form",
88 | "context": self._context,
89 | }
90 |
91 | @api.depends("move_id")
92 | def _compute_is_in_company_currency(self):
93 | self.is_in_company_currency = self.move_id.currency_id == self.move_id.company_currency_id
94 |
95 |
96 | class AccountInvoiceTaxLine(models.TransientModel):
97 | _name = "account.invoice.tax_line"
98 | _description = "Account Invoice Tax line"
99 |
100 | invoice_tax_id = fields.Many2one("account.invoice.tax")
101 | tax_id = fields.Many2one("account.tax", required=True)
102 | amount = fields.Float()
103 | amount_company_currency = fields.Float(
104 | compute="_compute_amount_company_currency",
105 | readonly=False,
106 | store=True,
107 | )
108 |
109 | new_tax = fields.Boolean(default=True)
110 |
111 | def _get_amount_updated_values(self):
112 | debit = credit = debit_cc = credit_cc = 0
113 | if self.invoice_tax_id.move_id.move_type == "in_invoice":
114 | if self.amount > 0:
115 | debit = self.amount
116 | debit_cc = self.amount_company_currency
117 | elif self.amount < 0:
118 | credit = -self.amount
119 | credit_cc = -self.amount_company_currency
120 | else: # For refund
121 | if self.amount > 0:
122 | credit = self.amount
123 | credit_cc = self.amount_company_currency
124 | elif self.amount < 0:
125 | debit = -self.amount
126 | debit_cc = -self.amount_company_currency
127 |
128 | # If multi currency enable
129 | move_currency = self.invoice_tax_id.move_id.currency_id
130 | company_currency = self.invoice_tax_id.move_id.company_currency_id
131 | not_company_currency = move_currency and move_currency != company_currency
132 |
133 | values = {
134 | "debit": debit_cc if not_company_currency else debit,
135 | "credit": credit_cc if not_company_currency else credit,
136 | "balance": (self.amount_company_currency if not_company_currency else self.amount) * (1 if debit else -1),
137 | }
138 |
139 | if not_company_currency and self.amount:
140 | values["amount_currency"] = self.amount
141 |
142 | return values
143 |
144 | def _compute_amount_company_currency(self):
145 | for line in self:
146 | taxes = line.invoice_tax_id.move_id.tax_totals["subtotals"][0]["tax_groups"]
147 | for tax_group in taxes:
148 | if line.tax_id.id == tax_group["involved_tax_ids"][0]:
149 | line.amount_company_currency = tax_group["tax_amount"]
150 | break
151 |
--------------------------------------------------------------------------------
/account_invoice_tax/wizards/account_invoice_tax_view.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | account.invoce.tax.form
5 | account.invoice.tax
6 |
7 |
25 |
26 |
27 |
28 | Edit tax lines
29 | account.invoice.tax
30 | form
31 | new
32 |
33 |
34 |
--------------------------------------------------------------------------------
/pyproject.toml:
--------------------------------------------------------------------------------
1 | [tool.ruff]
2 | line-length = 120
3 |
4 | [tool.ruff.lint]
5 | select = [
6 | "E", # pycodestyle errors
7 | "W", # pycodestyle warnings
8 | "C90", # mccabe
9 | "F", # pyflakes
10 | "UP", # pyupgrade
11 | "I", # isort
12 | ]
13 | ignore = [
14 | "UP008", # pyupgrade: Use `super()` instead of `super(__class__, self)` (no autofix)
15 | "UP031", # pyupgrade: use format specifiers instead of percent format (no autofix)
16 | "E712", # avoid equality comparisons to False (no autofix)
17 | "E721", # do not compare types, use 'isinstance()' (no autofix)
18 | "E722", # do not use bare `except` (no autofix)
19 | "E731", # do not assign `lambda` expression, use a `def` (no autofix)
20 | "E741", # ambiguos variable name (no autofix)
21 | ]
22 |
23 | [tool.ruff.lint.per-file-ignores]
24 | "__init__.py" = ["F401", "I001"]
25 | "__manifest__.py" = ["B018"]
26 |
27 | [tool.ruff.lint.pycodestyle]
28 | # line-length is set in [tool.ruff], and it's used by the formatter
29 | # in case the formatted can't autofix the line length, it will be reported as an error
30 | # only if it exceeds the max-line-length set here. We use 999 to effectively disable
31 | # this check.
32 | max-line-length = 999
33 |
34 | [tool.ruff.lint.isort]
35 | combine-as-imports = true
36 | force-wrap-aliases = true
37 | known-third-party = [
38 | "dateutil",
39 | "git",
40 | "gnupg",
41 | "openupgradelib",
42 | "pkg_resources",
43 | "psycopg2",
44 | "requests",
45 | "setuptools",
46 | "urllib2",
47 | "yaml",
48 | ]
49 |
50 | [tool.ruff.lint.mccabe]
51 | max-complexity = 20
52 |
53 | [tool.pylint.master]
54 | load-plugins = ["pylint_odoo"]
55 | score = false
56 |
57 | [tool.pylint.odoolint]
58 | manifest-required-authors = "ADHOC SA"
59 | manifest-required-keys = ["license"]
60 | manifest-deprecated-keys = ["description", "active"]
61 | license-allowed = [
62 | "AGPL-3",
63 | "GPL-2",
64 | "GPL-2 or any later version",
65 | "GPL-3",
66 | "GPL-3 or any later version",
67 | "LGPL-3",
68 | ]
69 |
70 | [tool.pylint."messages control"]
71 | disable = "all"
72 | enable = [
73 | "anomalous-backslash-in-string",
74 | "api-one-deprecated",
75 | "api-one-multi-together",
76 | "assignment-from-none",
77 | "attribute-deprecated",
78 | "attribute-string-redundant",
79 | "character-not-valid-in-resource-link",
80 | "class-camelcase",
81 | "consider-merging-classes-inherited",
82 | "context-overridden",
83 | "create-user-wo-reset-password",
84 | "dangerous-default-value",
85 | "dangerous-filter-wo-user",
86 | "dangerous-qweb-replace-wo-priority",
87 | "dangerous-view-replace-wo-priority",
88 | "deprecated-data-xml-node",
89 | "deprecated-openerp-xml-node",
90 | "development-status-allowed",
91 | "duplicate-id-csv",
92 | "duplicate-key",
93 | "duplicate-po-message-definition",
94 | "duplicate-xml-fields",
95 | "duplicate-xml-record-id",
96 | "eval-referenced",
97 | "eval-used",
98 | # "except-pass", # Annoying
99 | "external-request-timeout",
100 | "file-not-used",
101 | "incoherent-interpreter-exec-perm",
102 | "invalid-commit",
103 | "license-allowed",
104 | "manifest-author-string",
105 | "manifest-deprecated-key",
106 | "manifest-maintainers-list",
107 | "manifest-required-author",
108 | "manifest-required-key",
109 | # "manifest-version-format", # Errors on non-migrated modules, and redundant with runbot
110 | "method-compute",
111 | "method-inverse",
112 | "method-required-super",
113 | "method-search",
114 | "missing-newline-extrafiles",
115 | # "missing-return", # Annoying. Not applicable for computed field methods
116 | "odoo-addons-relative-import",
117 | "old-api7-method-defined",
118 | "openerp-exception-warning",
119 | "po-msgstr-variables",
120 | "po-syntax-error",
121 | "pointless-statement",
122 | "pointless-string-statement",
123 | "print-used",
124 | "redundant-keyword-arg",
125 | "redundant-modulename-xml",
126 | "reimported",
127 | "relative-import",
128 | "renamed-field-parameter",
129 | "resource-not-exist",
130 | "return-in-init",
131 | "rst-syntax-error",
132 | "sql-injection",
133 | "str-format-used",
134 | "test-folder-imported",
135 | "too-few-format-args",
136 | "translation-contains-variable",
137 | "translation-field",
138 | # "translation-positional-used", # Annoying in our use case
139 | # "translation-required", # We don't always translate everything, and that's fine
140 | "unnecessary-utf8-coding-comment",
141 | "unreachable",
142 | "use-vim-comment",
143 | "wrong-tabs-instead-of-spaces",
144 | "xml-attribute-translatable",
145 | "xml-deprecated-qweb-directive",
146 | "xml-deprecated-tree-attribute",
147 | "xml-syntax-error"
148 | ]
149 |
150 | [tool.pylint.reports]
151 | output-format = "colorized"
152 | msg-template = "{path}:{line}: [{msg_id}({symbol}), {obj}] {msg}"
153 |
--------------------------------------------------------------------------------
/requirements.txt:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ingadhoc/account-invoicing/68f284e76b1079b707533b52ea479d3c90aded9b/requirements.txt
--------------------------------------------------------------------------------
/website_sale_account_invoice_commission/README.rst:
--------------------------------------------------------------------------------
1 | .. |company| replace:: ADHOC SA
2 |
3 | .. |company_logo| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-logo.png
4 | :alt: ADHOC SA
5 | :target: https://www.adhoc.com.ar
6 |
7 | .. |icon| image:: https://raw.githubusercontent.com/ingadhoc/maintainer-tools/master/resources/adhoc-icon.png
8 |
9 | .. image:: https://img.shields.io/badge/license-AGPL--3-blue.png
10 | :target: https://www.gnu.org/licenses/agpl
11 | :alt: License: AGPL-3
12 |
13 | ==========================================
14 | Commission Invoices with Public Categories
15 | ==========================================
16 |
17 | Extend commission rules to be set with public categories.
18 |
19 | Installation
20 | ============
21 |
22 | To install this module, you need to:
23 |
24 | #. Only need to install the module
25 |
26 | Configuration
27 | =============
28 |
29 | To configure this module, you need to:
30 |
31 | #. Nothing to configure
32 |
33 | Usage
34 | =====
35 |
36 | To use this module, you need to:
37 |
38 | #. Just Use the module.
39 |
40 | .. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
41 | :alt: Try me on Runbot
42 | :target: http://runbot.adhoc.com.ar/
43 |
44 | Bug Tracker
45 | ===========
46 |
47 | Bugs are tracked on `GitHub Issues
48 | `_. In case of trouble, please
49 | check there if your issue has already been reported. If you spotted it first,
50 | help us smashing it by providing a detailed and welcomed feedback.
51 |
52 | Credits
53 | =======
54 |
55 | Images
56 | ------
57 |
58 | * |company| |icon|
59 |
60 | Contributors
61 | ------------
62 |
63 | Maintainer
64 | ----------
65 |
66 | |company_logo|
67 |
68 | This module is maintained by the |company|.
69 |
70 | To contribute to this module, please visit https://www.adhoc.com.ar.
71 |
--------------------------------------------------------------------------------
/website_sale_account_invoice_commission/__init__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from . import models
6 |
--------------------------------------------------------------------------------
/website_sale_account_invoice_commission/__manifest__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | #
3 | # Copyright (C) 2015 ADHOC SA (http://www.adhoc.com.ar)
4 | # All Rights Reserved.
5 | #
6 | # This program is free software: you can redistribute it and/or modify
7 | # it under the terms of the GNU Affero General Public License as
8 | # published by the Free Software Foundation, either version 3 of the
9 | # License, or (at your option) any later version.
10 | #
11 | # This program is distributed in the hope that it will be useful,
12 | # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | # GNU Affero General Public License for more details.
15 | #
16 | # You should have received a copy of the GNU Affero General Public License
17 | # along with this program. If not, see .
18 | #
19 | ##############################################################################
20 | {
21 | "name": "Commission Invoices with Public Categories",
22 | "version": "18.0.1.0.0",
23 | "category": "Accounting",
24 | "sequence": 14,
25 | "summary": "",
26 | "author": "ADHOC SA",
27 | "website": "www.adhoc.com.ar",
28 | "license": "AGPL-3",
29 | "images": [],
30 | "depends": [
31 | "account_invoice_commission",
32 | "website_sale",
33 | ],
34 | "data": [
35 | "views/account_commission_rule_views.xml",
36 | ],
37 | "demo": [],
38 | "installable": True,
39 | "auto_install": True,
40 | "application": False,
41 | }
42 |
--------------------------------------------------------------------------------
/website_sale_account_invoice_commission/i18n/es.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * website_sale_account_invoice_commission
4 | #
5 | # Translators:
6 | # Juan José Scarafía , 2024
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 18.0+e\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2024-11-14 20:36+0000\n"
13 | "PO-Revision-Date: 2024-11-14 20:36+0000\n"
14 | "Last-Translator: Juan José Scarafía , 2024\n"
15 | "Language-Team: Spanish (https://app.transifex.com/adhoc/teams/46451/es/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: es\n"
20 | "Plural-Forms: nplurals=3; plural=n == 1 ? 0 : n != 0 && n % 1000000 == 0 ? 1 : 2;\n"
21 |
22 | #. module: website_sale_account_invoice_commission
23 | #: model:ir.model,name:website_sale_account_invoice_commission.model_account_commission_rule
24 | msgid "Account Commission Rule"
25 | msgstr "Regla de Comisión de Cuenta"
26 |
27 | #. module: website_sale_account_invoice_commission
28 | #: model:ir.model.fields,field_description:website_sale_account_invoice_commission.field_account_commission_rule__algolia_search
29 | msgid "Algolia Search"
30 | msgstr ""
31 |
32 | #. module: website_sale_account_invoice_commission
33 | #: model:ir.model.fields,field_description:website_sale_account_invoice_commission.field_account_commission_rule__public_category_id
34 | msgid "Website Category"
35 | msgstr " Categoría del sitio web"
36 |
--------------------------------------------------------------------------------
/website_sale_account_invoice_commission/i18n/ru.po:
--------------------------------------------------------------------------------
1 | # Translation of Odoo Server.
2 | # This file contains the translation of the following modules:
3 | # * website_sale_account_invoice_commission
4 | #
5 | # Translators:
6 | # Irina Fedulova , 2020
7 | #
8 | msgid ""
9 | msgstr ""
10 | "Project-Id-Version: Odoo Server 13.0\n"
11 | "Report-Msgid-Bugs-To: \n"
12 | "POT-Creation-Date: 2021-01-07 17:47+0000\n"
13 | "PO-Revision-Date: 2020-07-17 16:04+0000\n"
14 | "Last-Translator: Irina Fedulova , 2020\n"
15 | "Language-Team: Russian (https://www.transifex.com/adhoc/teams/46451/ru/)\n"
16 | "MIME-Version: 1.0\n"
17 | "Content-Type: text/plain; charset=UTF-8\n"
18 | "Content-Transfer-Encoding: \n"
19 | "Language: ru\n"
20 | "Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n"
21 |
22 | #. module: website_sale_account_invoice_commission
23 | #: model:ir.model,name:website_sale_account_invoice_commission.model_account_commission_rule
24 | msgid "Account Commission Rule"
25 | msgstr ""
26 |
27 | #. module: website_sale_account_invoice_commission
28 | #: model:ir.model.fields,field_description:website_sale_account_invoice_commission.field_account_commission_rule__public_category_id
29 | msgid "Website Category"
30 | msgstr "Категория веб-сайта"
31 |
--------------------------------------------------------------------------------
/website_sale_account_invoice_commission/models/__init__.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from . import account_commission_rule
6 |
--------------------------------------------------------------------------------
/website_sale_account_invoice_commission/models/account_commission_rule.py:
--------------------------------------------------------------------------------
1 | ##############################################################################
2 | # For copyright and license notices, see __manifest__.py file in module root
3 | # directory
4 | ##############################################################################
5 | from odoo import fields, models
6 |
7 |
8 | class AccountCommissionRule(models.Model):
9 | _inherit = "account.commission.rule"
10 |
11 | public_category_id = fields.Many2one(
12 | "product.public.category",
13 | "Website Category",
14 | auto_join=True,
15 | )
16 |
17 | def _get_rule_domain(self, date, product, partner_id, customer, amount):
18 | domain = super()._get_rule_domain(date, product, partner_id, customer, amount)
19 | if not product:
20 | domain += [("public_category_id", "=", False)]
21 | else:
22 | domain += [
23 | "|",
24 | ("public_category_id", "=", False),
25 | ("public_category_id", "parent_of", product.public_categ_ids.ids),
26 | ]
27 | return domain
28 |
--------------------------------------------------------------------------------
/website_sale_account_invoice_commission/views/account_commission_rule_views.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | account.commission.rule.list
5 | account.commission.rule
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------