AEAT modelo 592

l10n_es_aeat_mod592
REPOSITORY
REPOSITORYOCA/l10n-spain
GIT
GIThttps://github.com/OCA/l10n-spain.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/l10n-spain/tree/17.0/l10n_es_aeat_mod592
VERSION
VERSION 1.0.4
CATEGORY
CATEGORYAccounting
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSTecnativa, Odoo Community Association (OCA), Binhex System Solutions
MAINTAINERS
MAINTAINERSTecnativa, Odoo Community Association (OCA), Binhex System Solutions
COMMITTERS
COMMITTERSPedro M. Baeza, Víctor Martínez, OCA-git-bot, oca-ci, Ignacio
WEBSITE
WEBSITEhttps://github.com/OCA/l10n-spain
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 19:19:59
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/account-financial-reporting:
    - account_tax_balance
OCA/l10n-spain:
    - l10n_es_aeat
OCA/reporting-engine:
    - report_csv
    - report_xlsx
OCA/server-ux:
    - date_range
odoo/odoo:
    - l10n_es
    - account
    - base_setup
    - base
    - web
    - onboarding
    - product
    - mail
    - bus
    - web_tour
    - uom
    - analytic
    - portal
    - web_editor
    - http_routing
    - auth_signup
    - digest
    - resource
    - base_iban
    - base_vat
    - stock
    - barcodes_gs1_nomenclature
    - barcodes
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES unidecode
xlrd
xlsxwriter
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION
Módulo que calcula el impuesto al plástico Mod592.

Esto módulo introduce el menú "AEAT 592 Model" en Contabilidad -\>
Informe -\> Declaraciones AEAT -\> AEAT 592 Model.

Es posible visualizar e imprimir por separado:

- Registro de asientos con productos en impuestos al plástico de los
  asquirientes

Es posible exportar los registros a archivo con extensión csv para subir
a la web de la AEAT.

Code Analysis

Views touched (18)
XML IDNameModelTypeStatus
l10n_es_aeat_mod592.mod592_acquirer_record l10n_es_aeat_mod592.mod592_acquirer_record ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_acquirer_record_head l10n_es_aeat_mod592.mod592_acquirer_record_head ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_acquirer_summary l10n_es_aeat_mod592.mod592_acquirer_summary ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_manufacturer_record l10n_es_aeat_mod592.mod592_manufacturer_record ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_manufacturer_record_head l10n_es_aeat_mod592.mod592_manufacturer_record_head ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_manufacturer_summary l10n_es_aeat_mod592.mod592_manufacturer_summary ir.ui.view qweb New
l10n_es_aeat_mod592.report_aeat_mod592_document l10n_es_aeat_mod592.report_aeat_mod592_document ir.ui.view qweb New
l10n_es_aeat_mod_592_acquirer_entries_view_form l10n_es_aeat_mod_592_acquirer_entries.view.form l10n.es.aeat.mod592.report.line.acquirer form New
l10n_es_aeat_mod_592_acquirer_entries_view_tree l10n_es_aeat_mod_592_acquirer_entries.view.tree l10n.es.aeat.mod592.report.line.acquirer tree New
l10n_es_aeat_mod_592_manufacturer_entries_view_form l10n_es_aeat_mod_592_manufacturer_entries.view.form l10n.es.aeat.mod592.report.line.manufacturer form New
l10n_es_aeat_mod_592_manufacturer_entries_view_tree l10n_es_aeat_mod_592_manufacturer_eentries.view.tree l10n.es.aeat.mod592.report.line.manufacturer tree New
product_template_form_view_inherit_l10n_es_aeat_mod592 product.template.view.form.inherit product.template xpath Inherits product.product_template_form_view
product_variant_easy_edit_view_inherit_l10n_es_aeat_mod592 product.product.view.form.easy product.product group Inherits product.product_variant_easy_edit_view
report_l10n_es_mod592_pdf report_l10n_es_mod592_pdf ir.ui.view qweb New
view_company_aeat_form_inherit_l10n_es_aeat_mod592 res.company.report.view.form.inherit res.company xpath Inherits l10n_es_aeat.view_company_aeat_form
view_l10n_es_aeat_mod592_report_form l10n_es.aeat.mod592.report.form l10n.es.aeat.mod592.report header Inherits l10n_es_aeat.view_l10n_es_aeat_report_form
view_l10n_es_aeat_mod592_report_tree l10n_es.aeat.mod592.report.tree l10n.es.aeat.mod592.report tree Inherits l10n_es_aeat.view_l10n_es_aeat_report_tree
view_partner_property_form_inherit_l10n_es_aeat_mod592 res.partner.view.form.inherit res.partner xpath Inherits account.view_partner_property_form
Models touched (12)

