Skip to content
Snippets Groups Projects
Commit 0e6e0053 authored by Nshimiyimana Séna's avatar Nshimiyimana Séna
Browse files

[FIX] account: prevent sequence number gap in Accounting Firms mode


### Summary

When modifying the accounting date of an invoice in Accounting Firms
mode, Odoo always generates a new invoice sequence number. This behavior
can introduce gaps in the sequences.

### Reproduction Steps

1. Activate Accounting Firms mode.
2. Create a new Draft Invoice and save it.
3. Create a second Draft Invoice and save it.
4. Modify the accounting date of the first invoice and save it.
5. Observe that the first invoice's invoice sequence number is updated
   to the next sequence, creating a gap.

### Fix

Recompute the sequence only when the new date falls into a different
fiscal year.

opw-3164537

closes odoo/odoo#117007

Signed-off-by: default avatarWilliam André (wan) <wan@odoo.com>
parent 98aca8f7
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment