Skip to content

Commit

Permalink
[FIX] l10n_it_edi: Codes in XML template shouldn't be translated
Browse files Browse the repository at this point in the history
Codes like "Exch.Rate" in the Italian EDI XML template for invoices were
translated. They shouldn't be, as they have pretty short char limit and
it's risky to people change that. The XML users are either domestic or
the Italian Tax Agency itself, so no point in translating "Divisa" into
"Currency" anyway.

Link: https://www.odoo.com/web#model=project.task&id=3627379
opw-3627379

closes #156134

X-original-commit: b9e44a0
Signed-off-by: William André (wan) <wan@odoo.com>
Signed-off-by: Paolo Gatti (pgi) <pgi@odoo.com>
  • Loading branch information
lordkrandel committed Mar 1, 2024
1 parent 0e354f2 commit 7ec2cec
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 101 deletions.
2 changes: 1 addition & 1 deletion addons/l10n_it_edi/data/invoice_it_simplified_template.xml
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@
</t>
<Allegati t-if="pdf">
<NomeAttachment t-out="format_alphanumeric(pdf_name[:60])"/>
<FormatoAttachment>PDF</FormatoAttachment>
<FormatoAttachment t-translation="off">PDF</FormatoAttachment>
<Attachment t-out="pdf"/>
</Allegati>
</FatturaElettronicaBody>
Expand Down
16 changes: 8 additions & 8 deletions addons/l10n_it_edi/data/invoice_it_template.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@
<DettaglioLinee>
<NumeroLinea t-out="line_dict['line_number']"/>
<CodiceArticolo t-if="line.product_id.barcode">
<CodiceTipo>EAN</CodiceTipo>
<CodiceTipo t-translation="off">EAN</CodiceTipo>
<CodiceValore t-out="format_alphanumeric(line.product_id.barcode)[:35]"/>
</CodiceArticolo>
<CodiceArticolo t-elif="line.product_id.default_code">
<CodiceTipo>INTERNAL</CodiceTipo>
<CodiceTipo t-translation="off">INTERNAL</CodiceTipo>
<CodiceValore t-out="format_alphanumeric(line.product_id.default_code)[:35]"/>
</CodiceArticolo>
<Descrizione t-out="format_alphanumeric(line_dict['description'])[:1000]"/>
Expand All @@ -26,12 +26,12 @@
<AliquotaIVA t-elif="vat_tax.amount_type != 'percent'" t-out="'0.00'"/>
<Natura t-if="vat_tax.l10n_it_has_exoneration" t-out="vat_tax.l10n_it_kind_exoneration"/>
<AltriDatiGestionali t-if="conversion_rate">
<TipoDato>Currency</TipoDato>
<TipoDato t-translation="off">DIVISA</TipoDato>
<RiferimentoTesto t-out="format_alphanumeric(record.currency_id.name)"/>
<RiferimentoNumero t-out="'%.06f' % line.price_subtotal"/>
</AltriDatiGestionali>
<AltriDatiGestionali t-if="conversion_rate">
<TipoDato>Exch.Rate</TipoDato>
<TipoDato t-translation="off">CAMBIO</TipoDato>
<RiferimentoNumero t-out="conversion_rate"/>
<RiferimentoData t-out="format_date(record.invoice_date)"/>
</AltriDatiGestionali>
Expand Down Expand Up @@ -143,7 +143,7 @@
<Data t-out="format_date(record.invoice_date)"/>
<Numero t-out="format_alphanumeric(record.name[-20:])"/>
<DatiBollo t-if="record.l10n_it_stamp_duty">
<BolloVirtuale>SI</BolloVirtuale>
<BolloVirtuale t-translation="off">SI</BolloVirtuale>
<ImportoBollo t-out="format_numbers(record.l10n_it_stamp_duty)"/>
</DatiBollo>
<ImportoTotaleDocumento t-out="format_monetary(document_total, currency)"/>
Expand Down Expand Up @@ -202,10 +202,10 @@
</DatiBeniServizi>
<DatiPagamento t-if="partner_bank and record.move_type != 'out_refund'">
<t t-set="payments" t-value="record.line_ids.filtered(lambda line: line.account_id.account_type in ('asset_receivable', 'liability_payable'))"/>
<CondizioniPagamento><t t-if="len(payments) == 1">TP02</t><t t-else="">TP01</t></CondizioniPagamento>
<CondizioniPagamento t-translation="off"><t t-if="len(payments) == 1">TP02</t><t t-else="">TP01</t></CondizioniPagamento>
<t t-foreach="payments" t-as="payment">
<DettaglioPagamento>
<ModalitaPagamento>MP05</ModalitaPagamento>
<ModalitaPagamento t-translation="off">MP05</ModalitaPagamento>
<DataScadenzaPagamento t-out="format_date(payment.date_maturity)"/>
<ImportoPagamento t-out="format_monetary(abs(payment.amount_currency), currency)"/>
<IstitutoFinanziario t-if="partner_bank.bank_id" t-out="format_alphanumeric(partner_bank.bank_id.name[:80])"/>
Expand All @@ -217,7 +217,7 @@
</DatiPagamento>
<Allegati t-if="pdf">
<NomeAttachment t-out="format_alphanumeric(pdf_name[:60])"/>
<FormatoAttachment>PDF</FormatoAttachment>
<FormatoAttachment t-translation="off">PDF</FormatoAttachment>
<Attachment t-out="pdf"/>
</Allegati>
</FatturaElettronicaBody>
Expand Down
46 changes: 0 additions & 46 deletions addons/l10n_it_edi/i18n/it.po
Original file line number Diff line number Diff line change
Expand Up @@ -218,11 +218,6 @@ msgstr "Creato da"
msgid "Created on"
msgstr "Creato il"

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_line_it_FatturaPA
msgid "Currency"
msgstr "Valuta"