New fields (18)
  • acquirer_line_ids One2many → l10n.es.aeat.mod592.report.line.acquirer
    comodel_name='l10n.es.aeat.mod592.report.line.acquirer' copy=False inverse_name='report_id' readonly=True string='Acquirer entries'
  • amount_plastic_tax Float
    default=0.45 store=True string='Amount tax for non recyclable'
  • company_plastic_acquirer Boolean
    related='company_id.company_plastic_acquirer'
  • company_plastic_manufacturer Boolean
    related='company_id.company_plastic_manufacturer'
  • manufacturer_line_ids One2many → l10n.es.aeat.mod592.report.line.manufacturer
    comodel_name='l10n.es.aeat.mod592.report.line.manufacturer' copy=False inverse_name='report_id' readonly=True string='Manufacturer entries'
  • num_lines_acquirer Integer
    compute='_compute_num_lines_acquirer' string='Number of lines acquirer'
  • num_lines_manufacturer Integer
    compute='_compute_num_lines_manufacturer' string='Number of lines manufacturer'
  • number Char
    default='592'
  • show_error_acquirer Boolean
    compute='_compute_show_error_acquirer' string='Acquirer lines with error'
  • show_error_manufacturer Boolean
    compute='_compute_show_error_manufacturer' string='Manufacturer lines with error'
  • total_acquirer_entries Integer
    compute='_compute_total_acquirer_entries' store=False string='Total acquirer entries'
  • total_amount_acquirer Float
    compute='_compute_total_amount_acquirer' digits='Product Price' store=False string='Total amount acquirer'
  • total_amount_manufacturer Float
    compute='_compute_total_amount_manufacturer' digits='Product Price' store=True string='Total amount manufacturer'
  • total_manufacturer_entries Integer
    compute='_compute_total_manufacturer_entries' store=True string='Total manufacturer entries'
  • total_weight_acquirer Float
    compute='_compute_total_weight_acquirer' store=False string='Total weight acquirer'
  • total_weight_acquirer_non_reclyclable Float
    compute='_compute_total_weight_acquirer_non_reclyclable' store=False string='Total weight acquirer non reclyclable'
  • total_weight_manufacturer Float
    compute='_compute_total_weight_manufacturer' store=True string='Total weight manufacturer'
  • total_weight_manufacturer_non_reclyclable Float
    compute='_compute_total_weight_manufacturer_non_reclyclable' store=True string='Total weight manufacturer non reclyclable'
Public methods (12)
  • button_confirm(self)
    Checks if all the fields of the report are correctly filled
  • button_recover(self)
    Clean children records in this state for allowing things like cancelling an invoice that is inside this report.
  • calculate(self)
    Computes the records in report.
  • export_csv_acquirer(self)
  • export_csv_manufacturer(self)
  • export_xlsx_acquirer(self)
  • export_xlsx_manufacturer(self)
  • get_acquirer_moves_domain(self)
    Search intracomunitary incoming moves with plastic tax TODO: Date range search by invoice related date or day 15 of next month whathever is first
  • get_manufacturer_moves_domain(self)
    TODO: Dependency on mrp module could be heavy. we need strong traceability of manufactured quants to covear each case Temporaly retunf a domain that return no records as we dont have this casuistic yet (l10n_es_aeat_mod592_mrp for example).
  • get_report_file_name(self)
  • view_action_mod592_report_line_acquirer(self)
  • view_action_mod592_report_line_manufacturer(self)

New fields (3)
  • concept Selection
    compute='_compute_concept' selection=[('1', _('(1) Intra-community acquisition')), ('2', _('(2) Shipping outside Spanish territory')), ('3', _('(3) Inadequacy or destruction')), ('4', _('(4) Return for destruction or reincorporation into the\n manufacturing process'))] store=True
  • entry_number Char
    default=<expr>
  • fiscal_acquirer Selection
    compute='_compute_fiscal_acquirer' selection=FISCAL_ACQUIRERS store=True string='Fiscal reginme acquirer'
Public methods (0)

No public methods.

New fields (3)
  • concept Selection
    compute='_compute_concept' selection=[('1', _('(1) Initial existence')), ('2', _('(2) Manufacturing')), ('3', _('(3) Return of products for destruction or reincorporation into the manufacturing process')), ('4', _('(4) Delivery or making available of the products accounted for')), ('5', _('(5) Other cancellations of the products accounted for other than their delivery or availability'))] store=True
  • entry_number Char
    default=<expr>
  • fiscal_manufacturer Selection
    compute='_compute_fiscal_manufacturer' selection=FISCAL_MANUFACTURERS store=True string='Fiscal regime manufacturer'
Public methods (0)

No public methods.

New fields (20)
  • date_done Date
    compute='_compute_date_done' store=True string='Date'
  • entries_ok Boolean
    compute='_compute_entries_ok' help='Checked if record is OK' string='Entries OK'
  • entry_note Text
    string='Entries observation'
  • entry_number Char
    string='Entrie number'
  • error_text Char
    compute='_compute_error_text' store=True string='Error text'
  • kgs Float
    compute='_compute_kgs' digits='Stock Weight' store=True string='Weight'
  • no_recycling_kgs Float
    compute='_compute_no_recycling_kgs' digits='Stock Weight' store=True string='Weight non reclycable'
  • partner_id Many2one → res.partner
    comodel_name='res.partner' compute='_compute_partner_id' store=True
  • picking_id Many2one → stock.picking
    comodel_name='stock.picking' related='stock_move_id.picking_id'
  • product_description Char
    compute='_compute_product_description' string='Product description'
  • product_id Many2one → product.product
    comodel_name='product.product' related='stock_move_id.product_id'
  • product_key Selection
    compute='_compute_product_key' selection=PRODUCT_KEYS store=True
  • product_uom_qty Float
    compute='_compute_product_uom_qty' digits='Product Unit of Measure' store=True
  • proof Char
    compute='_compute_proof' store=True string='Supporting document'
  • report_id Many2one → l10n.es.aeat.mod592.report
    comodel_name='l10n.es.aeat.mod592.report' string='Mod592 Report'
  • sequence Integer
    default=1
  • stock_move_id Many2one → stock.move
    comodel_name='stock.move' required=True string='Stock Move'
  • supplier_document_number Char
    compute='_compute_supplier_document_number' store=True string='Supplier document number'
  • supplier_document_type Selection
    compute='_compute_supplier_document_type' selection=DOCUMENT_TYPES store=True string='Supplier document type'
  • supplier_social_reason Char
    compute='_compute_supplier_social_reason' store=True string='Supplier name'
