GitHunt
NI

niczapata/credport_quanamco

Odoo module extending accounting functionality for Colombian companies with multi-currency support, exchange rate management, custom reports, and security groups for analytic accounts and products.

Credport by Grupo Quanam Colombia SAS

Odoo module for Colombian accounting extensions and customizations.

Overview

This module extends the standard Odoo account.move and account.move.line models to add Colombian-specific accounting features, including multi-currency handling, exchange rate management, and custom report templates.

Author

Grupo Quanam Colombia SAS

Version

1.0

Dependencies

  • account - Odoo base accounting module

Features

Account Move Extensions

  • Multi-Currency Support: Detects when transactions use currencies different from the company's default currency
  • Exchange Rate Management:
    • Custom exchange date field
    • User-defined exchange rates
    • Automatic exchange rate computation
  • Payment States: Extended payment state selection including "Cancelado(a)"
  • Amount Text Conversion: Converts monetary amounts to text (Spanish localization)
  • Debit/Credit Totals: Computes and displays total debits and credits on journal entries

Account Move Line Extensions

  • Exchange Difference Handling: Automatically updates references on exchange difference journal entries
  • Analytic Account Inheritance: Inherits analytic accounts from linked stock moves
  • Analytic Tags Inheritance: Inherits analytic tags from linked stock moves

Security Groups

The module provides the following security groups:

  1. Crear y/o modificar cuentas analíticas - Create and modify analytic accounts
  2. Crear y/o modificar etiquetas analíticas - Create and modify analytic tags
  3. Crear y/o modificar productos o servicios - Create and modify products/services
  4. Seleccionar Multiples Compañias - Select multiple companies
  5. Tipo de cambio en los asientos contables - Exchange rate in accounting entries

Custom Views

  • Modified invoice tree view showing original total amount
  • Modified invoice form with exchange rate fields

Reports

The module includes custom report templates:

  • custom_report.xml - Custom report layout
  • external_layout.xml - External document layout
  • paperformat.xml - Paper format configuration
  • reports.xml - Report definitions
  • journal_entries.xml - Journal entries report
  • contingency_bill.xml - Contingency bill report
  • requisitions.xml - Requisitions report

Installation

  1. Copy the module to your Odoo addons directory
  2. Restart Odoo server
  3. Update the apps list
  4. Install "Credport by Grupo Quanam Colombia SAS"

Usage

Exchange Rate Configuration

When creating or editing invoices in foreign currencies:

  1. The module automatically detects if the invoice uses a different currency than the company's default
  2. Set the exchange_date to specify the date for the exchange rate
  3. Toggle user_exchange_rate to manually input a custom exchange rate
  4. The exchange_rate field becomes available for manual input when user_exchange_rate is enabled

Invoice Status Updates

The module includes a method update_invoice_status for updating Colombian electronic invoice status (DIAN).

File Structure

credport_quanamco/
├── __init__.py                 # Module initialization
├── __manifest__.py             # Module manifest
├── models/
│   ├── __init__.py
│   ├── credport_account_move.py      # AccountMove model extensions
│   └── credport_account_move_line.py # AccountMoveLine model extensions
├── views/
│   └── credport_account_move_views.xml  # Custom view definitions
├── security/
│   ├── ir.model.access.csv     # Access control list
│   └── security.xml            # Security group definitions
└── reports/
    ├── custom_report.xml
    ├── external_layout.xml
    ├── paperformat.xml
    ├── reports.xml
    ├── journal_entries.xml
    ├── contingency_bill.xml
    └── requisitions.xml

Technical Details

Model Extensions

  • account.move - Extended with exchange rate fields, amount text conversion, and debit/credit totals
  • account.move.line - Extended with exchange difference handling and analytic account inheritance

Key Methods

  • _compute_other_currency() - Computes if the move uses a different currency
  • _post() - Custom posting logic to preserve partner information
  • update_invoice_status() - Updates Colombian electronic invoice status
  • _amount_text() - Converts amount to text representation
  • _amount_debit_credit() - Computes debit and credit totals
  • _create_exchange_difference_move() - Handles exchange difference journal entries
  • _compute_analytic_account_id() - Inherits analytic account from stock moves
  • _compute_analytic_tag_ids() - Inherits analytic tags from stock moves

License

This module is licensed under the GNU Lesser General Public License v3.0 (LGPL-3).

Support

For support, please contact Grupo Quanam Colombia SAS at https://grupoquanam.com.co

niczapata/credport_quanamco | GitHunt