Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
2 Odpowiedzi
1112 Widoki

Hi,


I create a new module that need to insert a new tax in odoo.

My concern if for french chart of account. In the source code of I10n_fr I notice the existence of the file account.tax-fr.csv that seem to contain what I want.

My problem is that I don't find where this file is load and how I could to the same thing in my custom module to load my new tax.


Can anyone help me?


Regards

Awatar
Odrzuć

Guten Tag 

Ich bin bis 23.09.2024 nicht im Büro. 

In dringenden Angelegenheiten senden Sie bitte Ihre Anfrage an support@nivels.ch oder rufen uns auf unserer Informatik Support Hotline +41 81 511 65 04 an. 

Besten Dank 

Ralf Müller


*********************** 

Dear customer Your answer to your email will be delayed as I’m in holiday until September 23.

In urgent cases please send your inquiry to support@nivels.ch or call our support helpline @ +41 81 511 65 04. 

Best regards, 

Najlepsza odpowiedź

Hi,

To insert a new tax in Odoo for the French chart of accounts, you can indeed follow a similar approach to how the account.tax-fr.csv file in the l10n_fr module works. CSV files in Odoo are typically loaded during module installation through the data section in the module's manifest file (__manifest__.py).


For example you can refer the following code:

{

    'name': 'Custom Tax Module',

    'version': '17.0.1.0.0',

    'depends': ['account'],

    'data': [

        'data/account.tax.custom.csv',

    ],

}


Hope this helps.

Awatar
Odrzuć
Autor Najlepsza odpowiedź

Hello,


Thank you very much. With your help I managed to import my new tax from a csv file. My mistake was not to have added the dependency with the localization module of my country in the manifest file.

Thanks again, you've saved me several hours going round in circles.

Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
1
lut 25
1571
1
lis 24
1403
1
kwi 24
1930
0
mar 24
1473
1
kwi 24
1758