Public methods (0)

No public methods.

New fields (7)
  • is_plastic_tax Boolean
    string='Is plastic tax?' tracking=True
  • plastic_tax_regime_acquirer Selection
    selection=FISCAL_ACQUIRERS string='Plastic tax regime acquirer'
  • plastic_tax_regime_manufacturer Selection
    selection=FISCAL_MANUFACTURERS string='Plastic tax regime manufaturer'
  • plastic_tax_weight Float
    digits='Stock Weight' string='Plastic weight'
  • plastic_type_key Selection
    selection=PRODUCT_KEYS string='Plastic type key'
  • plastic_weight_non_recyclable Float
    digits='Stock Weight' string='Plastic weight non recyclable'
  • tax_plastic_type Selection
    default='both' selection=[('manufacturer', _('Manufacturer')), ('acquirer', _('Acquirer')), ('both', _('Both'))]
Public methods (1)
  • check_plastic_weight_non_recyclable(self)
    @api.constrains('plastic_weight_non_recyclable', 'plastic_tax_weight')

New fields (7)
  • is_plastic_tax Boolean
    compute='_compute_plastic_info' inverse='_inverse_plastic_info' search='_search_is_plastic_tax' string='Is plastic tax?' tracking=True
  • plastic_tax_regime_acquirer Selection
    compute='_compute_plastic_info' inverse='_inverse_plastic_info' search='_search_plastic_tax_regime_acquirer' selection=FISCAL_ACQUIRERS string='Plastic tax regime acquirer'
  • plastic_tax_regime_manufacturer Selection
    compute='_compute_plastic_info' inverse='_inverse_plastic_info' search='_search_plastic_tax_regime_manufacturer' selection=FISCAL_MANUFACTURERS string='Plastic tax regime manufaturer'
  • plastic_tax_weight Float
    compute='_compute_plastic_info' digits='Stock Weight' inverse='_inverse_plastic_info' search='_search_plastic_tax_weight' string='Plastic weight'
  • plastic_type_key Selection
    compute='_compute_plastic_info' inverse='_inverse_plastic_info' search='_search_plastic_type_key' selection=PRODUCT_KEYS string='Plastic type key'
  • plastic_weight_non_recyclable Float
    compute='_compute_plastic_info' digits='Stock Weight' inverse='_inverse_plastic_info' search='_search_plastic_weight_non_recyclable' string='Plastic weight non recyclable'
  • tax_plastic_type Selection
    compute='_compute_plastic_info' default='both' inverse='_inverse_plastic_info' search='_search_tax_plastic_type' selection=[('manufacturer', _('Manufacturer')), ('acquirer', _('Acquirer')), ('both', _('Both'))]
Public methods (1)
  • check_plastic_tax_weight(self)
    @api.constrains('plastic_weight_non_recyclable', 'plastic_tax_weight')

New fields (0)

No new fields.

Public methods (2)
  • csv_report_options(self)
  • generate_csv_report(self, writer, data, objects)

New fields (0)

No new fields.

Public methods (2)
  • csv_report_options(self)
  • generate_csv_report(self, writer, data, objects)

New fields (0)

No new fields.

Public methods (1)
  • generate_xlsx_report(self, workbook, data, objects)

New fields (0)

No new fields.

Public methods (1)
  • generate_xlsx_report(self, workbook, data, objects)

New fields (2)
  • company_plastic_acquirer Boolean
    default=True string='Plastic Acquirer'
  • company_plastic_manufacturer Boolean
    default=False string='Plastic Manufacturer'
Public methods (0)

No public methods.

New fields (1)
  • plastic_document_type Selection
    compute='_compute_plastic_document_type' help='Supplier/Recipient Document Type Code' selection=DOCUMENT_TYPES store=True string='Plastic document type'
Public methods (0)

No public methods.

REPOSITORY
REPOSITORYOCA/l10n-spain
GIT
GIThttps://github.com/OCA/l10n-spain.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/l10n-spain/tree/16.0/l10n_es_aeat_mod592
VERSION
VERSION 1.0.3
CATEGORY
CATEGORYAccounting
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSTecnativa, Odoo Community Association (OCA), Binhex System Solutions
MAINTAINERS
MAINTAINERSTecnativa, Odoo Community Association (OCA), Binhex System Solutions
COMMITTERS
COMMITTERSVíctor Martínez, OCA-git-bot, oca-ci, arantxa-s73
WEBSITE
WEBSITEhttps://github.com/OCA/l10n-spain
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:53:39
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/account-financial-reporting:
    - account_tax_balance
OCA/l10n-spain:
    - l10n_es_aeat
OCA/reporting-engine:
    - report_csv
    - report_xlsx
OCA/server-ux:
    - date_range
odoo/odoo:
    - l10n_es
    - account
    - base_setup
    - base
    - web
    - product
    - mail
    - bus
    - web_tour
    - uom
    - analytic
    - portal
    - web_editor
    - http_routing
    - auth_signup
    - digest
    - resource
    - base_iban
    - base_vat
    - stock
    - barcodes_gs1_nomenclature
    - barcodes
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES unidecode
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION

Code Analysis

