-
-
Notifications
You must be signed in to change notification settings - Fork 118
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[18.0][MIG] l10n_fr_siret + add glue module l10n_fr_siret_account #584
base: 18.0
Are you sure you want to change the base?
Conversation
siren = fields.Char(tracking=50) | ||
nic = fields.Char(tracking=51) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't get why you redefine this two fields on the glue module. Why not in base module ?
also I'm not very familiar with this new tracking values. could you elaborate ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tracking is a feature of the mail module, not base. l10n_fr_siret_account depend on account which depend on mail.
For example, you will not see tracking=X on res.partner fields defined in the base module... they are in the mail module: https://github.com/odoo/odoo/blob/18.0/addons/mail/models/res_partner.py#L19
Very nice modular move.
+1, indeed. |
…ile and fr translation
Prepare the migration of l10n_fr_naf_ape to v10
Start with good version names
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate. Translation: l10n-france-14.0/l10n-france-14.0-l10n_fr_siret Translate-URL: https://translation.odoo-community.org/projects/l10n-france-14-0/l10n-france-14-0-l10n_fr_siret/
Currently translated at 100.0% (23 of 23 strings) Translation: l10n-france-16.0/l10n-france-16.0-l10n_fr_siret Translate-URL: https://translation.odoo-community.org/projects/l10n-france-16-0/l10n-france-16-0-l10n_fr_siret/fr/
Currently translated at 100.0% (23 of 23 strings) Translation: l10n-france-16.0/l10n-france-16.0-l10n_fr_siret Translate-URL: https://translation.odoo-community.org/projects/l10n-france-16-0/l10n-france-16-0-l10n_fr_siret/es/
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate. Translation: l10n-france-16.0/l10n-france-16.0-l10n_fr_siret Translate-URL: https://translation.odoo-community.org/projects/l10n-france-16-0/l10n-france-16-0-l10n_fr_siret/
Currently translated at 100.0% (21 of 21 strings) Translation: l10n-france-16.0/l10n-france-16.0-l10n_fr_siret Translate-URL: https://translation.odoo-community.org/projects/l10n-france-16-0/l10n-france-16-0-l10n_fr_siret/es/
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate. Translation: l10n-france-17.0/l10n-france-17.0-l10n_fr_siret Translate-URL: https://translation.odoo-community.org/projects/l10n-france-17-0/l10n-france-17-0-l10n_fr_siret/
Fixes OCA#38 l10n_fr_siret: unrequired dependency on account This is now possible because l10n_fr doesn't depend on account anymore and there is a new official module l10n_fr_account that acts as a glue module between l10n_fr and account.
7c715e3
to
b19448f
Compare
siren = fields.Char( | ||
string="SIREN", related="partner_id.siren", store=True, readonly=False | ||
) | ||
nic = fields.Char( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Presuming the nic here seems to be problematic.
The basic problem is that we've only been able to structure the res_partner companies (unique SIREN) by having the partner marked 'company' having the SIREN, but with a null NIC giving a SIRET as *****, adding for each establishment a child partner with it's NIC set correctly.
For the case of the HQ (siège), setting the partner type 'invoice' as well as setting it as the default invoiced partner for the company (for other partners, customer or suppliers, it may not be exactly that way).
What happens here with a blank nic is that it'll probably break the SIRET in a number of reports.
Unfortunately, it is seemingly not possible to non-programatically change the partner_id on the company.
Perhaps what is needed on the res_partner company is a HQ link to the child partner currently registered as HQ (siège), which link could be followed to make res_company happy... or at least so if NIC is null.
BTW, when the company moves [the HQ], it is straight-forward that the company partner is the only place that these details should be managed (creation of establishments, archival of closed establishments, et cetera).
Last but not least, the SIRET has a opening date, and at some point in time a possible closing date.
Since v18, l10n_fr doesn't depend on account (only on base) and there is a glue module l10n_fr_account.
So, we should follow this movement in OCA and have l10n_fr_siret and l10n_fr_siret_account
Fixes #38 which was opened 9 years ago !!!
Small improvements: add siren/siret/nic in list view as optional=hide
This migration PR is an alternative to #578