#. module: l10n_it_edi
#: model:ir.model.fields,field_description:l10n_it_edi.field_account_bank_statement_line__l10n_it_ddt_id
#: model:ir.model.fields,field_description:l10n_it_edi.field_account_move__l10n_it_ddt_id
Expand Down Expand Up @@ -278,11 +273,6 @@ msgstr "Data Documento non valida nel file XML:"
msgid "E-Invoice is generated on %s by %s"
msgstr "La Fattura Elettronica è stata generata il %s da %s"

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_line_it_FatturaPA
msgid "EAN"
msgstr "EAN"

#. module: l10n_it_edi
#: model:ir.model,name:l10n_it_edi.model_account_edi_format
msgid "EDI format"
Expand Down Expand Up @@ -321,11 +311,6 @@ msgstr "Fattura Elettronica"
msgid "Email Templates"
msgstr "Modello Email"

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_line_it_FatturaPA
msgid "Exch.Rate"
msgstr "Tasso di Cambio"

#. module: l10n_it_edi
#: model:ir.model.fields,field_description:l10n_it_edi.field_account_tax__l10n_it_kind_exoneration
msgid "Exoneration"
Expand Down Expand Up @@ -370,11 +355,6 @@ msgstr "Esente dalle tasse (Italia)"
msgid "ID"
msgstr ""

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_line_it_FatturaPA
msgid "INTERNAL"
msgstr "INTERNO"

#. module: l10n_it_edi
#. odoo-python
#: code:addons/l10n_it_edi/models/res_company.py:0
Expand Down Expand Up @@ -518,11 +498,6 @@ msgstr "Riferimento alla Legge"
msgid "Liquidation state"
msgstr "Stato Liquidazione"

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_it_FatturaPA_export
msgid "MP05"
msgstr ""

#. module: l10n_it_edi
#: model:ir.model.fields,help:l10n_it_edi.field_res_company__l10n_it_eco_index_share_capital
msgid ""
Expand Down Expand Up @@ -569,12 +544,6 @@ msgstr "Numero DDT"
msgid "Official"
msgstr "Ufficiale"

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_it_FatturaPA_export
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_it_simplified_FatturaPA_export
msgid "PDF"
msgstr "PDF"

#. module: l10n_it_edi
#: model:ir.model.fields,field_description:l10n_it_edi.field_res_partner__l10n_it_pec_email
#: model:ir.model.fields,field_description:l10n_it_edi.field_res_users__l10n_it_pec_email
Expand Down Expand Up @@ -613,11 +582,6 @@ msgstr "Per favore, selezionare il Sistema Fiscale a cui si è soggetti."
msgid "Province of the register-of-companies office"
msgstr "Provincia dell'ufficio del Registro delle Imprese"

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_it_FatturaPA_export
msgid "SI"
msgstr "SI"