Views touched (18)
XML IDNameModelTypeStatus
l10n_es_aeat_mod592.mod592_acquirer_record l10n_es_aeat_mod592.mod592_acquirer_record ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_acquirer_record_head l10n_es_aeat_mod592.mod592_acquirer_record_head ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_acquirer_summary l10n_es_aeat_mod592.mod592_acquirer_summary ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_manufacturer_record l10n_es_aeat_mod592.mod592_manufacturer_record ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_manufacturer_record_head l10n_es_aeat_mod592.mod592_manufacturer_record_head ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_manufacturer_summary l10n_es_aeat_mod592.mod592_manufacturer_summary ir.ui.view qweb New
l10n_es_aeat_mod592.report_aeat_mod592_document l10n_es_aeat_mod592.report_aeat_mod592_document ir.ui.view qweb New
l10n_es_aeat_mod_592_acquirer_entries_view_form l10n_es_aeat_mod_592_acquirer_entries.view.form l10n.es.aeat.mod592.report.line.acquirer form New
l10n_es_aeat_mod_592_acquirer_entries_view_tree l10n_es_aeat_mod_592_acquirer_entries.view.tree l10n.es.aeat.mod592.report.line.acquirer tree New
l10n_es_aeat_mod_592_manufacturer_entries_view_form l10n_es_aeat_mod_592_manufacturer_entries.view.form l10n.es.aeat.mod592.report.line.manufacturer form New
l10n_es_aeat_mod_592_manufacturer_entries_view_tree l10n_es_aeat_mod_592_manufacturer_eentries.view.tree l10n.es.aeat.mod592.report.line.manufacturer tree New
product_template_form_view_inherit_l10n_es_aeat_mod592 product.template.view.form.inherit product.template xpath Inherits product.product_template_form_view
product_variant_easy_edit_view_inherit_l10n_es_aeat_mod592 product.product.view.form.easy product.product group Inherits product.product_variant_easy_edit_view
report_l10n_es_mod592_pdf report_l10n_es_mod592_pdf ir.ui.view qweb New
view_company_aeat_form_inherit_l10n_es_aeat_mod592 res.company.report.view.form.inherit res.company xpath Inherits l10n_es_aeat.view_company_aeat_form
view_l10n_es_aeat_mod592_report_form l10n_es.aeat.mod592.report.form l10n.es.aeat.mod592.report header Inherits l10n_es_aeat.view_l10n_es_aeat_report_form
view_l10n_es_aeat_mod592_report_tree l10n_es.aeat.mod592.report.tree l10n.es.aeat.mod592.report tree Inherits l10n_es_aeat.view_l10n_es_aeat_report_tree
view_partner_property_form_inherit_l10n_es_aeat_mod592 res.partner.view.form.inherit res.partner xpath Inherits account.view_partner_property_form
Models touched (12)

New fields (18)
  • acquirer_line_ids One2many → l10n.es.aeat.mod592.report.line.acquirer
    comodel_name='l10n.es.aeat.mod592.report.line.acquirer' copy=False inverse_name='report_id' readonly=True string='Acquirer entries'
  • amount_plastic_tax Float
    default=0.45 store=True string='Amount tax for non recyclable'
  • company_plastic_acquirer Boolean
    related='company_id.company_plastic_acquirer'
  • company_plastic_manufacturer Boolean
    related='company_id.company_plastic_manufacturer'
  • manufacturer_line_ids One2many → l10n.es.aeat.mod592.report.line.manufacturer
    comodel_name='l10n.es.aeat.mod592.report.line.manufacturer' copy=False inverse_name='report_id' readonly=True string='Manufacturer entries'
  • num_lines_acquirer Integer
    compute='_compute_num_lines_acquirer' string='Number of lines acquirer'
  • num_lines_manufacturer Integer
    compute='_compute_num_lines_manufacturer' string='Number of lines manufacturer'
  • number Char
    default='592'
  • show_error_acquirer Boolean
    compute='_compute_show_error_acquirer' string='Acquirer lines with error'
  • show_error_manufacturer Boolean
    compute='_compute_show_error_manufacturer' string='Manufacturer lines with error'
  • total_acquirer_entries Integer
    compute='_compute_total_acquirer_entries' store=False string='Total acquirer entries'
  • total_amount_acquirer Float
    compute='_compute_total_amount_acquirer' digits='Product Price' store=False string='Total amount acquirer'
  • total_amount_manufacturer Float
    compute='_compute_total_amount_manufacturer' digits='Product Price' store=True string='Total amount manufacturer'
  • total_manufacturer_entries Integer
    compute='_compute_total_manufacturer_entries' store=True string='Total manufacturer entries'
  • total_weight_acquirer Float
    compute='_compute_total_weight_acquirer' store=False string='Total weight acquirer'
  • total_weight_acquirer_non_reclyclable Float
    compute='_compute_total_weight_acquirer_non_reclyclable' store=False string='Total weight acquirer non reclyclable'
  • total_weight_manufacturer Float
    compute='_compute_total_weight_manufacturer' store=True string='Total weight manufacturer'
  • total_weight_manufacturer_non_reclyclable Float
    compute='_compute_total_weight_manufacturer_non_reclyclable' store=True string='Total weight manufacturer non reclyclable'
Public methods (12)
  • button_confirm(self)
    Checks if all the fields of the report are correctly filled
  • button_recover(self)
    Clean children records in this state for allowing things like cancelling an invoice that is inside this report.
  • calculate(self)
    Computes the records in report.
  • export_csv_acquirer(self)
  • export_csv_manufacturer(self)
  • export_xlsx_acquirer(self)
  • export_xlsx_manufacturer(self)
  • get_acquirer_moves_domain(self)
    Search intracomunitary incoming moves with plastic tax TODO: Date range search by invoice related date or day 15 of next month whathever is first
  • get_manufacturer_moves_domain(self)
    TODO: Dependency on mrp module could be heavy. we need strong traceability of manufactured quants to covear each case Temporaly retunf a domain that return no records as we dont have this casuistic yet (l10n_es_aeat_mod592_mrp for example).
  • get_report_file_name(self)
  • view_action_mod592_report_line_acquirer(self)
  • view_action_mod592_report_line_manufacturer(self)

