-
-
Notifications
You must be signed in to change notification settings - Fork 118
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ADD] account_factoring_receivable_balance_factofrance: FactoFrance F…
…actoring
- Loading branch information
Showing
13 changed files
with
929 additions
and
0 deletions.
There are no files selected for viewing
123 changes: 123 additions & 0 deletions
123
account_factoring_receivable_balance_factofrance/README.rst
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,123 @@ | ||
================================= | ||
Account Factoring for FactoFrance | ||
================================= | ||
|
||
.. | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
!! This file is generated by oca-gen-addon-readme !! | ||
!! changes will be overwritten. !! | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
!! source digest: sha256:063d495a7d079ae9bafe1d7f47890862938bed76c7a1a0a94afd8fe018ea6303 | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png | ||
:target: https://odoo-community.org/page/development-status | ||
:alt: Beta | ||
.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png | ||
:target: http://www.gnu.org/licenses/agpl-3.0-standalone.html | ||
:alt: License: AGPL-3 | ||
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fl10n--france-lightgray.png?logo=github | ||
:target: https://github.com/OCA/l10n-france/tree/17.0/account_factoring_receivable_balance_factofrance | ||
:alt: OCA/l10n-france | ||
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png | ||
:target: https://translation.odoo-community.org/projects/l10n-france-17-0/l10n-france-17-0-account_factoring_receivable_balance_factofrance | ||
:alt: Translate me on Weblate | ||
.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png | ||
:target: https://runboat.odoo-community.org/builds?repo=OCA/l10n-france&target_branch=17.0 | ||
:alt: Try me on Runboat | ||
|
||
|badge1| |badge2| |badge3| |badge4| |badge5| | ||
|
||
Gestion de balance avec BPCE | ||
|
||
**Table of contents** | ||
|
||
.. contents:: | ||
:local: | ||
|
||
Configuration | ||
============= | ||
|
||
- use a company with l10n_fr | ||
- alternatively you may create a new one with | ||
|
||
Here you can create a new company with BPCE settings for default | ||
currency | ||
|
||
.. code:: python | ||
env["res.company"]._create_french_company(company_name="my new company") | ||
Here you may create settings for a new installed currency | ||
|
||
.. code:: python | ||
env.browse(mycompany_id)._configure_bpce_factoring(currency_record) | ||
- you may execute this last method with UI in res.company form (Factor | ||
tab) | ||
- now you can go to journals and filter them with Factor type. | ||
- set bpce to Factor Type to each bank journal related to currency of | ||
previous journals. | ||
|
||
Known issues / Roadmap | ||
====================== | ||
|
||
Seul le mode de réglement est géré dans ce module. | ||
|
||
Les prélèvements, effets, BOR, et chèques ne le sont pas | ||
|
||
Dans le fichier émis en position 53, seul le cas export est traité. | ||
|
||
See TODO in source code | ||
|
||
Bug Tracker | ||
=========== | ||
|
||
Bugs are tracked on `GitHub Issues <https://github.com/OCA/l10n-france/issues>`_. | ||
In case of trouble, please check there if your issue has already been reported. | ||
If you spotted it first, help us to smash it by providing a detailed and welcomed | ||
`feedback <https://github.com/OCA/l10n-france/issues/new?body=module:%20account_factoring_receivable_balance_factofrance%0Aversion:%2017.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_. | ||
|
||
Do not contact contributors directly about support or help with technical issues. | ||
|
||
Credits | ||
======= | ||
|
||
Authors | ||
------- | ||
|
||
* Open Source Integrators | ||
|
||
Contributors | ||
------------ | ||
|
||
- Akretion: | ||
|
||
- David BEAL | ||
- Alexis DE LATTRE | ||
|
||
Maintainers | ||
----------- | ||
|
||
This module is maintained by the OCA. | ||
|
||
.. image:: https://odoo-community.org/logo.png | ||
:alt: Odoo Community Association | ||
:target: https://odoo-community.org | ||
|
||
OCA, or the Odoo Community Association, is a nonprofit organization whose | ||
mission is to support the collaborative development of Odoo features and | ||
promote its widespread use. | ||
|
||
.. |maintainer-dreispt| image:: https://github.com/dreispt.png?size=40px | ||
:target: https://github.com/dreispt | ||
:alt: dreispt | ||
|
||
Current `maintainer <https://odoo-community.org/page/maintainer-role>`__: | ||
|
||
|maintainer-dreispt| | ||
|
||
This module is part of the `OCA/l10n-france <https://github.com/OCA/l10n-france/tree/17.0/account_factoring_receivable_balance_factofrance>`_ project on GitHub. | ||
|
||
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
from . import models |
16 changes: 16 additions & 0 deletions
16
account_factoring_receivable_balance_factofrance/__manifest__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# © 2024 Open Source Integrators, Daniel Reis | ||
{ | ||
"name": "Account Factoring for FactoFrance", | ||
"version": "17.0.1.0.0", | ||
"category": "Accounting", | ||
"license": "AGPL-3", | ||
"website": "https://github.com/OCA/l10n-france", | ||
"author": "Open Source Integrators,Odoo Community Association (OCA)", | ||
"maintainers": ["dreispt"], | ||
"depends": [ | ||
"account_factoring_receivable_balance", | ||
"l10n_fr", | ||
], | ||
"data": [], | ||
"demo": [], | ||
} |
3 changes: 3 additions & 0 deletions
3
account_factoring_receivable_balance_factofrance/models/__init__.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
from . import partner | ||
from . import account_journal | ||
from . import subrogation_receipt |
13 changes: 13 additions & 0 deletions
13
account_factoring_receivable_balance_factofrance/models/account_journal.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# © 2024 Open Source Integrators, Daniel Reis | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). | ||
|
||
from odoo import fields, models | ||
|
||
|
||
class AccountJournal(models.Model): | ||
_inherit = "account.journal" | ||
|
||
factor_type = fields.Selection( | ||
selection_add=[("factofrance", "FactoFrance")], | ||
ondelete={"factofrance": "set null"}, | ||
) |
20 changes: 20 additions & 0 deletions
20
account_factoring_receivable_balance_factofrance/models/partner.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# © 2024 Open Source Integrators, Daniel Reis | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). | ||
|
||
from odoo import _, api, models | ||
from odoo.exceptions import UserError | ||
|
||
|
||
class ResPartner(models.Model): | ||
_inherit = "res.partner" | ||
|
||
@api.constrains("factor_journal_id", "ref", "siret") | ||
def _constrains_factor_journal_id(self): | ||
for rec in self: | ||
is_factofrance = rec.factor_journal_id == "factofrance" | ||
if is_factofrance and (not rec.ref or not rec.siret): | ||
msg = _( | ||
"Les balances clients gérées par FactoFrance doivent avoir " | ||
"les champs Référence et SIRET remplis" | ||
) | ||
raise UserError(msg) |
Oops, something went wrong.