From 696389439de6087c643162cf96a3d3f9f4f944a9 Mon Sep 17 00:00:00 2001 From: Pablo Montenegro Date: Wed, 6 Mar 2024 09:24:01 -0300 Subject: [PATCH] [IMP] l10n_ar: add available document types 80 and 83 This pull request replaces https://github.com/odoo/odoo/pull/156598 Description of the issue/feature this PR addresses: It is necessary to be able to select document types "80 INFORME DIARIO DE CIERRE (ZETA) - CONTROLADORES FISCALES" and "83 TIQUE" in an invoice if the journal of the invoice has "Online Invoice" set on field "AFIP POS System". Current behavior before PR: User is not able to select document types "80 INFORME DIARIO DE CIERRE (ZETA) - CONTROLADORES FISCALES" and "83 TIQUE" in an invoice if the journal of the invoice has "Online Invoice" set on the field "AFIP POS System". Desired behavior after PR is merged: User is able to select document types "80 INFORME DIARIO DE CIERRE (ZETA) - CONTROLADORES FISCALES" and "83 TIQUE" in an invoice if the journal of the invoice has "Online Invoice" set on the field "AFIP POS System". Task Adhoc side: 34790 Task latam: 1167 closes odoo/odoo#156830 X-original-commit: 9fcfaf65bd657e3fc07ff04c8b6b0371e801f2c8 Signed-off-by: Josse Colpaert --- addons/l10n_ar/data/l10n_latam.document.type.csv | 2 +- addons/l10n_ar/models/account_journal.py | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/addons/l10n_ar/data/l10n_latam.document.type.csv b/addons/l10n_ar/data/l10n_latam.document.type.csv index 577a006bb60..27540357c84 100644 --- a/addons/l10n_ar/data/l10n_latam.document.type.csv +++ b/addons/l10n_ar/data/l10n_latam.document.type.csv @@ -53,7 +53,7 @@ dc_cfcp,510,71,TAX CREDIT FOR EMPLOYER CONTRIBUTIONS,,,,,base.ar, dc_f1116,520,73,FORM 1116 RT,,,,,base.ar, dc_cptag,530,74,WAYBILL FOR MOTOR TRANSPORT FOR GRAINS,,,,,base.ar, dc_cptfg,540,75,WAYBILL FOR RAIL TRANSPORT FOR GRAINS,,,,,base.ar, -dc_zeta,550,80,DAILY CLOSING REPORT (ZETA) - FISCAL CONTROLLERS,,,,,base.ar, +dc_zeta,550,80,DAILY CLOSING REPORT (ZETA) - FISCAL CONTROLLERS,,ZETA,invoice,CI-Z,base.ar,zero dc_a_t,560,81,TICKET INVOICE A,A,INVOICE TICKET,invoice,TF-A,base.ar,not_zero dc_b_t,570,82,TICKET - INVOICE B,B,INVOICE TICKET,invoice,TF-B,base.ar,zero dc_t,580,83,TICKET,,TICKET,invoice,TI-X,base.ar,zero diff --git a/addons/l10n_ar/models/account_journal.py b/addons/l10n_ar/models/account_journal.py index 1388e7fbdc1..0d98dceca10 100644 --- a/addons/l10n_ar/models/account_journal.py +++ b/addons/l10n_ar/models/account_journal.py @@ -103,6 +103,7 @@ class AccountJournal(models.Model): receipt_m_code = ['54'] receipt_codes = ['4', '9', '15'] expo_codes = ['19', '20', '21'] + zeta_codes = ['80', '83'] codes_issuer_is_supplier = [ '23', '24', '25', '26', '27', '28', '33', '43', '45', '46', '48', '58', '60', '61', '150', '151', '157', '158', '161', '162', '164', '166', '167', '171', '172', '180', '182', '186', '188', '332'] @@ -117,9 +118,11 @@ class AccountJournal(models.Model): elif afip_pos_system == 'II_IM': # pre-printed invoice codes = usual_codes + receipt_codes + expo_codes + invoice_m_code + receipt_m_code - elif afip_pos_system in ['RAW_MAW', 'RLI_RLM']: + elif afip_pos_system == 'RAW_MAW': # electronic/online invoice codes = usual_codes + receipt_codes + invoice_m_code + receipt_m_code + mipyme_codes + elif afip_pos_system == 'RLI_RLM': + codes = usual_codes + receipt_codes + invoice_m_code + receipt_m_code + mipyme_codes + zeta_codes elif afip_pos_system in ['CPERCEL', 'CPEWS']: # invoice with detail codes = usual_codes + invoice_m_code