New fields (3)
  • concept Selection
    compute='_compute_concept' selection=[('1', _('(1) Intra-community acquisition')), ('2', _('(2) Shipping outside Spanish territory')), ('3', _('(3) Inadequacy or destruction')), ('4', _('(4) Return for destruction or reincorporation into the\n manufacturing process'))] store=True
  • entry_number Char
    default=<expr>
  • fiscal_acquirer Selection
    compute='_compute_fiscal_acquirer' selection=FISCAL_ACQUIRERS store=True string='Fiscal reginme acquirer'
Public methods (0)

No public methods.

New fields (3)
  • concept Selection
    compute='_compute_concept' selection=[('1', _('(1) Initial existence')), ('2', _('(2) Manufacturing')), ('3', _('(3) Return of products for destruction or reincorporation into the\n manufacturing process')), ('4', _('(4) Delivery or making available of the products accounted for')), ('5', _('(5) Other cancellations of the products accounted for other than\n their delivery or availability'))] store=True
  • entry_number Char
    default=<expr>
  • fiscal_manufacturer Selection
    compute='_compute_fiscal_manufacturer' selection=FISCAL_MANUFACTURERS store=True string='Fiscal regime manufacturer'
Public methods (0)

No public methods.

New fields (20)
  • date_done Date
    compute='_compute_date_done' store=True string='Date'
  • entries_ok Boolean
    compute='_compute_entries_ok' help='Checked if record is OK' string='Entries OK'
  • entry_note Text
    string='Entries observation'
  • entry_number Char
    string='Entrie number'
  • error_text Char
    compute='_compute_error_text' store=True string='Error text'
  • kgs Float
    compute='_compute_kgs' digits='Stock Weight' store=True string='Weight'
  • no_recycling_kgs Float
    compute='_compute_no_recycling_kgs' digits='Stock Weight' store=True string='Weight non reclycable'
  • partner_id Many2one → res.partner
    comodel_name='res.partner' compute='_compute_partner_id' store=True
  • picking_id Many2one → stock.picking
    comodel_name='stock.picking' related='stock_move_id.picking_id'
  • product_description Char
    compute='_compute_product_description' string='Product description'
  • product_id Many2one → product.product
    comodel_name='product.product' related='stock_move_id.product_id'
  • product_key Selection
    compute='_compute_product_key' selection=PRODUCT_KEYS store=True
  • product_uom_qty Float
    compute='_compute_product_uom_qty' digits='Product Unit of Measure' store=True
  • proof Char
    compute='_compute_proof' store=True string='Supporting document'
  • report_id Many2one → l10n.es.aeat.mod592.report
    comodel_name='l10n.es.aeat.mod592.report' string='Mod592 Report'
  • sequence Integer
    default=1
  • stock_move_id Many2one → stock.move
    comodel_name='stock.move' required=True string='Stock Move'
  • supplier_document_number Char
    compute='_compute_supplier_document_number' store=True string='Supplier document number'
  • supplier_document_type Selection
    compute='_compute_supplier_document_type' selection=DOCUMENT_TYPES store=True string='Supplier document type'
  • supplier_social_reason Char
    compute='_compute_supplier_social_reason' store=True string='Supplier name'
Public methods (0)

No public methods.

New fields (7)
  • is_plastic_tax Boolean
    string='Is plastic tax?' tracking=True
  • plastic_tax_regime_acquirer Selection
    selection=FISCAL_ACQUIRERS string='Plastic tax regime acquirer'
  • plastic_tax_regime_manufacturer Selection
    selection=FISCAL_MANUFACTURERS string='Plastic tax regime manufaturer'
  • plastic_tax_weight Float
    digits='Stock Weight' string='Plastic weight'
  • plastic_type_key Selection
    selection=PRODUCT_KEYS string='Plastic type key'
  • plastic_weight_non_recyclable Float
    digits='Stock Weight' string='Plastic weight non recyclable'
  • tax_plastic_type Selection
    default='both' selection=[('manufacturer', _('Manufacturer')), ('acquirer', _('Acquirer')), ('both', _('Both'))]
Public methods (1)
  • check_plastic_weight_non_recyclable(self)
    @api.constrains('plastic_weight_non_recyclable', 'plastic_tax_weight')

New fields (7)
  • is_plastic_tax Boolean
    compute='_compute_plastic_info' inverse='_inverse_plastic_info' search='_search_is_plastic_tax' string='Is plastic tax?' tracking=True
  • plastic_tax_regime_acquirer Selection
    compute='_compute_plastic_info' inverse='_inverse_plastic_info' search='_search_plastic_tax_regime_acquirer' selection=FISCAL_ACQUIRERS string='Plastic tax regime acquirer'
  • plastic_tax_regime_manufacturer Selection
    compute='_compute_plastic_info' inverse='_inverse_plastic_info' search='_search_plastic_tax_regime_manufacturer' selection=FISCAL_MANUFACTURERS string='Plastic tax regime manufaturer'
  • plastic_tax_weight Float
    compute='_compute_plastic_info' digits='Stock Weight' inverse='_inverse_plastic_info' search='_search_plastic_tax_weight' string='Plastic weight'
  • plastic_type_key Selection
    compute='_compute_plastic_info' inverse='_inverse_plastic_info' search='_search_plastic_type_key' selection=PRODUCT_KEYS string='Plastic type key'
  • plastic_weight_non_recyclable Float
    compute='_compute_plastic_info' digits='Stock Weight' inverse='_inverse_plastic_info' search='_search_plastic_weight_non_recyclable' string='Plastic weight non recyclable'
  • tax_plastic_type Selection
    compute='_compute_plastic_info' default='both' inverse='_inverse_plastic_info' search='_search_tax_plastic_type' selection=[('manufacturer', _('Manufacturer')), ('acquirer', _('Acquirer')), ('both', _('Both'))]
