OdooWiki OCA HUB

Retenciones anticipadas – Colombia

l10n_co_withholding_advance folder_open OCA/l10n-colombia open_in_new
Accounting/Localizations License: AGPL-3

Este módulo implementa el manejo automático de autorretenciones anticipadas en facturas de venta para la localización contable de Colombia.

La autorretención es un mecanismo tributario mediante el cual ciertas empresas están obligadas a retener y pagar directamente al Estado un porcentaje de sus ingresos, actuando como agentes retenedores sobre sí mismas.

Este módulo permite:

  • Configuración flexible: Define las cuentas contables de débito y crédito para las autorretenciones
  • Tasa personalizable: Configura el porcentaje de autorretención según las disposiciones legales vigentes
  • Cálculo automático: Calcula automáticamente el valor de la autorretención basado en la base imponible de la factura
  • Integración contable: Genera automáticamente las líneas contables correspondientes en facturas de venta y notas crédito
  • Soporte para notas crédito: Invierte correctamente los asientos contables en las notas crédito

auto_awesome What this module does

AI-generated from the code · Odoo 19.0

Automatically adds self-withholding (autorretención) accounting lines to customer invoices and credit notes in the Colombian localization, based on a rate and accounts you configure in Accounting settings.

This module adds an "Autorenta" block to the Accounting settings screen. There you can switch on self-withholding for customer invoices, set a percentage rate, and choose the debit and credit accounts to use. The debit and credit accounts become mandatory once the option is enabled.

When the option is on, the module automatically creates or updates a tax-type journal line on customer invoices (out_invoice) and customer credit notes (out_refund). The amount is calculated as the invoice's tax base amount multiplied by the configured rate, divided by 100. For credit notes the debit and credit sides are swapped so the entry is reversed correctly.

  • If the invoice has no product lines, any existing self-withholding line is removed.
  • If a line already exists on the configured account, it is updated instead of duplicated.
  • The line is named using the invoice number and the account name.

Only customer invoices and credit notes are affected; vendor bills are not touched. The calculation runs as part of the invoice synchronization process, so the line is refreshed when the invoice is updated. No new menus or reports are added; everything is driven from the existing Accounting settings and the invoice form.

Depends on

baseaccount
Models and fields (2)
  • account.move · extends an existing model
  • res.config.settings · extends an existing modell10n_co_withholding_advance_rate (Tasa de autorretención (%)), l10n_co_withholding_advance_enabled (Autorretención en Facturas de Clientes), l10n_co_withholding_advance_debit_id (Cuenta de autorretención débito), l10n_co_withholding_advance_credit_id (Cuenta de autorretención crédito)

Text generated by AI (DeepSeek) from reading the Odoo 19.0 code on GitHub; it may contain mistakes, so check the code before deciding. View the code on GitHub

Availability by version

Reviewed: 2026-11-03
Confirmed (verified in repository and branch) Estimated (unverified) No information

Confirmation status: 2 confirmed, 7 with no information of 9 versions.

Sources · Odoo 19.0

Confirmed on 2026-11-03 in branch 19.0 of OCA/l10n-colombia.

terminal Installation and usage

OCA documentation · Odoo 19.0

Configuración

  • Instale el módulo desde el menú de Aplicaciones
  • Vaya a Contabilidad > Configuración > Ajustes
  • En la sección Autorenta, active la opción Autorretención en Facturas de Clientes
  • Configure los siguientes parámetros:
  • Tasa de autorretención (%): Ingrese el porcentaje aplicable según la normativa colombiana (por ejemplo, 1.20% para autorretención de renta)
  • Cuenta de autorretención débito: Seleccione la cuenta contable que se usará para el débito (típicamente una cuenta de activo o gasto)
  • Cuenta de autorretención crédito: Seleccione la cuenta contable que se usará para el crédito (típicamente una cuenta de pasivo o de retenciones por pagar)

Operación Automática

Una vez configurado, el módulo opera automáticamente:

  • En Facturas de Venta: Al crear o modificar una factura de cliente, el sistema calcula automáticamente la autorretención
  • Cálculo: El monto se calcula como: Base Imponible × Tasa de Autorretención / 100
  • Asientos Contables: Se crean automáticamente las líneas contables correspondientes
  • Notas Crédito: En notas crédito de cliente, los asientos se invierten automáticamente

Ejemplo Práctico

Si tiene una factura de venta con:

  • Base imponible: $10,000,000 COP
  • Tasa de autorretención configurada: 1.20%

El sistema creará automáticamente:

  • Línea de débito: $120,000 COP en la cuenta de autorretención débito
  • Línea de crédito: $120,000 COP en la cuenta de autorretención crédito

Verificación

Para verificar que la autorretención se está aplicando correctamente:

  • Cree o abra una factura de cliente
  • Verifique que exista una línea de tipo "tax" con la cuenta de autorretención configurada
  • Confirme que el monto corresponda al porcentaje configurado sobre la base imponible

Notas Importantes

  • El módulo solo aplica autorretención en documentos de tipo Factura de Cliente (out_invoice) y Nota Crédito de Cliente (out_refund)
  • La autorretención NO se aplica si no hay líneas de productos en la factura
  • Los cálculos se registran en los logs de Odoo para facilitar la auditoría

No verified information in OCA: Installation, Configuration.

info

Data imported from GitHub: this sheet reflects the latest catalog review, not a live lookup. Always check the module documentation and staging before installing in production.