Skip to content
Health
67/100
fair
  • Security25/25
    No findings
  • Activity25/25
    Last human commit 1 month ago
  • Required by5/25
    0 modules depend on it
  • Maturity12/25
    In 2 Odoo series since 16.0

Heuristic over the facts below, not an audit · How it's computed

Security findings
Grave / minor (static analysis)
Required by
0
Modules depending on it
External deps
0 pip · 0 bin
Python packages / system binaries
License
AGPL-3
No conflicts with its dependencies
Folder size
0.09 MB
Module directory on disk
Code analysis 0 migration notes 3 models 2 views 0 HTTP endpoints

Description

This module allows renegotiating payment installments on posted invoices without having to reset them to draft.

In Brazilian fiscal scenarios, it's common to need to adjust payment due dates and amounts after an invoice (NFe) has been validated. This module provides a wizard to modify the payment terms while keeping the fiscal document unchanged.

Features:

  • Renegotiate payment installments on posted invoices
  • Modify due dates and amounts while keeping the total unchanged
  • Re-generate all installments from the payment term if needed
  • Edit the payment mode on installments (supports heterogenous payment modes)
  • Automatically logs changes in the invoice's chatter
  • Does not affect the fiscal document (NFe)

Dependencies

Odoo dependencies
Python dependencies
None
System dependencies
None
Required by
None

Code analysis

Extracted from the source by best-effort static analysis (no code is executed); details may be incomplete.

Views touched 2

XML IDNameModelTypeStatus
view_installment_renegotiation_wizard_form account.installment.renegotiation.wizard.form account.installment.renegotiation.wizard form New
view_move_form_renegotiation account.move.form.renegotiation account.move form Inherits account.view_move_form

HTTP endpoints 0

No HTTP endpoints found for this module.

Models touched 3

New fields (9)
  • company_id Many2one → res.company
    comodel_name='res.company' readonly=True related='move_id.company_id'
  • currency_id Many2one → res.currency
    comodel_name='res.currency' readonly=True related='move_id.currency_id'
  • difference Monetary
    compute='_compute_totals' currency_field='currency_id' help='Difference between original and new totals (must be zero)'
  • line_ids One2many → account.installment.renegotiation.wizard.line
    comodel_name='account.installment.renegotiation.wizard.line' inverse_name='wizard_id' string='Installments'
  • move_id Many2one → account.move
    comodel_name='account.move' ondelete='cascade' readonly=True required=True string='Invoice'
  • new_total Monetary
    compute='_compute_totals' currency_field='currency_id' help='Total amount of new installments'
  • original_total Monetary
    compute='_compute_totals' currency_field='currency_id' help='Total amount of unreconciled installments before renegotiation'
  • payment_term_id Many2one → account.payment.term
    comodel_name='account.payment.term' help='Select a payment term to automatically regenerate the installments.' string='New Payment Term'
  • starting_date Date
    help="Base date for computing the new payment term. Leave as the Invoice Date for corrections, or change to today's date for debt renegotiations."
Public methods (2)
  • action_apply(self)
    Apply the renegotiation to the invoice.
  • create(self, vals_list)
    @api.model_create_multi
    Override create to auto-populate fields and installment lines.

New fields (7)
  • amount Monetary
    currency_field='currency_id' required=True
  • company_id Many2one
    related='wizard_id.company_id'
  • currency_id Many2one → res.currency
    comodel_name='res.currency' readonly=True related='wizard_id.currency_id'
  • date_maturity Date
    required=True string='Due Date'
  • original_line_id Many2one → account.move.line
    comodel_name='account.move.line' help='The original invoice line this installment is based on (if any)' readonly=True string='Original Line'
  • payment_mode_id Many2one → account.payment.mode
    comodel_name='account.payment.mode' domain="[('company_id', '=', company_id)]" string='Payment Mode'
  • wizard_id Many2one → account.installment.renegotiation.wizard
    comodel_name='account.installment.renegotiation.wizard' ondelete='cascade' required=True string='Wizard'
Public methods (0)

No public methods.

New fields (1)
  • can_renegotiate_installments Boolean
    compute='_compute_can_renegotiate_installments' help='Technical field to determine if installment renegotiation is available'
Public methods (1)
  • action_renegotiate_installments(self)
    Open the installment renegotiation wizard. Only available for posted invoices with unreconciled payment_term lines.

Loading…