Public methods (1)
  • check_plastic_tax_weight(self)
    @api.constrains('plastic_weight_non_recyclable', 'plastic_tax_weight')

New fields (0)

No new fields.

Public methods (2)
  • csv_report_options(self)
  • generate_csv_report(self, writer, data, objects)

New fields (0)

No new fields.

Public methods (2)
  • csv_report_options(self)
  • generate_csv_report(self, writer, data, objects)

New fields (0)

No new fields.

Public methods (1)
  • generate_xlsx_report(self, workbook, data, objects)

New fields (0)

No new fields.

Public methods (1)
  • generate_xlsx_report(self, workbook, data, objects)

New fields (2)
  • company_plastic_acquirer Boolean
    default=True string='Plastic Acquirer'
  • company_plastic_manufacturer Boolean
    default=False string='Plastic Manufacturer'
Public methods (0)

No public methods.

New fields (1)
  • plastic_document_type Selection
    compute='_compute_plastic_document_type' help='Supplier/Recipient Document Type Code' selection=DOCUMENT_TYPES store=True string='Plastic document type'
Public methods (0)

No public methods.

REPOSITORY
REPOSITORYOCA/l10n-spain
GIT
GIThttps://github.com/OCA/l10n-spain.git
GIT FOLDER
GIT FOLDERhttps://github.com/OCA/l10n-spain/tree/15.0/l10n_es_aeat_mod592
VERSION
VERSION 2.0.3
CATEGORY
CATEGORYAccounting
LICENSE
LICENSEAGPL-3
APPLICATION
APPLICATIONNo
AUTO-INSTALLABLE
AUTO-INSTALLABLENo
AUTHORS
AUTHORSTecnativa, Odoo Community Association (OCA), Binhex System Solutions
MAINTAINERS
MAINTAINERSTecnativa, Odoo Community Association (OCA), Binhex System Solutions
COMMITTERS
COMMITTERSPedro M. Baeza, Víctor Martínez, Weblate, OCA-git-bot, oca-ci
WEBSITE
WEBSITEhttps://github.com/OCA/l10n-spain
LAST TRACKING UPDATE
LAST TRACKING UPDATE2026-07-06 00:46:29
ODOO DEPENDENCIES
ODOO DEPENDENCIES OCA/account-financial-reporting:
    - account_tax_balance
OCA/l10n-spain:
    - l10n_es_aeat
OCA/reporting-engine:
    - report_csv
    - report_xlsx
OCA/server-ux:
    - date_range
odoo/odoo:
    - l10n_es
    - account
    - base_setup
    - base
    - web
    - product
    - mail
    - bus
    - web_tour
    - uom
    - analytic
    - portal
    - web_editor
    - http_routing
    - auth_signup
    - digest
    - resource
    - base_iban
    - base_vat
    - stock
    - barcodes
PYTHON DEPENDENCIES
PYTHON DEPENDENCIES cryptography
unidecode
xlrd
xlsxwriter
SYSTEM DEPENDENCIES
SYSTEM DEPENDENCIES Not have
DESCRIPTION
DESCRIPTION

Code Analysis

Views touched (18)
XML IDNameModelTypeStatus
l10n_es_aeat_mod592.mod592_acquirer_record l10n_es_aeat_mod592.mod592_acquirer_record ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_acquirer_record_head l10n_es_aeat_mod592.mod592_acquirer_record_head ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_acquirer_summary l10n_es_aeat_mod592.mod592_acquirer_summary ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_manufacturer_record l10n_es_aeat_mod592.mod592_manufacturer_record ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_manufacturer_record_head l10n_es_aeat_mod592.mod592_manufacturer_record_head ir.ui.view qweb New
l10n_es_aeat_mod592.mod592_manufacturer_summary l10n_es_aeat_mod592.mod592_manufacturer_summary ir.ui.view qweb New
l10n_es_aeat_mod592.report_aeat_mod592_document l10n_es_aeat_mod592.report_aeat_mod592_document ir.ui.view qweb New
l10n_es_aeat_mod_592_acquirer_entries_view_form l10n_es_aeat_mod_592_acquirer_entries.view.form l10n.es.aeat.mod592.report.line.acquirer form New
l10n_es_aeat_mod_592_acquirer_entries_view_tree l10n_es_aeat_mod_592_acquirer_entries.view.tree l10n.es.aeat.mod592.report.line.acquirer tree New
l10n_es_aeat_mod_592_manufacturer_entries_view_form l10n_es_aeat_mod_592_manufacturer_entries.view.form l10n.es.aeat.mod592.report.line.manufacturer form New
l10n_es_aeat_mod_592_manufacturer_entries_view_tree l10n_es_aeat_mod_592_manufacturer_eentries.view.tree l10n.es.aeat.mod592.report.line.manufacturer tree New
product_template_form_view_inherit_l10n_es_aeat_mod592 product.template.view.form.inherit product.template xpath Inherits product.product_template_form_view
product_variant_easy_edit_view_inherit_l10n_es_aeat_mod592 product.product.view.form.easy product.product group Inherits product.product_variant_easy_edit_view
report_l10n_es_mod592_pdf report_l10n_es_mod592_pdf ir.ui.view qweb New
view_company_aeat_form_inherit_l10n_es_aeat_mod592 res.company.report.view.form.inherit res.company xpath Inherits l10n_es_aeat.view_company_aeat_form
view_l10n_es_aeat_mod592_report_form l10n_es.aeat.mod592.report.form l10n.es.aeat.mod592.report header Inherits l10n_es_aeat.view_l10n_es_aeat_report_form
view_l10n_es_aeat_mod592_report_tree l10n_es.aeat.mod592.report.tree l10n.es.aeat.mod592.report tree Inherits l10n_es_aeat.view_l10n_es_aeat_report_tree
view_partner_property_form_inherit_l10n_es_aeat_mod592 res.partner.view.form.inherit res.partner xpath Inherits account.view_partner_property_form
Models touched (12)

New fields (18)
  • acquirer_line_ids One2many → l10n.es.aeat.mod592.report.line.acquirer
    comodel_name='l10n.es.aeat.mod592.report.line.acquirer' copy=False inverse_name='report_id' readonly=True string='Acquirer entries'
  • amount_plastic_tax Float
    default=0.45 store=True string='Amount tax for non recyclable'
  • company_plastic_acquirer Boolean
    related='company_id.company_plastic_acquirer'
  • company_plastic_manufacturer Boolean
    related='company_id.company_plastic_manufacturer'
  • manufacturer_line_ids One2many → l10n.es.aeat.mod592.report.line.manufacturer
    comodel_name='l10n.es.aeat.mod592.report.line.manufacturer' copy=False inverse_name='report_id' readonly=True string='Manufacturer entries'
  • num_lines_acquirer Integer
    compute='_compute_num_lines_acquirer' string='Number of lines acquirer'
  • num_lines_manufacturer Integer
    compute='_compute_num_lines_manufacturer' string='Number of lines manufacturer'
  • number Char
    default='592'
  • show_error_acquirer Boolean
    compute='_compute_show_error_acquirer' string='Acquirer lines with error'
  • show_error_manufacturer Boolean
    compute='_compute_show_error_manufacturer' string='Manufacturer lines with error'
  • total_acquirer_entries Integer
    compute='_compute_total_acquirer_entries' store=False string='Total acquirer entries'
  • total_amount_acquirer Float
    compute='_compute_total_amount_acquirer' digits='Product Price' store=False string='Total amount acquirer'
  • total_amount_manufacturer Float
    compute='_compute_total_amount_manufacturer' digits='Product Price' store=True string='Total amount manufacturer'
  • total_manufacturer_entries Integer
    compute='_compute_total_manufacturer_entries' store=True string='Total manufacturer entries'
  • total_weight_acquirer Float
    compute='_compute_total_weight_acquirer' store=False string='Total weight acquirer'
  • total_weight_acquirer_non_reclyclable Float
    compute='_compute_total_weight_acquirer_non_reclyclable' store=False string='Total weight acquirer non reclyclable'
  • total_weight_manufacturer Float
    compute='_compute_total_weight_manufacturer' store=True string='Total weight manufacturer'
  • total_weight_manufacturer_non_reclyclable Float
    compute='_compute_total_weight_manufacturer_non_reclyclable' store=True string='Total weight manufacturer non reclyclable'
Public methods (12)
  • button_confirm(self)
    Checks if all the fields of the report are correctly filled
  • button_recover(self)
    Clean children records in this state for allowing things like cancelling an invoice that is inside this report.
  • calculate(self)
    Computes the records in report.
  • export_csv_acquirer(self)
  • export_csv_manufacturer(self)
  • export_xlsx_acquirer(self)
  • export_xlsx_manufacturer(self)
  • get_acquirer_moves_domain(self)
    Search intracomunitary incoming moves with plastic tax TODO: Date range search by invoice related date or day 15 of next month whathever is first
  • get_manufacturer_moves_domain(self)
    TODO: Dependency on mrp module could be heavy. we need strong traceability of manufactured quants to covear each case Temporaly retunf a domain that return no records as we dont have this casuistic yet (l10n_es_aeat_mod592_mrp for example).
  • get_report_file_name(self)
  • view_action_mod592_report_line_acquirer(self)
  • view_action_mod592_report_line_manufacturer(self)

New fields (3)
  • concept Selection
    compute='_compute_concept' selection=[('1', _('(1) Intra-community acquisition')), ('2', _('(2) Shipping outside Spanish territory')), ('3', _('(3) Inadequacy or destruction')), ('4', _('(4) Return for destruction or reincorporation into the\n manufacturing process'))] store=True
  • entry_number Char
    default=<expr>
  • fiscal_acquirer Selection
    compute='_compute_fiscal_acquirer' selection=FISCAL_ACQUIRERS store=True string='Fiscal reginme acquirer'
Public methods (0)

No public methods.

New fields (3)
  • concept Selection
    compute='_compute_concept' selection=[('1', _('(1) Initial existence')), ('2', _('(2) Manufacturing')), ('3', _('(3) Return of products for destruction or reincorporation into the\n manufacturing process')), ('4', _('(4) Delivery or making available of the products accounted for')), ('5', _('(5) Other cancellations of the products accounted for other than\n their delivery or availability'))] store=True
  • entry_number Char
    default=<expr>
  • fiscal_manufacturer Selection
    compute='_compute_fiscal_manufacturer' selection=FISCAL_MANUFACTURERS store=True string='Fiscal regime manufacturer'
Public methods (0)

No public methods.