#. module: l10n_it_edi
#. odoo-python
#: code:addons/l10n_it_edi/models/account_edi_format.py:0
Expand Down Expand Up @@ -647,16 +611,6 @@ msgstr ""
msgid "Split Payment is not compatible with exoneration of kind 'N6'"
msgstr "'Scissione dei pagamenti' non è compatibile con l'esenzione di tipo 'N6'"

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_it_FatturaPA_export
msgid "TP01"
msgstr ""

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_it_FatturaPA_export
msgid "TP02"
msgstr ""

#. module: l10n_it_edi
#: model:ir.model,name:l10n_it_edi.model_account_tax
msgid "Tax"
Expand Down
46 changes: 0 additions & 46 deletions addons/l10n_it_edi/i18n/l10n_it_edi.pot
Original file line number Diff line number Diff line change
Expand Up @@ -221,11 +221,6 @@ msgstr ""
msgid "Created on"
msgstr ""

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_line_it_FatturaPA
msgid "Currency"
msgstr ""

#. module: l10n_it_edi
#: model:ir.model.fields,field_description:l10n_it_edi.field_account_bank_statement_line__l10n_it_ddt_id
#: model:ir.model.fields,field_description:l10n_it_edi.field_account_move__l10n_it_ddt_id
Expand Down Expand Up @@ -281,11 +276,6 @@ msgstr ""
msgid "E-Invoice is generated on %s by %s"
msgstr ""

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_line_it_FatturaPA
msgid "EAN"
msgstr ""

#. module: l10n_it_edi
#: model:ir.model,name:l10n_it_edi.model_account_edi_format
msgid "EDI format"
Expand Down Expand Up @@ -324,11 +314,6 @@ msgstr ""
msgid "Email Templates"
msgstr ""

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_line_it_FatturaPA
msgid "Exch.Rate"
msgstr ""

#. module: l10n_it_edi
#: model:ir.model.fields,field_description:l10n_it_edi.field_account_tax__l10n_it_kind_exoneration
msgid "Exoneration"
Expand Down Expand Up @@ -373,11 +358,6 @@ msgstr ""
msgid "ID"
msgstr ""

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_line_it_FatturaPA
msgid "INTERNAL"
msgstr ""

#. module: l10n_it_edi
#. odoo-python
#: code:addons/l10n_it_edi/models/res_company.py:0
Expand Down Expand Up @@ -505,11 +485,6 @@ msgstr ""
msgid "Liquidation state"
msgstr ""

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_it_FatturaPA_export
msgid "MP05"
msgstr ""

#. module: l10n_it_edi
#: model:ir.model.fields,help:l10n_it_edi.field_res_company__l10n_it_eco_index_share_capital
msgid ""
Expand Down Expand Up @@ -549,12 +524,6 @@ msgstr ""
msgid "Official"
msgstr ""

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_it_FatturaPA_export
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_it_simplified_FatturaPA_export
msgid "PDF"
msgstr ""

#. module: l10n_it_edi
#: model:ir.model.fields,field_description:l10n_it_edi.field_res_partner__l10n_it_pec_email
#: model:ir.model.fields,field_description:l10n_it_edi.field_res_users__l10n_it_pec_email
Expand Down Expand Up @@ -592,11 +561,6 @@ msgstr ""
msgid "Province of the register-of-companies office"
msgstr ""

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_it_FatturaPA_export
msgid "SI"
msgstr ""

#. module: l10n_it_edi
#. odoo-python
#: code:addons/l10n_it_edi/models/account_edi_format.py:0
Expand Down Expand Up @@ -626,16 +590,6 @@ msgstr ""
msgid "Split Payment is not compatible with exoneration of kind 'N6'"
msgstr ""

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_it_FatturaPA_export
msgid "TP01"
msgstr ""

#. module: l10n_it_edi
#: model_terms:ir.ui.view,arch_db:l10n_it_edi.account_invoice_it_FatturaPA_export
msgid "TP02"
msgstr ""

#. module: l10n_it_edi
#: model:ir.model,name:l10n_it_edi.model_account_tax
msgid "Tax"
Expand Down

0 comments on commit 7ec2cec

Please sign in to comment.