New fields (20)
  • date_done Date
    compute='_compute_date_done' store=True string='Date'
  • entries_ok Boolean
    compute='_compute_entries_ok' help='Checked if record is OK' string='Entries OK'
  • entry_note Text
    string='Entries observation'
  • entry_number Char
    string='Entrie number'
  • error_text Char
    compute='_compute_error_text' store=True string='Error text'
  • kgs Float
    compute='_compute_kgs' digits='Stock Weight' store=True string='Weight'
  • no_recycling_kgs Float
    compute='_compute_no_recycling_kgs' digits='Stock Weight' store=True string='Weight non reclycable'
  • partner_id Many2one → res.partner
    comodel_name='res.partner' compute='_compute_partner_id' store=True
  • picking_id Many2one → stock.picking
    comodel_name='stock.picking' related='stock_move_id.picking_id'
  • product_description Char
    compute='_compute_product_description' string='Product description'
  • product_id Many2one → product.product
    comodel_name='product.product' related='stock_move_id.product_id'
  • product_key Selection
    compute='_compute_product_key' selection=PRODUCT_KEYS store=True
  • product_uom_qty Float
    compute='_compute_product_uom_qty' digits='Product Unit of Measure' store=True
  • proof Char
    compute='_compute_proof' store=True string='Supporting document'
  • report_id Many2one → l10n.es.aeat.mod592.report
    comodel_name='l10n.es.aeat.mod592.report' string='Mod592 Report'
  • sequence Integer
    default=1
  • stock_move_id Many2one → stock.move
    comodel_name='stock.move' required=True string='Stock Move'
  • supplier_document_number Char
    compute='_compute_supplier_document_number' store=True string='Supplier document number'
  • supplier_document_type Selection
    compute='_compute_supplier_document_type' selection=DOCUMENT_TYPES store=True string='Supplier document type'
  • supplier_social_reason Char
    compute='_compute_supplier_social_reason' store=True string='Supplier name'
Public methods (0)

No public methods.

New fields (7)
  • is_plastic_tax Boolean
    string='Is plastic tax?' tracking=True
  • plastic_tax_regime_acquirer Selection
    selection=FISCAL_ACQUIRERS string='Plastic tax regime acquirer'
  • plastic_tax_regime_manufacturer Selection
    selection=FISCAL_MANUFACTURERS string='Plastic tax regime manufaturer'
  • plastic_tax_weight Float
    digits='Stock Weight' string='Plastic weight'
  • plastic_type_key Selection
    selection=PRODUCT_KEYS string='Plastic type key'
  • plastic_weight_non_recyclable Float
    digits='Stock Weight' string='Plastic weight non recyclable'
  • tax_plastic_type Selection
    default='both' selection=[('manufacturer', _('Manufacturer')), ('acquirer', _('Acquirer')), ('both', _('Both'))]
Public methods (1)
  • check_plastic_weight_non_recyclable(self)
    @api.constrains('plastic_weight_non_recyclable', 'plastic_tax_weight')

New fields (7)
  • is_plastic_tax Boolean
    compute='_compute_plastic_info' inverse='_inverse_plastic_info' search='_search_is_plastic_tax' string='Is plastic tax?' tracking=True
  • plastic_tax_regime_acquirer Selection
    compute='_compute_plastic_info' inverse='_inverse_plastic_info' search='_search_plastic_tax_regime_acquirer' selection=FISCAL_ACQUIRERS string='Plastic tax regime acquirer'
  • plastic_tax_regime_manufacturer Selection
    compute='_compute_plastic_info' inverse='_inverse_plastic_info' search='_search_plastic_tax_regime_manufacturer' selection=FISCAL_MANUFACTURERS string='Plastic tax regime manufaturer'
  • plastic_tax_weight Float
    compute='_compute_plastic_info' digits='Stock Weight' inverse='_inverse_plastic_info' search='_search_plastic_tax_weight' string='Plastic weight'
  • plastic_type_key Selection
    compute='_compute_plastic_info' inverse='_inverse_plastic_info' search='_search_plastic_type_key' selection=PRODUCT_KEYS string='Plastic type key'
  • plastic_weight_non_recyclable Float
    compute='_compute_plastic_info' digits='Stock Weight' inverse='_inverse_plastic_info' search='_search_plastic_weight_non_recyclable' string='Plastic weight non recyclable'
  • tax_plastic_type Selection
    compute='_compute_plastic_info' default='both' inverse='_inverse_plastic_info' search='_search_tax_plastic_type' selection=[('manufacturer', _('Manufacturer')), ('acquirer', _('Acquirer')), ('both', _('Both'))]
Public methods (1)
  • check_plastic_tax_weight(self)
    @api.constrains('plastic_weight_non_recyclable', 'plastic_tax_weight')

New fields (0)

No new fields.

Public methods (2)
  • csv_report_options(self)
  • generate_csv_report(self, writer, data, objects)

New fields (0)

No new fields.

Public methods (2)
  • csv_report_options(self)
  • generate_csv_report(self, writer, data, objects)

New fields (0)

No new fields.

Public methods (1)
  • generate_xlsx_report(self, workbook, data, objects)

New fields (0)

No new fields.

Public methods (1)
  • generate_xlsx_report(self, workbook, data, objects)

New fields (2)
  • company_plastic_acquirer Boolean
    default=True string='Plastic Acquirer'
  • company_plastic_manufacturer Boolean
    default=False string='Plastic Manufacturer'
Public methods (0)

No public methods.

New fields (1)
  • plastic_document_type Selection
    compute='_compute_plastic_document_type' help='Supplier/Recipient Document Type Code' selection=DOCUMENT_TYPES store=True string='Plastic document type'
Public methods (0)

No public methods.

STATUS
STATUSOpen migration PR - not merged yet for this version
REPOSITORY
REPOSITORYOCA/l10n-spain
PULL REQUEST
PULL REQUEST[18.0][MIG] l10n_es_aeat_mod592: Migration to 18.0 (#4928)